diff --git a/.eslintignore b/.eslintignore
deleted file mode 100644
index a832007..0000000
--- a/.eslintignore
+++ /dev/null
@@ -1,13 +0,0 @@
-snapshot*
-dist
-lib
-es
-esm
-node_modules
-static
-cypress
-script/test/cypress
-_site
-temp*
-static/
-!.prettierrc.js
\ No newline at end of file
diff --git a/.eslintrc b/.eslintrc
deleted file mode 100644
index da7365e..0000000
--- a/.eslintrc
+++ /dev/null
@@ -1,140 +0,0 @@
-{
- "extends": [
- "plugin:@typescript-eslint/recommended",
- "eslint-config-airbnb-base",
- "@vue/typescript/recommended",
- "plugin:vue/vue3-recommended",
- "plugin:vue-scoped-css/base",
- "plugin:prettier/recommended"
- ],
- "env": {
- "browser": true,
- "node": true,
- "jest": true,
- "es6": true
- },
- "globals": {
- "defineProps": "readonly",
- "defineEmits": "readonly"
- },
- "plugins": [
- "vue",
- "@typescript-eslint",
- "simple-import-sort"
- ],
- "parserOptions": {
- "parser": "@typescript-eslint/parser",
- "sourceType": "module",
- "allowImportExportEverywhere": true,
- "ecmaFeatures": {
- "jsx": true
- }
- },
- "settings": {
- "import/extensions": [
- ".js",
- ".jsx",
- ".ts",
- ".tsx"
- ]
- },
- "rules": {
- "no-nested-ternary": "off",
- "no-console": "off",
- "no-continue": "off",
- "no-restricted-syntax": "off",
- "no-return-assign": "off",
- "no-unused-expressions": "off",
- "no-return-await": "off",
- "no-plusplus": "off",
- "no-param-reassign": "off",
- "no-shadow": "off",
- "guard-for-in": "off",
- "import/extensions": "off",
- "import/no-unresolved": "off",
- "import/no-extraneous-dependencies": "off",
- "import/prefer-default-export": "off",
- "import/first": "off", // https://github.com/vuejs/vue-eslint-parser/issues/58
- "@typescript-eslint/no-explicit-any": "off",
- "@typescript-eslint/explicit-module-boundary-types": "off",
- "vue/first-attribute-linebreak": 0,
- "@typescript-eslint/no-unused-vars": [
- "error",
- {
- "argsIgnorePattern": "^_",
- "varsIgnorePattern": "^_"
- }
- ],
- "no-unused-vars": [
- "error",
- {
- "argsIgnorePattern": "^_",
- "varsIgnorePattern": "^_"
- }
- ],
- "no-use-before-define": "off",
- "@typescript-eslint/no-use-before-define": "off",
- "@typescript-eslint/ban-ts-comment": "off",
- "@typescript-eslint/ban-types": "off",
- "class-methods-use-this": "off", // 因为AxiosCancel必须实例化而能静态化所以加的规则,如果有办法解决可以取消
- "simple-import-sort/imports": "error",
- "simple-import-sort/exports": "error"
- },
- "overrides": [
- {
- "files": [
- "*.vue"
- ],
- "rules": {
- "vue/component-name-in-template-casing": [
- 2,
- "kebab-case"
- ],
- "vue/require-default-prop": 0,
- "vue/multi-word-component-names": 0,
- "vue/no-reserved-props": 0,
- "vue/no-v-html": 0,
- "vue-scoped-css/enforce-style-type": [
- "error",
- {
- "allows": [
- "scoped"
- ]
- }
- ]
- }
- },
- {
- "files": [
- "*.ts",
- "*.tsx"
- ], // https://github.com/typescript-eslint eslint-recommended
- "rules": {
- "constructor-super": "off", // ts(2335) & ts(2377)
- "getter-return": "off", // ts(2378)
- "no-const-assign": "off", // ts(2588)
- "no-dupe-args": "off", // ts(2300)
- "no-dupe-class-members": "off", // ts(2393) & ts(2300)
- "no-dupe-keys": "off", // ts(1117)
- "no-func-assign": "off", // ts(2539)
- "no-import-assign": "off", // ts(2539) & ts(2540)
- "no-new-symbol": "off", // ts(2588)
- "no-obj-calls": "off", // ts(2349)
- "no-redeclare": "off", // ts(2451)
- "no-setter-return": "off", // ts(2408)
- "no-this-before-super": "off", // ts(2376)
- "no-undef": "off", // ts(2304)
- "no-unreachable": "off", // ts(7027)
- "no-unsafe-negation": "off", // ts(2365) & ts(2360) & ts(2358)
- "no-var": "error", // ts transpiles let/const to var, so no need for vars any more
- "prefer-const": "error", // ts provides better types with const
- "prefer-rest-params": "error", // ts provides better types with rest args over arguments
- "prefer-spread": "error", // ts transpiles spread to apply, so no need for manual apply
- "valid-typeof": "off", // ts(2367)
- "consistent-return": "off",
- "no-promise-executor-return": "off",
- "prefer-promise-reject-errors": "off"
- }
- }
- ]
-}
\ No newline at end of file
diff --git a/.npmrc b/.npmrc
deleted file mode 100644
index 80ebf6e..0000000
--- a/.npmrc
+++ /dev/null
@@ -1,2 +0,0 @@
-electron_mirror=https://npmmirror.com/mirrors/electron/
-electron_builder_binaries_mirror=https://npmmirror.com/mirrors/electron-builder-binaries/
\ No newline at end of file
diff --git a/.prettierrc.js b/.prettierrc.js
deleted file mode 100644
index 3c58064..0000000
--- a/.prettierrc.js
+++ /dev/null
@@ -1,39 +0,0 @@
-module.exports = {
- // 一行最多 120 字符..
- printWidth: 120,
- // 使用 2 个空格缩进
- tabWidth: 2,
- // 不使用缩进符,而使用空格
- useTabs: false,
- // 行尾需要有分号
- semi: true,
- // 使用单引号
- singleQuote: true,
- // 对象的 key 仅在必要时用引号
- quoteProps: 'as-needed',
- // jsx 不使用单引号,而使用双引号
- jsxSingleQuote: false,
- // 末尾需要有逗号
- trailingComma: 'all',
- // 大括号内的首尾需要空格
- bracketSpacing: true,
- // jsx 标签的反尖括号需要换行
- jsxBracketSameLine: false,
- // 箭头函数,只有一个参数的时候,也需要括号
- arrowParens: 'always',
- // 每个文件格式化的范围是文件的全部内容
- rangeStart: 0,
- rangeEnd: Infinity,
- // 不需要写文件开头的 @prettier
- requirePragma: false,
- // 不需要自动在文件开头插入 @prettier
- insertPragma: false,
- // 使用默认的折行标准
- proseWrap: 'preserve',
- // 根据显示样式决定 html 要不要折行
- htmlWhitespaceSensitivity: 'css',
- // vue 文件中的 script 和 style 内不用缩进
- vueIndentScriptAndStyle: false,
- // 换行符使用 lf
- endOfLine: 'lf',
-};
diff --git a/LICENSE b/LICENSE
deleted file mode 100644
index 261eeb9..0000000
--- a/LICENSE
+++ /dev/null
@@ -1,201 +0,0 @@
- Apache License
- Version 2.0, January 2004
- http://www.apache.org/licenses/
-
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
-
- 1. Definitions.
-
- "License" shall mean the terms and conditions for use, reproduction,
- and distribution as defined by Sections 1 through 9 of this document.
-
- "Licensor" shall mean the copyright owner or entity authorized by
- the copyright owner that is granting the License.
-
- "Legal Entity" shall mean the union of the acting entity and all
- other entities that control, are controlled by, or are under common
- control with that entity. For the purposes of this definition,
- "control" means (i) the power, direct or indirect, to cause the
- direction or management of such entity, whether by contract or
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
- outstanding shares, or (iii) beneficial ownership of such entity.
-
- "You" (or "Your") shall mean an individual or Legal Entity
- exercising permissions granted by this License.
-
- "Source" form shall mean the preferred form for making modifications,
- including but not limited to software source code, documentation
- source, and configuration files.
-
- "Object" form shall mean any form resulting from mechanical
- transformation or translation of a Source form, including but
- not limited to compiled object code, generated documentation,
- and conversions to other media types.
-
- "Work" shall mean the work of authorship, whether in Source or
- Object form, made available under the License, as indicated by a
- copyright notice that is included in or attached to the work
- (an example is provided in the Appendix below).
-
- "Derivative Works" shall mean any work, whether in Source or Object
- form, that is based on (or derived from) the Work and for which the
- editorial revisions, annotations, elaborations, or other modifications
- represent, as a whole, an original work of authorship. For the purposes
- of this License, Derivative Works shall not include works that remain
- separable from, or merely link (or bind by name) to the interfaces of,
- the Work and Derivative Works thereof.
-
- "Contribution" shall mean any work of authorship, including
- the original version of the Work and any modifications or additions
- to that Work or Derivative Works thereof, that is intentionally
- submitted to Licensor for inclusion in the Work by the copyright owner
- or by an individual or Legal Entity authorized to submit on behalf of
- the copyright owner. For the purposes of this definition, "submitted"
- means any form of electronic, verbal, or written communication sent
- to the Licensor or its representatives, including but not limited to
- communication on electronic mailing lists, source code control systems,
- and issue tracking systems that are managed by, or on behalf of, the
- Licensor for the purpose of discussing and improving the Work, but
- excluding communication that is conspicuously marked or otherwise
- designated in writing by the copyright owner as "Not a Contribution."
-
- "Contributor" shall mean Licensor and any individual or Legal Entity
- on behalf of whom a Contribution has been received by Licensor and
- subsequently incorporated within the Work.
-
- 2. Grant of Copyright License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- copyright license to reproduce, prepare Derivative Works of,
- publicly display, publicly perform, sublicense, and distribute the
- Work and such Derivative Works in Source or Object form.
-
- 3. Grant of Patent License. Subject to the terms and conditions of
- this License, each Contributor hereby grants to You a perpetual,
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
- (except as stated in this section) patent license to make, have made,
- use, offer to sell, sell, import, and otherwise transfer the Work,
- where such license applies only to those patent claims licensable
- by such Contributor that are necessarily infringed by their
- Contribution(s) alone or by combination of their Contribution(s)
- with the Work to which such Contribution(s) was submitted. If You
- institute patent litigation against any entity (including a
- cross-claim or counterclaim in a lawsuit) alleging that the Work
- or a Contribution incorporated within the Work constitutes direct
- or contributory patent infringement, then any patent licenses
- granted to You under this License for that Work shall terminate
- as of the date such litigation is filed.
-
- 4. Redistribution. You may reproduce and distribute copies of the
- Work or Derivative Works thereof in any medium, with or without
- modifications, and in Source or Object form, provided that You
- meet the following conditions:
-
- (a) You must give any other recipients of the Work or
- Derivative Works a copy of this License; and
-
- (b) You must cause any modified files to carry prominent notices
- stating that You changed the files; and
-
- (c) You must retain, in the Source form of any Derivative Works
- that You distribute, all copyright, patent, trademark, and
- attribution notices from the Source form of the Work,
- excluding those notices that do not pertain to any part of
- the Derivative Works; and
-
- (d) If the Work includes a "NOTICE" text file as part of its
- distribution, then any Derivative Works that You distribute must
- include a readable copy of the attribution notices contained
- within such NOTICE file, excluding those notices that do not
- pertain to any part of the Derivative Works, in at least one
- of the following places: within a NOTICE text file distributed
- as part of the Derivative Works; within the Source form or
- documentation, if provided along with the Derivative Works; or,
- within a display generated by the Derivative Works, if and
- wherever such third-party notices normally appear. The contents
- of the NOTICE file are for informational purposes only and
- do not modify the License. You may add Your own attribution
- notices within Derivative Works that You distribute, alongside
- or as an addendum to the NOTICE text from the Work, provided
- that such additional attribution notices cannot be construed
- as modifying the License.
-
- You may add Your own copyright statement to Your modifications and
- may provide additional or different license terms and conditions
- for use, reproduction, or distribution of Your modifications, or
- for any such Derivative Works as a whole, provided Your use,
- reproduction, and distribution of the Work otherwise complies with
- the conditions stated in this License.
-
- 5. Submission of Contributions. Unless You explicitly state otherwise,
- any Contribution intentionally submitted for inclusion in the Work
- by You to the Licensor shall be under the terms and conditions of
- this License, without any additional terms or conditions.
- Notwithstanding the above, nothing herein shall supersede or modify
- the terms of any separate license agreement you may have executed
- with Licensor regarding such Contributions.
-
- 6. Trademarks. This License does not grant permission to use the trade
- names, trademarks, service marks, or product names of the Licensor,
- except as required for reasonable and customary use in describing the
- origin of the Work and reproducing the content of the NOTICE file.
-
- 7. Disclaimer of Warranty. Unless required by applicable law or
- agreed to in writing, Licensor provides the Work (and each
- Contributor provides its Contributions) on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
- implied, including, without limitation, any warranties or conditions
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
- PARTICULAR PURPOSE. You are solely responsible for determining the
- appropriateness of using or redistributing the Work and assume any
- risks associated with Your exercise of permissions under this License.
-
- 8. Limitation of Liability. In no event and under no legal theory,
- whether in tort (including negligence), contract, or otherwise,
- unless required by applicable law (such as deliberate and grossly
- negligent acts) or agreed to in writing, shall any Contributor be
- liable to You for damages, including any direct, indirect, special,
- incidental, or consequential damages of any character arising as a
- result of this License or out of the use or inability to use the
- Work (including but not limited to damages for loss of goodwill,
- work stoppage, computer failure or malfunction, or any and all
- other commercial damages or losses), even if such Contributor
- has been advised of the possibility of such damages.
-
- 9. Accepting Warranty or Additional Liability. While redistributing
- the Work or Derivative Works thereof, You may choose to offer,
- and charge a fee for, acceptance of support, warranty, indemnity,
- or other liability obligations and/or rights consistent with this
- License. However, in accepting such obligations, You may act only
- on Your own behalf and on Your sole responsibility, not on behalf
- of any other Contributor, and only if You agree to indemnify,
- defend, and hold each Contributor harmless for any liability
- incurred by, or claims asserted against, such Contributor by reason
- of your accepting any such warranty or additional liability.
-
- END OF TERMS AND CONDITIONS
-
- APPENDIX: How to apply the Apache License to your work.
-
- To apply the Apache License to your work, attach the following
- boilerplate notice, with the fields enclosed by brackets "[]"
- replaced with your own identifying information. (Don't include
- the brackets!) The text should be enclosed in the appropriate
- comment syntax for the file format. We also recommend that a
- file or class name and description of purpose be included on the
- same "printed page" as the copyright notice for easier
- identification within third-party archives.
-
- Copyright [yyyy] [name of copyright owner]
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
diff --git a/README.md b/README.md
index 7994201..c1ec5b9 100644
--- a/README.md
+++ b/README.md
@@ -1,102 +1,34 @@
-# Alger Music Player
-主要功能如下
+# electron-lan-file
-- 音乐推荐
-- 音乐播放
-- 网易云登录
-- 播放历史
-- 桌面歌词
-- 歌单 mv 搜索 专辑等功能
-- 识别无法播放歌曲 并代理播放
-- 可听周杰伦(搜索专辑)
+An Electron application with Vue and TypeScript
-## 项目简介
- 一个基于 electron typescript vue3 的桌面音乐播放器 适配 web端 桌面端 web移动端
+## Recommended IDE Setup
-## 预览地址
-[http://mc.alger.fun/](http://mc.alger.fun/)
+- [VSCode](https://code.visualstudio.com/) + [ESLint](https://marketplace.visualstudio.com/items?itemName=dbaeumer.vscode-eslint) + [Prettier](https://marketplace.visualstudio.com/items?itemName=esbenp.prettier-vscode) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) + [TypeScript Vue Plugin (Volar)](https://marketplace.visualstudio.com/items?itemName=Vue.vscode-typescript-vue-plugin)
-QQ群:789288579
+## Project Setup
-## 软件截图
-
-
-
-
-## 技术栈
-
-### 主要框架
-- Vue 3 - 渐进式 JavaScript 框架
-- TypeScript - JavaScript 的超集,添加了类型系统
-- Electron - 跨平台桌面应用开发框架
-- Vite - 下一代前端构建工具
-
-### UI 框架
-- Naive UI - 基于 Vue 3 的组件库
-
-### 项目特点
-- 完整的类型支持(TypeScript)
-- 模块化设计
-- 自动化组件和 API 导入
-- 多平台支持(Web、Desktop、Mobile Web)
-- 构建优化(代码分割、压缩)
-
-## 咖啡☕️
-| 微信 | 支付宝 |
-| :--------------------------------------------------------------------------------: | :--------------------------------------------------------------------------------: |
-|
|
|
-
-## 项目运行
-```bash
- # 安装依赖
- npm install
-
- # 运行项目 web
- npm run dev
-
- # 运行项目 electron
- npm run start
-
- # 打包项目 web
- npm run build
-
- # 打包项目 electron
- npm run win ...
- # 具体看 package.json
-```
-#### 注意
-- 本地运行需要配置 .env.development 文件
-- 打包需要配置 .env.production 文件
+### Install
```bash
- # .env.development
- VITE_API_LOCAL = /api
- VITE_API_MUSIC_PROXY = /music
- VITE_API_PROXY_MUSIC = /music_proxy
-
- # 你的接口地址 (必填)
- VITE_API = ***
- # 音乐po接口地址
- VITE_API_MUSIC = ***
- VITE_API_PROXY = ***
-
-
- # .env.production
- # 你的接口地址 (必填)
- VITE_API = ***
- # 音乐po接口地址
- VITE_API_MUSIC = ***
- # 代理地址
- VITE_API_PROXY = ***
+$ npm install
```
-## Stargazers over time
-[](https://starchart.cc/algerkong/AlgerMusicPlayer)
+### Development
+```bash
+$ npm run dev
+```
+### Build
+```bash
+# For windows
+$ npm run build:win
-## 欢迎提Issues
+# For macOS
+$ npm run build:mac
-## 免责声明
-本软件仅用于学习交流,禁止用于商业用途,否则后果自负。
+# For Linux
+$ npm run build:linux
+```
diff --git a/app.js b/app.js
deleted file mode 100644
index 69be6f5..0000000
--- a/app.js
+++ /dev/null
@@ -1,148 +0,0 @@
-const { app, BrowserWindow, ipcMain, Tray, Menu, globalShortcut, nativeImage } = require('electron');
-const path = require('path');
-const Store = require('electron-store');
-const setJson = require('./electron/set.json');
-const { loadLyricWindow } = require('./electron/lyric');
-const config = require('./electron/config');
-
-let mainWin = null;
-function createWindow() {
- mainWin = new BrowserWindow({
- width: 1200,
- height: 780,
- frame: false,
- webPreferences: {
- nodeIntegration: false,
- contextIsolation: true,
- preload: path.join(__dirname, '/electron/preload.js'),
- },
- });
- const win = mainWin;
- win.setMinimumSize(1200, 780);
- if (process.env.NODE_ENV === 'development') {
- win.webContents.openDevTools({ mode: 'detach' });
- win.loadURL(`http://localhost:${config.development.mainPort}/`);
- } else {
- win.loadURL(`file://${__dirname}/dist/index.html`);
- }
- const image = nativeImage
- .createFromPath(path.join(__dirname, 'public/icon_16x16.png'))
- .resize({ width: 16, height: 16 });
- const tray = new Tray(image);
-
- // 创建一个上下文菜单
- const contextMenu = Menu.buildFromTemplate([
- {
- label: '显示',
- click: () => {
- win.show();
- },
- },
- {
- label: '退出',
- click: () => {
- win.destroy();
- app.quit();
- },
- },
- ]);
-
- // 设置系统托盘图标的上下文菜单
- tray.setContextMenu(contextMenu);
-
- // 当系统托盘图标被点击时,切换窗口的显示/隐藏
- tray.on('click', () => {
- if (win.isVisible()) {
- win.hide();
- } else {
- win.show();
- }
- });
-
- const set = store.get('set');
- // store.set('set', setJson)
-
- if (!set) {
- store.set('set', setJson);
- }
-
- loadLyricWindow(ipcMain, mainWin);
-}
-
-// 限制只能启动一个应用
-const gotTheLock = app.requestSingleInstanceLock();
-if (!gotTheLock) {
- app.quit();
-}
-
-app.whenReady().then(createWindow);
-
-app.on('ready', () => {
- globalShortcut.register('CommandOrControl+Alt+Shift+M', () => {
- if (mainWin.isVisible()) {
- mainWin.hide();
- } else {
- mainWin.show();
- }
- });
-});
-
-app.on('window-all-closed', () => {
- if (process.platform !== 'darwin') {
- app.quit();
- }
-});
-
-app.on('will-quit', () => {
- globalShortcut.unregisterAll();
-});
-
-ipcMain.on('minimize-window', (event) => {
- const win = BrowserWindow.fromWebContents(event.sender);
- win.minimize();
-});
-
-ipcMain.on('maximize-window', (event) => {
- const win = BrowserWindow.fromWebContents(event.sender);
- if (win.isMaximized()) {
- win.unmaximize();
- } else {
- win.maximize();
- }
-});
-
-ipcMain.on('close-window', (event) => {
- const win = BrowserWindow.fromWebContents(event.sender);
- win.destroy();
- app.quit();
-});
-
-ipcMain.on('drag-start', (event) => {
- const win = BrowserWindow.fromWebContents(event.sender);
- win.webContents.beginFrameSubscription((frameBuffer) => {
- event.reply('frame-buffer', frameBuffer);
- });
-});
-
-ipcMain.on('mini-tray', (event) => {
- const win = BrowserWindow.fromWebContents(event.sender);
- win.hide();
-});
-
-// 重启
-ipcMain.on('restart', () => {
- app.relaunch();
- app.exit(0);
-});
-
-const store = new Store();
-
-// 定义ipcRenderer监听事件
-ipcMain.on('setStore', (_, key, value) => {
- store.set(key, value);
-});
-
-ipcMain.on('getStore', (_, key) => {
- const value = store.get(key);
- _.returnValue = value || '';
-});
diff --git a/auto-imports.d.ts b/auto-imports.d.ts
index b4ca07c..3af2dd5 100644
--- a/auto-imports.d.ts
+++ b/auto-imports.d.ts
@@ -6,70 +6,85 @@
// biome-ignore lint: disable
export {}
declare global {
- const EffectScope: typeof import('vue')['EffectScope']
- const computed: typeof import('vue')['computed']
- const createApp: typeof import('vue')['createApp']
- const customRef: typeof import('vue')['customRef']
- const defineAsyncComponent: typeof import('vue')['defineAsyncComponent']
- const defineComponent: typeof import('vue')['defineComponent']
- const effectScope: typeof import('vue')['effectScope']
- const getCurrentInstance: typeof import('vue')['getCurrentInstance']
- const getCurrentScope: typeof import('vue')['getCurrentScope']
- const h: typeof import('vue')['h']
- const inject: typeof import('vue')['inject']
- const isProxy: typeof import('vue')['isProxy']
- const isReactive: typeof import('vue')['isReactive']
- const isReadonly: typeof import('vue')['isReadonly']
- const isRef: typeof import('vue')['isRef']
- const markRaw: typeof import('vue')['markRaw']
- const nextTick: typeof import('vue')['nextTick']
- const onActivated: typeof import('vue')['onActivated']
- const onBeforeMount: typeof import('vue')['onBeforeMount']
- const onBeforeUnmount: typeof import('vue')['onBeforeUnmount']
- const onBeforeUpdate: typeof import('vue')['onBeforeUpdate']
- const onDeactivated: typeof import('vue')['onDeactivated']
- const onErrorCaptured: typeof import('vue')['onErrorCaptured']
- const onMounted: typeof import('vue')['onMounted']
- const onRenderTracked: typeof import('vue')['onRenderTracked']
- const onRenderTriggered: typeof import('vue')['onRenderTriggered']
- const onScopeDispose: typeof import('vue')['onScopeDispose']
- const onServerPrefetch: typeof import('vue')['onServerPrefetch']
- const onUnmounted: typeof import('vue')['onUnmounted']
- const onUpdated: typeof import('vue')['onUpdated']
- const onWatcherCleanup: typeof import('vue')['onWatcherCleanup']
- const provide: typeof import('vue')['provide']
- const reactive: typeof import('vue')['reactive']
- const readonly: typeof import('vue')['readonly']
- const ref: typeof import('vue')['ref']
- const resolveComponent: typeof import('vue')['resolveComponent']
- const shallowReactive: typeof import('vue')['shallowReactive']
- const shallowReadonly: typeof import('vue')['shallowReadonly']
- const shallowRef: typeof import('vue')['shallowRef']
- const toRaw: typeof import('vue')['toRaw']
- const toRef: typeof import('vue')['toRef']
- const toRefs: typeof import('vue')['toRefs']
- const toValue: typeof import('vue')['toValue']
- const triggerRef: typeof import('vue')['triggerRef']
- const unref: typeof import('vue')['unref']
- const useAttrs: typeof import('vue')['useAttrs']
- const useCssModule: typeof import('vue')['useCssModule']
- const useCssVars: typeof import('vue')['useCssVars']
- const useDialog: typeof import('naive-ui')['useDialog']
- const useId: typeof import('vue')['useId']
- const useLoadingBar: typeof import('naive-ui')['useLoadingBar']
- const useMessage: typeof import('naive-ui')['useMessage']
- const useModel: typeof import('vue')['useModel']
- const useNotification: typeof import('naive-ui')['useNotification']
- const useSlots: typeof import('vue')['useSlots']
- const useTemplateRef: typeof import('vue')['useTemplateRef']
- const watch: typeof import('vue')['watch']
- const watchEffect: typeof import('vue')['watchEffect']
- const watchPostEffect: typeof import('vue')['watchPostEffect']
- const watchSyncEffect: typeof import('vue')['watchSyncEffect']
+ const EffectScope: (typeof import('vue'))['EffectScope'];
+ const computed: (typeof import('vue'))['computed'];
+ const createApp: (typeof import('vue'))['createApp'];
+ const customRef: (typeof import('vue'))['customRef'];
+ const defineAsyncComponent: (typeof import('vue'))['defineAsyncComponent'];
+ const defineComponent: (typeof import('vue'))['defineComponent'];
+ const effectScope: (typeof import('vue'))['effectScope'];
+ const getCurrentInstance: (typeof import('vue'))['getCurrentInstance'];
+ const getCurrentScope: (typeof import('vue'))['getCurrentScope'];
+ const h: (typeof import('vue'))['h'];
+ const inject: (typeof import('vue'))['inject'];
+ const isProxy: (typeof import('vue'))['isProxy'];
+ const isReactive: (typeof import('vue'))['isReactive'];
+ const isReadonly: (typeof import('vue'))['isReadonly'];
+ const isRef: (typeof import('vue'))['isRef'];
+ const markRaw: (typeof import('vue'))['markRaw'];
+ const nextTick: (typeof import('vue'))['nextTick'];
+ const onActivated: (typeof import('vue'))['onActivated'];
+ const onBeforeMount: (typeof import('vue'))['onBeforeMount'];
+ const onBeforeUnmount: (typeof import('vue'))['onBeforeUnmount'];
+ const onBeforeUpdate: (typeof import('vue'))['onBeforeUpdate'];
+ const onDeactivated: (typeof import('vue'))['onDeactivated'];
+ const onErrorCaptured: (typeof import('vue'))['onErrorCaptured'];
+ const onMounted: (typeof import('vue'))['onMounted'];
+ const onRenderTracked: (typeof import('vue'))['onRenderTracked'];
+ const onRenderTriggered: (typeof import('vue'))['onRenderTriggered'];
+ const onScopeDispose: (typeof import('vue'))['onScopeDispose'];
+ const onServerPrefetch: (typeof import('vue'))['onServerPrefetch'];
+ const onUnmounted: (typeof import('vue'))['onUnmounted'];
+ const onUpdated: (typeof import('vue'))['onUpdated'];
+ const onWatcherCleanup: (typeof import('vue'))['onWatcherCleanup'];
+ const provide: (typeof import('vue'))['provide'];
+ const reactive: (typeof import('vue'))['reactive'];
+ const readonly: (typeof import('vue'))['readonly'];
+ const ref: (typeof import('vue'))['ref'];
+ const resolveComponent: (typeof import('vue'))['resolveComponent'];
+ const shallowReactive: (typeof import('vue'))['shallowReactive'];
+ const shallowReadonly: (typeof import('vue'))['shallowReadonly'];
+ const shallowRef: (typeof import('vue'))['shallowRef'];
+ const toRaw: (typeof import('vue'))['toRaw'];
+ const toRef: (typeof import('vue'))['toRef'];
+ const toRefs: (typeof import('vue'))['toRefs'];
+ const toValue: (typeof import('vue'))['toValue'];
+ const triggerRef: (typeof import('vue'))['triggerRef'];
+ const unref: (typeof import('vue'))['unref'];
+ const useAttrs: (typeof import('vue'))['useAttrs'];
+ const useCssModule: (typeof import('vue'))['useCssModule'];
+ const useCssVars: (typeof import('vue'))['useCssVars'];
+ const useDialog: (typeof import('naive-ui'))['useDialog'];
+ const useId: (typeof import('vue'))['useId'];
+ const useLoadingBar: (typeof import('naive-ui'))['useLoadingBar'];
+ const useMessage: (typeof import('naive-ui'))['useMessage'];
+ const useModel: (typeof import('vue'))['useModel'];
+ const useNotification: (typeof import('naive-ui'))['useNotification'];
+ const useSlots: (typeof import('vue'))['useSlots'];
+ const useTemplateRef: (typeof import('vue'))['useTemplateRef'];
+ const watch: (typeof import('vue'))['watch'];
+ const watchEffect: (typeof import('vue'))['watchEffect'];
+ const watchPostEffect: (typeof import('vue'))['watchPostEffect'];
+ const watchSyncEffect: (typeof import('vue'))['watchSyncEffect'];
}
// for type re-export
declare global {
// @ts-ignore
- export type { Component, ComponentPublicInstance, ComputedRef, DirectiveBinding, ExtractDefaultPropTypes, ExtractPropTypes, ExtractPublicPropTypes, InjectionKey, PropType, Ref, MaybeRef, MaybeRefOrGetter, VNode, WritableComputedRef } from 'vue'
- import('vue')
+ export type {
+ Component,
+ ComponentPublicInstance,
+ ComputedRef,
+ DirectiveBinding,
+ ExtractDefaultPropTypes,
+ ExtractPropTypes,
+ ExtractPublicPropTypes,
+ InjectionKey,
+ PropType,
+ Ref,
+ MaybeRef,
+ MaybeRefOrGetter,
+ VNode,
+ WritableComputedRef
+ } from 'vue';
+ import('vue');
}
diff --git a/build/entitlements.mac.plist b/build/entitlements.mac.plist
new file mode 100644
index 0000000..38c887b
--- /dev/null
+++ b/build/entitlements.mac.plist
@@ -0,0 +1,12 @@
+
+
+
+
+ com.apple.security.cs.allow-jit
+
+ com.apple.security.cs.allow-unsigned-executable-memory
+
+ com.apple.security.cs.allow-dyld-environment-variables
+
+
+
diff --git a/build/icon.icns b/build/icon.icns
new file mode 100644
index 0000000..28644aa
Binary files /dev/null and b/build/icon.icns differ
diff --git a/build/icon.ico b/build/icon.ico
new file mode 100644
index 0000000..72c391e
Binary files /dev/null and b/build/icon.ico differ
diff --git a/build/icon.png b/build/icon.png
new file mode 100644
index 0000000..cf9e8b2
Binary files /dev/null and b/build/icon.png differ
diff --git a/build/mac.json b/build/mac.json
deleted file mode 100644
index 5cf4922..0000000
--- a/build/mac.json
+++ /dev/null
@@ -1,49 +0,0 @@
-{
- "appId": "com.alger.music",
- "productName": "AlgerMusic",
- "artifactName": "${productName}_${version}_${arch}.${ext}",
- "directories": {
- "output": "dist_electron/mac"
- },
- "files": [
- "dist/**/*",
- "package.json",
- "app.js",
- "electron/**/*",
- "**/*",
- "public/**/*",
- "node_modules/**/*"
- ],
- "mac": {
- "icon": "public/icon.icns",
- "target": [
- {
- "target": "dmg",
- "arch": ["x64", "arm64"]
- }
- ],
- "category": "public.app-category.music",
- "darkModeSupport": true
- },
- "dmg": {
- "title": "${productName} ${version}",
- "icon": "public/icon.icns",
- "contents": [
- {
- "x": 410,
- "y": 150,
- "type": "link",
- "path": "/Applications"
- },
- {
- "x": 130,
- "y": 150,
- "type": "file"
- }
- ],
- "window": {
- "width": 540,
- "height": 380
- }
- }
-}
\ No newline at end of file
diff --git a/build/win32.json b/build/win32.json
deleted file mode 100644
index a1d095d..0000000
--- a/build/win32.json
+++ /dev/null
@@ -1,31 +0,0 @@
-{
- "appId": "com.alger.music",
- "productName": "AlgerMusic",
- "artifactName": "${productName}_${version}_Setup_x86.${ext}",
- "directories": {
- "output": "dist_electron/win-x86"
- },
- "files": ["dist/**/*", "package.json", "app.js", "electron/**/*"],
- "win": {
- "icon": "public/icon.png",
- "target": [
- {
- "target": "nsis",
- "arch": ["ia32"]
- }
- ],
- "extraFiles": [
- {
- "from": "installer/installer.nsh",
- "to": "$INSTDIR"
- }
- ]
- },
- "nsis": {
- "oneClick": false,
- "language": "2052",
- "allowToChangeInstallationDirectory": true,
- "differentialPackage": true,
- "shortcutName": "Alger Music"
- }
-}
diff --git a/build/win64.json b/build/win64.json
deleted file mode 100644
index 98dfb45..0000000
--- a/build/win64.json
+++ /dev/null
@@ -1,31 +0,0 @@
-{
- "appId": "com.alger.music",
- "productName": "AlgerMusic",
- "artifactName": "${productName}_${version}_Setup_x64.${ext}",
- "directories": {
- "output": "dist_electron/win-x64"
- },
- "files": ["dist/**/*", "package.json", "app.js", "electron/**/*"],
- "win": {
- "icon": "public/icon.png",
- "target": [
- {
- "target": "nsis",
- "arch": ["x64"]
- }
- ],
- "extraFiles": [
- {
- "from": "installer/installer.nsh",
- "to": "$INSTDIR"
- }
- ]
- },
- "nsis": {
- "oneClick": false,
- "language": "2052",
- "allowToChangeInstallationDirectory": true,
- "differentialPackage": true,
- "shortcutName": "Alger Music"
- }
-}
diff --git a/build/winarm64.json b/build/winarm64.json
deleted file mode 100644
index d0ea633..0000000
--- a/build/winarm64.json
+++ /dev/null
@@ -1,31 +0,0 @@
-{
- "appId": "com.alger.music",
- "productName": "AlgerMusic",
- "artifactName": "${productName}_${version}_Setup_arm64.${ext}",
- "directories": {
- "output": "dist_electron/win-arm64"
- },
- "files": ["dist/**/*", "package.json", "app.js", "electron/**/*", "!node_modules/**/*"],
- "win": {
- "icon": "public/icon.png",
- "target": [
- {
- "target": "nsis",
- "arch": ["arm64"]
- }
- ],
- "extraFiles": [
- {
- "from": "installer/installer.nsh",
- "to": "$INSTDIR"
- }
- ]
- },
- "nsis": {
- "oneClick": false,
- "language": "2052",
- "allowToChangeInstallationDirectory": true,
- "differentialPackage": true,
- "shortcutName": "Alger Music"
- }
-}
diff --git a/components.d.ts b/components.d.ts
index c5d95f3..6db7320 100644
--- a/components.d.ts
+++ b/components.d.ts
@@ -2,19 +2,13 @@
// @ts-nocheck
// Generated by unplugin-vue-components
// Read more: https://github.com/vuejs/core/pull/3399
-export {}
+export {};
/* prettier-ignore */
declare module 'vue' {
export interface GlobalComponents {
- Coffee: typeof import('./src/components/Coffee.vue')['default']
- InstallAppModal: typeof import('./src/components/common/InstallAppModal.vue')['default']
- MPop: typeof import('./src/components/common/MPop.vue')['default']
- MusicList: typeof import('./src/components/MusicList.vue')['default']
- MvPlayer: typeof import('./src/components/MvPlayer.vue')['default']
NAvatar: typeof import('naive-ui')['NAvatar']
NButton: typeof import('naive-ui')['NButton']
- NButtonGroup: typeof import('naive-ui')['NButtonGroup']
NCheckbox: typeof import('naive-ui')['NCheckbox']
NConfigProvider: typeof import('naive-ui')['NConfigProvider']
NDialogProvider: typeof import('naive-ui')['NDialogProvider']
@@ -24,6 +18,7 @@ declare module 'vue' {
NEmpty: typeof import('naive-ui')['NEmpty']
NImage: typeof import('naive-ui')['NImage']
NInput: typeof import('naive-ui')['NInput']
+ NInputNumber: typeof import('naive-ui')['NInputNumber']
NLayout: typeof import('naive-ui')['NLayout']
NMessageProvider: typeof import('naive-ui')['NMessageProvider']
NModal: typeof import('naive-ui')['NModal']
@@ -32,17 +27,7 @@ declare module 'vue' {
NSlider: typeof import('naive-ui')['NSlider']
NSpin: typeof import('naive-ui')['NSpin']
NSwitch: typeof import('naive-ui')['NSwitch']
- NTooltip: typeof import('naive-ui')['NTooltip']
- NVirtualList: typeof import('naive-ui')['NVirtualList']
- PlayBottom: typeof import('./src/components/common/PlayBottom.vue')['default']
- PlayListsItem: typeof import('./src/components/common/PlayListsItem.vue')['default']
- PlaylistType: typeof import('./src/components/PlaylistType.vue')['default']
- RecommendAlbum: typeof import('./src/components/RecommendAlbum.vue')['default']
- RecommendSinger: typeof import('./src/components/RecommendSinger.vue')['default']
- RecommendSonglist: typeof import('./src/components/RecommendSonglist.vue')['default']
RouterLink: typeof import('vue-router')['RouterLink']
RouterView: typeof import('vue-router')['RouterView']
- SearchItem: typeof import('./src/components/common/SearchItem.vue')['default']
- SongItem: typeof import('./src/components/common/SongItem.vue')['default']
}
}
diff --git a/dev-app-update.yml b/dev-app-update.yml
new file mode 100644
index 0000000..db4eb90
--- /dev/null
+++ b/dev-app-update.yml
@@ -0,0 +1,3 @@
+provider: generic
+url: https://example.com/auto-updates
+updaterCacheDirName: electron-lan-file-updater
diff --git a/docs/img/image-1.png b/docs/img/image-1.png
deleted file mode 100644
index 29d7f90..0000000
Binary files a/docs/img/image-1.png and /dev/null differ
diff --git a/docs/img/image-2.png b/docs/img/image-2.png
deleted file mode 100644
index 6cc1dc9..0000000
Binary files a/docs/img/image-2.png and /dev/null differ
diff --git a/docs/img/image-3.png b/docs/img/image-3.png
deleted file mode 100644
index 170bcf7..0000000
Binary files a/docs/img/image-3.png and /dev/null differ
diff --git a/docs/img/image-4.png b/docs/img/image-4.png
deleted file mode 100644
index 18109aa..0000000
Binary files a/docs/img/image-4.png and /dev/null differ
diff --git a/docs/img/image-5.png b/docs/img/image-5.png
deleted file mode 100644
index 54c9e08..0000000
Binary files a/docs/img/image-5.png and /dev/null differ
diff --git a/docs/img/image-6.png b/docs/img/image-6.png
deleted file mode 100644
index a5816d4..0000000
Binary files a/docs/img/image-6.png and /dev/null differ
diff --git a/docs/img/image-7.png b/docs/img/image-7.png
deleted file mode 100644
index 6ebe42b..0000000
Binary files a/docs/img/image-7.png and /dev/null differ
diff --git a/docs/img/image-8.png b/docs/img/image-8.png
deleted file mode 100644
index 671c32d..0000000
Binary files a/docs/img/image-8.png and /dev/null differ
diff --git a/docs/img/image.png b/docs/img/image.png
deleted file mode 100644
index e217355..0000000
Binary files a/docs/img/image.png and /dev/null differ
diff --git a/electron-builder.yml b/electron-builder.yml
new file mode 100644
index 0000000..f5f7ed6
--- /dev/null
+++ b/electron-builder.yml
@@ -0,0 +1,45 @@
+appId: com.electron.app
+productName: electron-lan-file
+directories:
+ buildResources: build
+files:
+ - '!**/.vscode/*'
+ - '!src/*'
+ - '!electron.vite.config.{js,ts,mjs,cjs}'
+ - '!{.eslintignore,.eslintrc.cjs,.prettierignore,.prettierrc.yaml,dev-app-update.yml,CHANGELOG.md,README.md}'
+ - '!{.env,.env.*,.npmrc,pnpm-lock.yaml}'
+ - '!{tsconfig.json,tsconfig.node.json,tsconfig.web.json}'
+asarUnpack:
+ - resources/**
+win:
+ executableName: electron-lan-file
+nsis:
+ artifactName: ${name}-${version}-setup.${ext}
+ shortcutName: ${productName}
+ uninstallDisplayName: ${productName}
+ createDesktopShortcut: always
+mac:
+ entitlementsInherit: build/entitlements.mac.plist
+ extendInfo:
+ - NSCameraUsageDescription: Application requests access to the device's camera.
+ - NSMicrophoneUsageDescription: Application requests access to the device's microphone.
+ - NSDocumentsFolderUsageDescription: Application requests access to the user's Documents folder.
+ - NSDownloadsFolderUsageDescription: Application requests access to the user's Downloads folder.
+ notarize: false
+dmg:
+ artifactName: ${name}-${version}.${ext}
+linux:
+ target:
+ - AppImage
+ - snap
+ - deb
+ maintainer: electronjs.org
+ category: Utility
+appImage:
+ artifactName: ${name}-${version}.${ext}
+npmRebuild: false
+publish:
+ provider: generic
+ url: https://example.com/auto-updates
+electronDownload:
+ mirror: https://npmmirror.com/mirrors/electron/
diff --git a/electron.vite.config.ts b/electron.vite.config.ts
new file mode 100644
index 0000000..9cf314e
--- /dev/null
+++ b/electron.vite.config.ts
@@ -0,0 +1,60 @@
+import vue from '@vitejs/plugin-vue';
+import { defineConfig, externalizeDepsPlugin } from 'electron-vite';
+import { resolve } from 'path';
+import AutoImport from 'unplugin-auto-import/vite';
+import { NaiveUiResolver } from 'unplugin-vue-components/resolvers';
+import Components from 'unplugin-vue-components/vite';
+import viteCompression from 'vite-plugin-compression';
+
+export default defineConfig({
+ main: {
+ plugins: [externalizeDepsPlugin()]
+ },
+ preload: {
+ plugins: [externalizeDepsPlugin()]
+ },
+ renderer: {
+ resolve: {
+ alias: {
+ '@': resolve('src/renderer'),
+ '@renderer': resolve('src/renderer')
+ }
+ },
+ plugins: [
+ vue(),
+ viteCompression(),
+ // VueDevTools(),
+ AutoImport({
+ imports: [
+ 'vue',
+ {
+ 'naive-ui': ['useDialog', 'useMessage', 'useNotification', 'useLoadingBar']
+ }
+ ]
+ }),
+ Components({
+ resolvers: [NaiveUiResolver()]
+ })
+ ],
+ server: {
+ proxy: {
+ // with options
+ [process.env.VITE_API_LOCAL as string]: {
+ target: process.env.VITE_API,
+ changeOrigin: true,
+ rewrite: (path) => path.replace(new RegExp(`^${process.env.VITE_API_LOCAL}`), '')
+ },
+ [process.env.VITE_API_MUSIC_PROXY as string]: {
+ target: process.env.VITE_API_MUSIC,
+ changeOrigin: true,
+ rewrite: (path) => path.replace(new RegExp(`^${process.env.VITE_API_MUSIC_PROXY}`), '')
+ },
+ [process.env.VITE_API_PROXY_MUSIC as string]: {
+ target: process.env.VITE_API_PROXY,
+ changeOrigin: true,
+ rewrite: (path) => path.replace(new RegExp(`^${process.env.VITE_API_PROXY_MUSIC}`), '')
+ }
+ }
+ }
+ }
+});
diff --git a/electron/config.js b/electron/config.js
deleted file mode 100644
index e849ffb..0000000
--- a/electron/config.js
+++ /dev/null
@@ -1,11 +0,0 @@
-module.exports = {
- // 开发环境配置
- development: {
- mainPort: 4488,
- lyricPort: 4488,
- },
- // 生产环境配置
- production: {
- distPath: '../dist',
- },
-};
diff --git a/electron/preload.js b/electron/preload.js
deleted file mode 100644
index ebee7d8..0000000
--- a/electron/preload.js
+++ /dev/null
@@ -1,30 +0,0 @@
-const { contextBridge, ipcRenderer } = require('electron');
-
-// 主进程通信
-contextBridge.exposeInMainWorld('electronAPI', {
- minimize: () => ipcRenderer.send('minimize-window'),
- maximize: () => ipcRenderer.send('maximize-window'),
- close: () => ipcRenderer.send('close-window'),
- dragStart: (data) => ipcRenderer.send('drag-start', data),
- miniTray: () => ipcRenderer.send('mini-tray'),
- restart: () => ipcRenderer.send('restart'),
- openLyric: () => ipcRenderer.send('open-lyric'),
- sendLyric: (data) => ipcRenderer.send('send-lyric', data),
-});
-
-// 存储相关
-contextBridge.exposeInMainWorld('electron', {
- ipcRenderer: {
- setStoreValue: (key, value) => ipcRenderer.send('setStore', key, value),
- getStoreValue: (key) => ipcRenderer.sendSync('getStore', key),
- on: (channel, func) => {
- ipcRenderer.on(channel, (event, ...args) => func(...args));
- },
- once: (channel, func) => {
- ipcRenderer.once(channel, (event, ...args) => func(...args));
- },
- send: (channel, data) => {
- ipcRenderer.send(channel, data);
- },
- },
-});
diff --git a/electron/update.js b/electron/update.js
deleted file mode 100644
index 55e51ba..0000000
--- a/electron/update.js
+++ /dev/null
@@ -1,69 +0,0 @@
-const { app, BrowserWindow } = require('electron');
-const axios = require('axios');
-const fs = require('fs');
-const path = require('path');
-const AdmZip = require('adm-zip');
-
-class Updater {
- constructor(mainWindow) {
- this.mainWindow = mainWindow;
- this.updateUrl = 'http://your-server.com/update'; // 更新服务器地址
- this.version = app.getVersion();
- }
-
- // 检查更新
- async checkForUpdates() {
- try {
- const response = await axios.get(`${this.updateUrl}/check`, {
- params: {
- version: this.version,
- },
- });
-
- if (response.data.hasUpdate) {
- await this.downloadUpdate(response.data.downloadUrl);
- }
- } catch (error) {
- console.error('检查更新失败:', error);
- }
- }
-
- // 下载更新
- async downloadUpdate(downloadUrl) {
- try {
- const response = await axios({
- url: downloadUrl,
- method: 'GET',
- responseType: 'arraybuffer',
- });
-
- const tempPath = path.join(app.getPath('temp'), 'update.zip');
- fs.writeFileSync(tempPath, response.data);
-
- await this.extractUpdate(tempPath);
- } catch (error) {
- console.error('下载更新失败:', error);
- }
- }
-
- // 解压更新
- async extractUpdate(zipPath) {
- try {
- const zip = new AdmZip(zipPath);
- const targetPath = path.join(__dirname, '../dist'); // 前端文件目录
-
- // 解压文件
- zip.extractAllTo(targetPath, true);
-
- // 删除临时文件
- fs.unlinkSync(zipPath);
-
- // 刷新页面
- this.mainWindow.webContents.reload();
- } catch (error) {
- console.error('解压更新失败:', error);
- }
- }
-}
-
-module.exports = Updater;
diff --git a/index.html b/index.html
deleted file mode 100644
index 73f9080..0000000
--- a/index.html
+++ /dev/null
@@ -1,57 +0,0 @@
-
-
-
-
-
-
-
-
-
- 网抑云音乐 | AlgerKong | AlgerMusicPlayer
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Total Page View Loading
- Total Visits Loading
- Site Total Visitors Loading
-
-
-
-
-
\ No newline at end of file
diff --git a/out/main/index.js b/out/main/index.js
new file mode 100644
index 0000000..f188d04
--- /dev/null
+++ b/out/main/index.js
@@ -0,0 +1,323 @@
+"use strict";
+const utils = require("@electron-toolkit/utils");
+const electron = require("electron");
+const Store = require("electron-store");
+const path = require("path");
+const fs = require("fs");
+const os = require("os");
+const match = require("@unblockneteasemusic/server");
+const server = require("netease-cloud-music-api-alger/server");
+const isProxy = false;
+const noAnimate = false;
+const animationSpeed = 1;
+const author = "Alger";
+const authorUrl = "https://github.com/algerkong";
+const musicApiPort = 30488;
+const set = {
+ isProxy,
+ noAnimate,
+ animationSpeed,
+ author,
+ authorUrl,
+ musicApiPort
+};
+const store$2 = new Store();
+let lyricWindow = null;
+const createWin = () => {
+ console.log("Creating lyric window");
+ const windowBounds = store$2.get("lyricWindowBounds") || {};
+ const { x, y, width, height } = windowBounds;
+ const { width: screenWidth, height: screenHeight } = electron.screen.getPrimaryDisplay().workAreaSize;
+ const validPosition = x !== void 0 && y !== void 0 && x >= 0 && y >= 0 && x < screenWidth && y < screenHeight;
+ lyricWindow = new electron.BrowserWindow({
+ width: width || 800,
+ height: height || 200,
+ x: validPosition ? x : void 0,
+ y: validPosition ? y : void 0,
+ frame: false,
+ show: false,
+ transparent: true,
+ hasShadow: false,
+ alwaysOnTop: true,
+ webPreferences: {
+ preload: path.join(__dirname, "../preload/index.js"),
+ sandbox: false,
+ contextIsolation: true
+ }
+ });
+ lyricWindow.on("closed", () => {
+ if (lyricWindow) {
+ lyricWindow.destroy();
+ lyricWindow = null;
+ }
+ });
+ return lyricWindow;
+};
+const loadLyricWindow = (ipcMain, mainWin) => {
+ const showLyricWindow = () => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ if (lyricWindow.isMinimized()) {
+ lyricWindow.restore();
+ }
+ lyricWindow.focus();
+ lyricWindow.show();
+ return true;
+ }
+ return false;
+ };
+ ipcMain.on("open-lyric", () => {
+ console.log("Received open-lyric request");
+ if (showLyricWindow()) {
+ return;
+ }
+ console.log("Creating new lyric window");
+ const win = createWin();
+ if (!win) {
+ console.error("Failed to create lyric window");
+ return;
+ }
+ if (process.env.NODE_ENV === "development") {
+ win.webContents.openDevTools({ mode: "detach" });
+ win.loadURL(`${process.env.ELECTRON_RENDERER_URL}/#/lyric`);
+ } else {
+ const distPath = path.resolve(__dirname, "../renderer");
+ win.loadURL(`file://${distPath}/index.html#/lyric`);
+ }
+ win.setMinimumSize(600, 200);
+ win.setSkipTaskbar(true);
+ win.once("ready-to-show", () => {
+ console.log("Lyric window ready to show");
+ win.show();
+ });
+ });
+ ipcMain.on("send-lyric", (_, data) => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ try {
+ lyricWindow.webContents.send("receive-lyric", data);
+ } catch (error) {
+ console.error("Error processing lyric data:", error);
+ }
+ }
+ });
+ ipcMain.on("top-lyric", (_, data) => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.setAlwaysOnTop(data);
+ }
+ });
+ ipcMain.on("close-lyric", () => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.webContents.send("lyric-window-close");
+ mainWin.webContents.send("lyric-control-back", "close");
+ lyricWindow.destroy();
+ lyricWindow = null;
+ }
+ });
+ ipcMain.on("mouseenter-lyric", () => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.setIgnoreMouseEvents(true);
+ }
+ });
+ ipcMain.on("mouseleave-lyric", () => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.setIgnoreMouseEvents(false);
+ }
+ });
+ ipcMain.on("lyric-drag-move", (_, { deltaX, deltaY }) => {
+ if (!lyricWindow || lyricWindow.isDestroyed()) return;
+ const [currentX, currentY] = lyricWindow.getPosition();
+ const { width: screenWidth, height: screenHeight } = electron.screen.getPrimaryDisplay().workAreaSize;
+ const [windowWidth, windowHeight] = lyricWindow.getSize();
+ const newX = Math.max(0, Math.min(currentX + deltaX, screenWidth - windowWidth));
+ const newY = Math.max(0, Math.min(currentY + deltaY, screenHeight - windowHeight));
+ lyricWindow.setPosition(newX, newY);
+ store$2.set("lyricWindowBounds", {
+ ...lyricWindow.getBounds(),
+ x: newX,
+ y: newY
+ });
+ });
+ ipcMain.on("set-ignore-mouse", (_, shouldIgnore) => {
+ if (!lyricWindow || lyricWindow.isDestroyed()) return;
+ lyricWindow.setIgnoreMouseEvents(shouldIgnore, { forward: true });
+ });
+ ipcMain.on("control-back", (_, command) => {
+ console.log("command", command);
+ if (mainWin && !mainWin.isDestroyed()) {
+ console.log("Sending control-back command:", command);
+ mainWin.webContents.send("lyric-control-back", command);
+ }
+ });
+};
+const unblockMusic = async (id) => {
+ return new Promise((resolve, reject) => {
+ match(parseInt(id, 10), ["qq", "migu", "kugou", "joox"]).then((data) => {
+ resolve({
+ data: {
+ data,
+ params: {
+ id,
+ type: "song"
+ }
+ }
+ });
+ }).catch((err) => {
+ reject(err);
+ });
+ });
+};
+const store$1 = new Store();
+if (!fs.existsSync(path.resolve(os.tmpdir(), "anonymous_token"))) {
+ fs.writeFileSync(path.resolve(os.tmpdir(), "anonymous_token"), "", "utf-8");
+}
+electron.ipcMain.handle("unblock-music", async (_, id) => {
+ return unblockMusic(id);
+});
+async function startMusicApi() {
+ console.log("MUSIC API STARTED");
+ const port = store$1.get("set").musicApiPort || 30488;
+ await server.serveNcmApi({
+ port
+ });
+}
+const iconPath = path.join(__dirname, "../../resources");
+const icon = electron.nativeImage.createFromPath(
+ process.platform === "darwin" ? path.join(iconPath, "icon.icns") : process.platform === "win32" ? path.join(iconPath, "favicon.ico") : path.join(iconPath, "icon.png")
+);
+let mainWindow;
+function createWindow() {
+ startMusicApi();
+ mainWindow = new electron.BrowserWindow({
+ width: 1200,
+ height: 780,
+ show: false,
+ frame: false,
+ autoHideMenuBar: true,
+ icon,
+ webPreferences: {
+ preload: path.join(__dirname, "../preload/index.js"),
+ sandbox: false,
+ contextIsolation: true
+ }
+ });
+ mainWindow.setMinimumSize(1200, 780);
+ mainWindow.on("ready-to-show", () => {
+ mainWindow.show();
+ });
+ mainWindow.webContents.setWindowOpenHandler((details) => {
+ electron.shell.openExternal(details.url);
+ return { action: "deny" };
+ });
+ if (utils.is.dev && process.env.ELECTRON_RENDERER_URL) {
+ mainWindow.webContents.openDevTools({ mode: "detach" });
+ mainWindow.loadURL(process.env.ELECTRON_RENDERER_URL);
+ } else {
+ mainWindow.webContents.openDevTools({ mode: "detach" });
+ mainWindow.loadFile(path.join(__dirname, "../renderer/index.html"));
+ }
+ const trayIcon = electron.nativeImage.createFromPath(path.join(iconPath, "icon_16x16.png")).resize({ width: 16, height: 16 });
+ const tray = new electron.Tray(trayIcon);
+ const contextMenu = electron.Menu.buildFromTemplate([
+ {
+ label: "显示",
+ click: () => {
+ mainWindow.show();
+ }
+ },
+ {
+ label: "退出",
+ click: () => {
+ mainWindow.destroy();
+ electron.app.quit();
+ }
+ }
+ ]);
+ tray.setContextMenu(contextMenu);
+ tray.on("click", () => {
+ if (mainWindow.isVisible()) {
+ mainWindow.hide();
+ } else {
+ mainWindow.show();
+ }
+ });
+ loadLyricWindow(electron.ipcMain, mainWindow);
+}
+electron.app.whenReady().then(() => {
+ utils.electronApp.setAppUserModelId("com.alger.music");
+ electron.app.on("browser-window-created", (_, window) => {
+ utils.optimizer.watchWindowShortcuts(window);
+ });
+ electron.ipcMain.on("ping", () => console.log("pong"));
+ createWindow();
+ electron.app.on("activate", function() {
+ if (electron.BrowserWindow.getAllWindows().length === 0) createWindow();
+ });
+});
+electron.app.on("ready", () => {
+ electron.globalShortcut.register("CommandOrControl+Alt+Shift+M", () => {
+ if (mainWindow.isVisible()) {
+ mainWindow.hide();
+ } else {
+ mainWindow.show();
+ }
+ });
+});
+electron.app.on("window-all-closed", () => {
+ if (process.platform !== "darwin") {
+ electron.app.quit();
+ }
+});
+electron.ipcMain.on("minimize-window", (event) => {
+ const win = electron.BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.minimize();
+ }
+});
+electron.ipcMain.on("maximize-window", (event) => {
+ const win = electron.BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ if (win.isMaximized()) {
+ win.unmaximize();
+ } else {
+ win.maximize();
+ }
+ }
+});
+electron.ipcMain.on("close-window", (event) => {
+ const win = electron.BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.destroy();
+ electron.app.quit();
+ }
+});
+electron.ipcMain.on("drag-start", (event) => {
+ const win = electron.BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.webContents.beginFrameSubscription((frameBuffer) => {
+ event.reply("frame-buffer", frameBuffer);
+ });
+ }
+});
+electron.ipcMain.on("mini-tray", (event) => {
+ const win = electron.BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.hide();
+ }
+});
+electron.ipcMain.on("restart", () => {
+ electron.app.relaunch();
+ electron.app.exit(0);
+});
+const store = new Store({
+ name: "config",
+ // 配置文件名
+ defaults: {
+ set
+ }
+});
+electron.ipcMain.on("set-store-value", (_, key, value) => {
+ store.set(key, value);
+});
+electron.ipcMain.on("get-store-value", (_, key) => {
+ const value = store.get(key);
+ _.returnValue = value || "";
+});
diff --git a/out/preload/index.js b/out/preload/index.js
new file mode 100644
index 0000000..f8670c8
--- /dev/null
+++ b/out/preload/index.js
@@ -0,0 +1,25 @@
+"use strict";
+const preload = require("@electron-toolkit/preload");
+const electron = require("electron");
+const api = {
+ minimize: () => electron.ipcRenderer.send("minimize-window"),
+ maximize: () => electron.ipcRenderer.send("maximize-window"),
+ close: () => electron.ipcRenderer.send("close-window"),
+ dragStart: (data) => electron.ipcRenderer.send("drag-start", data),
+ miniTray: () => electron.ipcRenderer.send("mini-tray"),
+ restart: () => electron.ipcRenderer.send("restart"),
+ openLyric: () => electron.ipcRenderer.send("open-lyric"),
+ sendLyric: (data) => electron.ipcRenderer.send("send-lyric", data),
+ unblockMusic: (id) => electron.ipcRenderer.invoke("unblock-music", id)
+};
+if (process.contextIsolated) {
+ try {
+ electron.contextBridge.exposeInMainWorld("electron", preload.electronAPI);
+ electron.contextBridge.exposeInMainWorld("api", api);
+ } catch (error) {
+ console.error(error);
+ }
+} else {
+ window.electron = preload.electronAPI;
+ window.api = api;
+}
diff --git a/out/renderer/assets/AppMenu-CbDXL_JE.js b/out/renderer/assets/AppMenu-CbDXL_JE.js
new file mode 100644
index 0000000..ae96239
--- /dev/null
+++ b/out/renderer/assets/AppMenu-CbDXL_JE.js
@@ -0,0 +1,98 @@
+import { d as defineComponent, af as useRoute, r as ref, E as watch, ar as resolveComponent, j as openBlock, c as createElementBlock, b as createBaseVNode, u as unref, a3 as Fragment, a4 as renderList, e as createVNode, f as withCtx, n as normalizeClass, a2 as normalizeStyle, t as toDisplayString, T as createCommentVNode, _ as _export_sfc } from "./index-DKaFsuse.js";
+const icon = "" + new URL("icon-mGmYaNg4.png", import.meta.url).href;
+const _hoisted_1 = { class: "app-menu-header" };
+const _hoisted_2 = ["src"];
+const _hoisted_3 = { class: "app-menu-list" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "AppMenu",
+ props: {
+ size: {
+ type: String,
+ default: "26px"
+ },
+ color: {
+ type: String,
+ default: "#aaa"
+ },
+ selectColor: {
+ type: String,
+ default: "#10B981"
+ },
+ menus: {
+ type: Array,
+ default: () => []
+ }
+ },
+ setup(__props) {
+ const props = __props;
+ const route = useRoute();
+ const path = ref(route.path);
+ watch(
+ () => route.path,
+ async (newParams) => {
+ path.value = newParams;
+ }
+ );
+ const isChecked = (index) => {
+ return path.value === props.menus[index].path;
+ };
+ const iconStyle = (index) => {
+ const style = {
+ fontSize: props.size,
+ color: isChecked(index) ? props.selectColor : props.color
+ };
+ return style;
+ };
+ const isText = ref(false);
+ return (_ctx, _cache) => {
+ const _component_router_link = resolveComponent("router-link");
+ return openBlock(), createElementBlock("div", null, [
+ createBaseVNode("div", {
+ class: normalizeClass(["app-menu", { "app-menu-expanded": unref(isText) }])
+ }, [
+ createBaseVNode("div", _hoisted_1, [
+ createBaseVNode("div", {
+ class: "app-menu-logo",
+ onClick: _cache[0] || (_cache[0] = ($event) => isText.value = !unref(isText))
+ }, [
+ createBaseVNode("img", {
+ src: unref(icon),
+ class: "w-9 h-9",
+ alt: "logo"
+ }, null, 8, _hoisted_2)
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_3, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(__props.menus, (item, index) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.path,
+ class: "app-menu-item"
+ }, [
+ createVNode(_component_router_link, {
+ class: "app-menu-item-link",
+ to: item.path
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont app-menu-item-icon", item.meta.icon]),
+ style: normalizeStyle(iconStyle(index))
+ }, null, 6),
+ unref(isText) ? (openBlock(), createElementBlock("span", {
+ key: 0,
+ class: normalizeClass(["app-menu-item-text ml-3", isChecked(index) ? "text-green-500" : ""])
+ }, toDisplayString(item.meta.title), 3)) : createCommentVNode("", true)
+ ]),
+ _: 2
+ }, 1032, ["to"])
+ ]);
+ }), 128))
+ ])
+ ], 2)
+ ]);
+ };
+ }
+});
+const AppMenu = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f209e92f"]]);
+export {
+ AppMenu as default
+};
diff --git a/out/renderer/assets/AppMenu-CbDXL_JE.js.gz b/out/renderer/assets/AppMenu-CbDXL_JE.js.gz
new file mode 100644
index 0000000..4d6c45c
Binary files /dev/null and b/out/renderer/assets/AppMenu-CbDXL_JE.js.gz differ
diff --git a/out/renderer/assets/AppMenu-iZYnVe2B.css b/out/renderer/assets/AppMenu-iZYnVe2B.css
new file mode 100644
index 0000000..6b7185d
--- /dev/null
+++ b/out/renderer/assets/AppMenu-iZYnVe2B.css
@@ -0,0 +1,90 @@
+.app-menu[data-v-f209e92f] {
+ width: 100px;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+ padding-left: 0.25rem;
+ padding-right: 0.25rem;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+}
+.app-menu-expanded[data-v-f209e92f] {
+ width: 160px;
+}
+.app-menu-expanded .app-menu-item[data-v-f209e92f] {
+ margin-right: 1rem;
+ border-radius: 0.25rem;
+}
+.app-menu-expanded .app-menu-item[data-v-f209e92f]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+.app-menu-expanded .app-menu-item[data-v-f209e92f]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.app-menu-item-link[data-v-f209e92f],
+.app-menu-header[data-v-f209e92f] {
+ margin-left: 0.5rem;
+ display: flex;
+ width: 200px;
+ align-items: center;
+ overflow: hidden;
+ padding-left: 1.25rem;
+ padding-right: 1.25rem;
+}
+.app-menu-header[data-v-f209e92f] {
+ margin-left: 0.25rem;
+}
+.app-menu-item-link[data-v-f209e92f] {
+ margin-bottom: 1.5rem;
+ margin-top: 1.5rem;
+}
+.app-menu-item-icon[data-v-f209e92f] {
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 200ms;
+}
+.app-menu-item-icon[data-v-f209e92f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.app-menu-item-icon[data-v-f209e92f]:hover {
+ --tw-scale-x: 1.05 !important;
+ --tw-scale-y: 1.05 !important;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y)) !important;
+ --tw-text-opacity: 1 !important;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1)) !important;
+}
+.mobile .app-menu[data-v-f209e92f] {
+ max-width: 100%;
+ width: 100vw;
+ position: relative;
+ z-index: 999999;
+ border-top-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.mobile .app-menu[data-v-f209e92f]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.mobile .app-menu-header[data-v-f209e92f] {
+ display: none;
+}
+.mobile .app-menu-list[data-v-f209e92f] {
+ display: flex;
+ justify-content: space-between;
+}
+.mobile .app-menu-item-link[data-v-f209e92f] {
+ margin-top: 1rem;
+ margin-bottom: 1rem;
+ width: auto;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/AppMenu-iZYnVe2B.css.gz b/out/renderer/assets/AppMenu-iZYnVe2B.css.gz
new file mode 100644
index 0000000..5bd99f0
Binary files /dev/null and b/out/renderer/assets/AppMenu-iZYnVe2B.css.gz differ
diff --git a/out/renderer/assets/Avatar-rQ2og-6c.js b/out/renderer/assets/Avatar-rQ2og-6c.js
new file mode 100644
index 0000000..b21f078
--- /dev/null
+++ b/out/renderer/assets/Avatar-rQ2og-6c.js
@@ -0,0 +1,319 @@
+import { i as isImageSupportNativeLazy, o as observeIntersection } from "./Image-DXClIklC.js";
+import { t as tagInjectionKey } from "./Tag-C0oC92WF.js";
+import { aL as createInjectionKey, p as cB, aN as insideModal, m as c, aO as insidePopover, Y as cE, d as defineComponent, x as useConfig, r as ref, G as computed, q as useTheme, ap as useThemeClass, o as onMounted, a8 as watchEffect, a as onBeforeUnmount, E as watch, K as resolveSlot, I as resolveWrappedSlot, l as h, as as inject, bw as avatarLight, ao as createKey, bx as color2Class, ay as VResizeObserver } from "./index-DKaFsuse.js";
+const avatarGroupInjectionKey = createInjectionKey("n-avatar-group");
+const style = cB("avatar", `
+ width: var(--n-merged-size);
+ height: var(--n-merged-size);
+ color: #FFF;
+ font-size: var(--n-font-size);
+ display: inline-flex;
+ position: relative;
+ overflow: hidden;
+ text-align: center;
+ border: var(--n-border);
+ border-radius: var(--n-border-radius);
+ --n-merged-color: var(--n-color);
+ background-color: var(--n-merged-color);
+ transition:
+ border-color .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+`, [insideModal(c("&", "--n-merged-color: var(--n-color-modal);")), insidePopover(c("&", "--n-merged-color: var(--n-color-popover);")), c("img", `
+ width: 100%;
+ height: 100%;
+ `), cE("text", `
+ white-space: nowrap;
+ display: inline-block;
+ position: absolute;
+ left: 50%;
+ top: 50%;
+ `), cB("icon", `
+ vertical-align: bottom;
+ font-size: calc(var(--n-merged-size) - 6px);
+ `), cE("text", "line-height: 1.25")]);
+const avatarProps = Object.assign(Object.assign({}, useTheme.props), {
+ size: [String, Number],
+ src: String,
+ circle: {
+ type: Boolean,
+ default: void 0
+ },
+ objectFit: String,
+ round: {
+ type: Boolean,
+ default: void 0
+ },
+ bordered: {
+ type: Boolean,
+ default: void 0
+ },
+ onError: Function,
+ fallbackSrc: String,
+ intersectionObserverOptions: Object,
+ lazy: Boolean,
+ onLoad: Function,
+ renderPlaceholder: Function,
+ renderFallback: Function,
+ imgProps: Object,
+ /** @deprecated */
+ color: String
+});
+const __unplugin_components_2 = defineComponent({
+ name: "Avatar",
+ props: avatarProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const hasLoadErrorRef = ref(false);
+ let memoedTextHtml = null;
+ const textRef = ref(null);
+ const selfRef = ref(null);
+ const fitTextTransform = () => {
+ const {
+ value: textEl
+ } = textRef;
+ if (textEl) {
+ if (memoedTextHtml === null || memoedTextHtml !== textEl.innerHTML) {
+ memoedTextHtml = textEl.innerHTML;
+ const {
+ value: selfEl
+ } = selfRef;
+ if (selfEl) {
+ const {
+ offsetWidth: elWidth,
+ offsetHeight: elHeight
+ } = selfEl;
+ const {
+ offsetWidth: textWidth,
+ offsetHeight: textHeight
+ } = textEl;
+ const radix = 0.9;
+ const ratio = Math.min(elWidth / textWidth * radix, elHeight / textHeight * radix, 1);
+ textEl.style.transform = `translateX(-50%) translateY(-50%) scale(${ratio})`;
+ }
+ }
+ }
+ };
+ const NAvatarGroup = inject(avatarGroupInjectionKey, null);
+ const mergedSizeRef = computed(() => {
+ const {
+ size
+ } = props;
+ if (size) return size;
+ const {
+ size: avatarGroupSize
+ } = NAvatarGroup || {};
+ if (avatarGroupSize) return avatarGroupSize;
+ return "medium";
+ });
+ const themeRef = useTheme("Avatar", "-avatar", style, avatarLight, props, mergedClsPrefixRef);
+ const TagInjection = inject(tagInjectionKey, null);
+ const mergedRoundRef = computed(() => {
+ if (NAvatarGroup) return true;
+ const {
+ round,
+ circle
+ } = props;
+ if (round !== void 0 || circle !== void 0) return round || circle;
+ if (TagInjection) {
+ return TagInjection.roundRef.value;
+ }
+ return false;
+ });
+ const mergedBorderedRef = computed(() => {
+ if (NAvatarGroup) return true;
+ return props.bordered || false;
+ });
+ const cssVarsRef = computed(() => {
+ const size = mergedSizeRef.value;
+ const round = mergedRoundRef.value;
+ const bordered = mergedBorderedRef.value;
+ const {
+ color: propColor
+ } = props;
+ const {
+ self: {
+ borderRadius,
+ fontSize,
+ color,
+ border,
+ colorModal,
+ colorPopover
+ },
+ common: {
+ cubicBezierEaseInOut
+ }
+ } = themeRef.value;
+ let height;
+ if (typeof size === "number") {
+ height = `${size}px`;
+ } else {
+ height = themeRef.value.self[createKey("height", size)];
+ }
+ return {
+ "--n-font-size": fontSize,
+ "--n-border": bordered ? border : "none",
+ "--n-border-radius": round ? "50%" : borderRadius,
+ "--n-color": propColor || color,
+ "--n-color-modal": propColor || colorModal,
+ "--n-color-popover": propColor || colorPopover,
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-merged-size": `var(--n-avatar-size-override, ${height})`
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("avatar", computed(() => {
+ const size = mergedSizeRef.value;
+ const round = mergedRoundRef.value;
+ const bordered = mergedBorderedRef.value;
+ const {
+ color
+ } = props;
+ let hash = "";
+ if (size) {
+ if (typeof size === "number") {
+ hash += `a${size}`;
+ } else {
+ hash += size[0];
+ }
+ }
+ if (round) {
+ hash += "b";
+ }
+ if (bordered) {
+ hash += "c";
+ }
+ if (color) {
+ hash += color2Class(color);
+ }
+ return hash;
+ }), cssVarsRef, props) : void 0;
+ const shouldStartLoadingRef = ref(!props.lazy);
+ onMounted(() => {
+ if (props.lazy && props.intersectionObserverOptions) {
+ let unobserve;
+ const stopWatchHandle = watchEffect(() => {
+ unobserve === null || unobserve === void 0 ? void 0 : unobserve();
+ unobserve = void 0;
+ if (props.lazy) {
+ unobserve = observeIntersection(selfRef.value, props.intersectionObserverOptions, shouldStartLoadingRef);
+ }
+ });
+ onBeforeUnmount(() => {
+ stopWatchHandle();
+ unobserve === null || unobserve === void 0 ? void 0 : unobserve();
+ });
+ }
+ });
+ watch(() => {
+ var _a;
+ return props.src || ((_a = props.imgProps) === null || _a === void 0 ? void 0 : _a.src);
+ }, () => {
+ hasLoadErrorRef.value = false;
+ });
+ const loadedRef = ref(!props.lazy);
+ return {
+ textRef,
+ selfRef,
+ mergedRoundRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ fitTextTransform,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender,
+ hasLoadError: hasLoadErrorRef,
+ shouldStartLoading: shouldStartLoadingRef,
+ loaded: loadedRef,
+ mergedOnError: (e) => {
+ if (!shouldStartLoadingRef.value) return;
+ hasLoadErrorRef.value = true;
+ const {
+ onError,
+ imgProps: {
+ onError: imgPropsOnError
+ } = {}
+ } = props;
+ onError === null || onError === void 0 ? void 0 : onError(e);
+ imgPropsOnError === null || imgPropsOnError === void 0 ? void 0 : imgPropsOnError(e);
+ },
+ mergedOnLoad: (e) => {
+ const {
+ onLoad,
+ imgProps: {
+ onLoad: imgPropsOnLoad
+ } = {}
+ } = props;
+ onLoad === null || onLoad === void 0 ? void 0 : onLoad(e);
+ imgPropsOnLoad === null || imgPropsOnLoad === void 0 ? void 0 : imgPropsOnLoad(e);
+ loadedRef.value = true;
+ }
+ };
+ },
+ render() {
+ var _a, _b;
+ const {
+ $slots,
+ src,
+ mergedClsPrefix,
+ lazy,
+ onRender,
+ loaded,
+ hasLoadError,
+ imgProps = {}
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ let img;
+ const placeholderNode = !loaded && !hasLoadError && (this.renderPlaceholder ? this.renderPlaceholder() : (_b = (_a = this.$slots).placeholder) === null || _b === void 0 ? void 0 : _b.call(_a));
+ if (this.hasLoadError) {
+ img = this.renderFallback ? this.renderFallback() : resolveSlot($slots.fallback, () => [h("img", {
+ src: this.fallbackSrc,
+ style: {
+ objectFit: this.objectFit
+ }
+ })]);
+ } else {
+ img = resolveWrappedSlot($slots.default, (children) => {
+ if (children) {
+ return h(VResizeObserver, {
+ onResize: this.fitTextTransform
+ }, {
+ default: () => h("span", {
+ ref: "textRef",
+ class: `${mergedClsPrefix}-avatar__text`
+ }, children)
+ });
+ } else if (src || imgProps.src) {
+ const loadSrc = this.src || imgProps.src;
+ return h("img", Object.assign(Object.assign({}, imgProps), {
+ loading: (
+ // If interseciton observer options is set, do not use native lazy
+ isImageSupportNativeLazy && !this.intersectionObserverOptions && lazy ? "lazy" : "eager"
+ ),
+ src: lazy && this.intersectionObserverOptions ? this.shouldStartLoading ? loadSrc : void 0 : loadSrc,
+ "data-image-src": loadSrc,
+ onLoad: this.mergedOnLoad,
+ onError: this.mergedOnError,
+ style: [imgProps.style || "", {
+ objectFit: this.objectFit
+ }, placeholderNode ? {
+ height: "0",
+ width: "0",
+ visibility: "hidden",
+ position: "absolute"
+ } : ""]
+ }));
+ }
+ });
+ }
+ return h("span", {
+ ref: "selfRef",
+ class: [`${mergedClsPrefix}-avatar`, this.themeClass],
+ style: this.cssVars
+ }, img, lazy && placeholderNode);
+ }
+});
+export {
+ __unplugin_components_2 as _
+};
diff --git a/out/renderer/assets/Avatar-rQ2og-6c.js.gz b/out/renderer/assets/Avatar-rQ2og-6c.js.gz
new file mode 100644
index 0000000..7f32948
Binary files /dev/null and b/out/renderer/assets/Avatar-rQ2og-6c.js.gz differ
diff --git a/out/renderer/assets/Drawer-BEJ8Ydua.js b/out/renderer/assets/Drawer-BEJ8Ydua.js
new file mode 100644
index 0000000..dea8270
--- /dev/null
+++ b/out/renderer/assets/Drawer-BEJ8Ydua.js
@@ -0,0 +1,803 @@
+import { d as defineComponent, r as ref, as as inject, G as computed, x as useConfig, F as useRtl, a8 as watchEffect, E as watch, a as onBeforeUnmount, aT as clickoutside, aU as useLockHtmlScroll, $ as provide, w as withDirectives, a6 as vShow, l as h, aV as FocusTrap, ak as Transition, ax as mergeProps, aK as Scrollbar, aW as drawerInjectionKey, aX as drawerBodyInjectionKey, aY as popoverBodyInjectionKey, aZ as modalBodyInjectionKey, m as c, a_ as commonVariables, p as cB, W as cM, Y as cE, a$ as fadeInTransition, aR as isMounted, q as useTheme, C as useMergedState, A as toRef, b0 as useIsComposing, ap as useThemeClass, b1 as LazyTeleport, b2 as drawerLight, b3 as eventEffectNotPerformed, L as call, b4 as zindexable } from "./index-DKaFsuse.js";
+import { f as formatLength } from "./Image-DXClIklC.js";
+const NDrawerBodyWrapper = defineComponent({
+ name: "NDrawerContent",
+ inheritAttrs: false,
+ props: {
+ blockScroll: Boolean,
+ show: {
+ type: Boolean,
+ default: void 0
+ },
+ displayDirective: {
+ type: String,
+ required: true
+ },
+ placement: {
+ type: String,
+ required: true
+ },
+ contentClass: String,
+ contentStyle: [Object, String],
+ nativeScrollbar: {
+ type: Boolean,
+ required: true
+ },
+ scrollbarProps: Object,
+ trapFocus: {
+ type: Boolean,
+ default: true
+ },
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ showMask: {
+ type: [Boolean, String],
+ required: true
+ },
+ maxWidth: Number,
+ maxHeight: Number,
+ minWidth: Number,
+ minHeight: Number,
+ resizable: Boolean,
+ onClickoutside: Function,
+ onAfterLeave: Function,
+ onAfterEnter: Function,
+ onEsc: Function
+ },
+ setup(props) {
+ const displayedRef = ref(!!props.show);
+ const bodyRef = ref(null);
+ const NDrawer = inject(drawerInjectionKey);
+ let startPosition = 0;
+ let memoizedBodyStyleCursor = "";
+ let hoverTimerId = null;
+ const isHoverOnResizeTriggerRef = ref(false);
+ const isDraggingRef = ref(false);
+ const isVertical = computed(() => {
+ return props.placement === "top" || props.placement === "bottom";
+ });
+ const {
+ mergedClsPrefixRef,
+ mergedRtlRef
+ } = useConfig(props);
+ const rtlEnabledRef = useRtl("Drawer", mergedRtlRef, mergedClsPrefixRef);
+ const handleBodyMouseleave = handleBodyMouseup;
+ const handleMousedownResizeTrigger = (e) => {
+ isDraggingRef.value = true;
+ startPosition = isVertical.value ? e.clientY : e.clientX;
+ memoizedBodyStyleCursor = document.body.style.cursor;
+ document.body.style.cursor = isVertical.value ? "ns-resize" : "ew-resize";
+ document.body.addEventListener("mousemove", handleBodyMousemove);
+ document.body.addEventListener("mouseleave", handleBodyMouseleave);
+ document.body.addEventListener("mouseup", handleBodyMouseup);
+ };
+ const handleMouseenterResizeTrigger = () => {
+ if (hoverTimerId !== null) {
+ window.clearTimeout(hoverTimerId);
+ hoverTimerId = null;
+ }
+ if (isDraggingRef.value) {
+ isHoverOnResizeTriggerRef.value = true;
+ } else {
+ hoverTimerId = window.setTimeout(() => {
+ isHoverOnResizeTriggerRef.value = true;
+ }, 300);
+ }
+ };
+ const handleMouseleaveResizeTrigger = () => {
+ if (hoverTimerId !== null) {
+ window.clearTimeout(hoverTimerId);
+ hoverTimerId = null;
+ }
+ isHoverOnResizeTriggerRef.value = false;
+ };
+ const {
+ doUpdateHeight,
+ doUpdateWidth
+ } = NDrawer;
+ const regulateWidth = (size) => {
+ const {
+ maxWidth
+ } = props;
+ if (maxWidth && size > maxWidth) return maxWidth;
+ const {
+ minWidth
+ } = props;
+ if (minWidth && size < minWidth) return minWidth;
+ return size;
+ };
+ const regulateHeight = (size) => {
+ const {
+ maxHeight
+ } = props;
+ if (maxHeight && size > maxHeight) return maxHeight;
+ const {
+ minHeight
+ } = props;
+ if (minHeight && size < minHeight) return minHeight;
+ return size;
+ };
+ function handleBodyMousemove(e) {
+ var _a, _b;
+ if (isDraggingRef.value) {
+ if (isVertical.value) {
+ let height = ((_a = bodyRef.value) === null || _a === void 0 ? void 0 : _a.offsetHeight) || 0;
+ const increment = startPosition - e.clientY;
+ height += props.placement === "bottom" ? increment : -increment;
+ height = regulateHeight(height);
+ doUpdateHeight(height);
+ startPosition = e.clientY;
+ } else {
+ let width = ((_b = bodyRef.value) === null || _b === void 0 ? void 0 : _b.offsetWidth) || 0;
+ const increment = startPosition - e.clientX;
+ width += props.placement === "right" ? increment : -increment;
+ width = regulateWidth(width);
+ doUpdateWidth(width);
+ startPosition = e.clientX;
+ }
+ }
+ }
+ function handleBodyMouseup() {
+ if (isDraggingRef.value) {
+ startPosition = 0;
+ isDraggingRef.value = false;
+ document.body.style.cursor = memoizedBodyStyleCursor;
+ document.body.removeEventListener("mousemove", handleBodyMousemove);
+ document.body.removeEventListener("mouseup", handleBodyMouseup);
+ document.body.removeEventListener("mouseleave", handleBodyMouseleave);
+ }
+ }
+ watchEffect(() => {
+ if (props.show) displayedRef.value = true;
+ });
+ watch(() => props.show, (value) => {
+ if (!value) {
+ handleBodyMouseup();
+ }
+ });
+ onBeforeUnmount(() => {
+ handleBodyMouseup();
+ });
+ const bodyDirectivesRef = computed(() => {
+ const {
+ show
+ } = props;
+ const directives = [[vShow, show]];
+ if (!props.showMask) {
+ directives.push([clickoutside, props.onClickoutside, void 0, {
+ capture: true
+ }]);
+ }
+ return directives;
+ });
+ function handleAfterLeave() {
+ var _a;
+ displayedRef.value = false;
+ (_a = props.onAfterLeave) === null || _a === void 0 ? void 0 : _a.call(props);
+ }
+ useLockHtmlScroll(computed(() => props.blockScroll && displayedRef.value));
+ provide(drawerBodyInjectionKey, bodyRef);
+ provide(popoverBodyInjectionKey, null);
+ provide(modalBodyInjectionKey, null);
+ return {
+ bodyRef,
+ rtlEnabled: rtlEnabledRef,
+ mergedClsPrefix: NDrawer.mergedClsPrefixRef,
+ isMounted: NDrawer.isMountedRef,
+ mergedTheme: NDrawer.mergedThemeRef,
+ displayed: displayedRef,
+ transitionName: computed(() => {
+ return {
+ right: "slide-in-from-right-transition",
+ left: "slide-in-from-left-transition",
+ top: "slide-in-from-top-transition",
+ bottom: "slide-in-from-bottom-transition"
+ }[props.placement];
+ }),
+ handleAfterLeave,
+ bodyDirectives: bodyDirectivesRef,
+ handleMousedownResizeTrigger,
+ handleMouseenterResizeTrigger,
+ handleMouseleaveResizeTrigger,
+ isDragging: isDraggingRef,
+ isHoverOnResizeTrigger: isHoverOnResizeTriggerRef
+ };
+ },
+ render() {
+ const {
+ $slots,
+ mergedClsPrefix
+ } = this;
+ return this.displayDirective === "show" || this.displayed || this.show ? withDirectives(
+ /* Keep the wrapper dom. Make sure the drawer has a host.
+ Nor the detached content will disappear without transition */
+ h("div", {
+ role: "none"
+ }, h(FocusTrap, {
+ disabled: !this.showMask || !this.trapFocus,
+ active: this.show,
+ autoFocus: this.autoFocus,
+ onEsc: this.onEsc
+ }, {
+ default: () => h(Transition, {
+ name: this.transitionName,
+ appear: this.isMounted,
+ onAfterEnter: this.onAfterEnter,
+ onAfterLeave: this.handleAfterLeave
+ }, {
+ default: () => withDirectives(h("div", mergeProps(this.$attrs, {
+ role: "dialog",
+ ref: "bodyRef",
+ "aria-modal": "true",
+ class: [
+ `${mergedClsPrefix}-drawer`,
+ this.rtlEnabled && `${mergedClsPrefix}-drawer--rtl`,
+ `${mergedClsPrefix}-drawer--${this.placement}-placement`,
+ /**
+ * When the mouse is pressed to resize the drawer,
+ * disable text selection
+ */
+ this.isDragging && `${mergedClsPrefix}-drawer--unselectable`,
+ this.nativeScrollbar && `${mergedClsPrefix}-drawer--native-scrollbar`
+ ]
+ }), [this.resizable ? h("div", {
+ class: [`${mergedClsPrefix}-drawer__resize-trigger`, (this.isDragging || this.isHoverOnResizeTrigger) && `${mergedClsPrefix}-drawer__resize-trigger--hover`],
+ onMouseenter: this.handleMouseenterResizeTrigger,
+ onMouseleave: this.handleMouseleaveResizeTrigger,
+ onMousedown: this.handleMousedownResizeTrigger
+ }) : null, this.nativeScrollbar ? h("div", {
+ class: [`${mergedClsPrefix}-drawer-content-wrapper`, this.contentClass],
+ style: this.contentStyle,
+ role: "none"
+ }, $slots) : h(Scrollbar, Object.assign({}, this.scrollbarProps, {
+ contentStyle: this.contentStyle,
+ contentClass: [`${mergedClsPrefix}-drawer-content-wrapper`, this.contentClass],
+ theme: this.mergedTheme.peers.Scrollbar,
+ themeOverrides: this.mergedTheme.peerOverrides.Scrollbar
+ }), $slots)]), this.bodyDirectives)
+ })
+ })),
+ [[vShow, this.displayDirective === "if" || this.displayed || this.show]]
+ ) : null;
+ }
+});
+const {
+ cubicBezierEaseIn: cubicBezierEaseIn$3,
+ cubicBezierEaseOut: cubicBezierEaseOut$3
+} = commonVariables;
+function slideInFromBottomTransition({
+ duration = "0.3s",
+ leaveDuration = "0.2s",
+ name = "slide-in-from-bottom"
+} = {}) {
+ return [c(`&.${name}-transition-leave-active`, {
+ transition: `transform ${leaveDuration} ${cubicBezierEaseIn$3}`
+ }), c(`&.${name}-transition-enter-active`, {
+ transition: `transform ${duration} ${cubicBezierEaseOut$3}`
+ }), c(`&.${name}-transition-enter-to`, {
+ transform: "translateY(0)"
+ }), c(`&.${name}-transition-enter-from`, {
+ transform: "translateY(100%)"
+ }), c(`&.${name}-transition-leave-from`, {
+ transform: "translateY(0)"
+ }), c(`&.${name}-transition-leave-to`, {
+ transform: "translateY(100%)"
+ })];
+}
+const {
+ cubicBezierEaseIn: cubicBezierEaseIn$2,
+ cubicBezierEaseOut: cubicBezierEaseOut$2
+} = commonVariables;
+function slideInFromLeftTransition({
+ duration = "0.3s",
+ leaveDuration = "0.2s",
+ name = "slide-in-from-left"
+} = {}) {
+ return [c(`&.${name}-transition-leave-active`, {
+ transition: `transform ${leaveDuration} ${cubicBezierEaseIn$2}`
+ }), c(`&.${name}-transition-enter-active`, {
+ transition: `transform ${duration} ${cubicBezierEaseOut$2}`
+ }), c(`&.${name}-transition-enter-to`, {
+ transform: "translateX(0)"
+ }), c(`&.${name}-transition-enter-from`, {
+ transform: "translateX(-100%)"
+ }), c(`&.${name}-transition-leave-from`, {
+ transform: "translateX(0)"
+ }), c(`&.${name}-transition-leave-to`, {
+ transform: "translateX(-100%)"
+ })];
+}
+const {
+ cubicBezierEaseIn: cubicBezierEaseIn$1,
+ cubicBezierEaseOut: cubicBezierEaseOut$1
+} = commonVariables;
+function slideInFromRightTransition({
+ duration = "0.3s",
+ leaveDuration = "0.2s",
+ name = "slide-in-from-right"
+} = {}) {
+ return [c(`&.${name}-transition-leave-active`, {
+ transition: `transform ${leaveDuration} ${cubicBezierEaseIn$1}`
+ }), c(`&.${name}-transition-enter-active`, {
+ transition: `transform ${duration} ${cubicBezierEaseOut$1}`
+ }), c(`&.${name}-transition-enter-to`, {
+ transform: "translateX(0)"
+ }), c(`&.${name}-transition-enter-from`, {
+ transform: "translateX(100%)"
+ }), c(`&.${name}-transition-leave-from`, {
+ transform: "translateX(0)"
+ }), c(`&.${name}-transition-leave-to`, {
+ transform: "translateX(100%)"
+ })];
+}
+const {
+ cubicBezierEaseIn,
+ cubicBezierEaseOut
+} = commonVariables;
+function slideInFromTopTransition({
+ duration = "0.3s",
+ leaveDuration = "0.2s",
+ name = "slide-in-from-top"
+} = {}) {
+ return [c(`&.${name}-transition-leave-active`, {
+ transition: `transform ${leaveDuration} ${cubicBezierEaseIn}`
+ }), c(`&.${name}-transition-enter-active`, {
+ transition: `transform ${duration} ${cubicBezierEaseOut}`
+ }), c(`&.${name}-transition-enter-to`, {
+ transform: "translateY(0)"
+ }), c(`&.${name}-transition-enter-from`, {
+ transform: "translateY(-100%)"
+ }), c(`&.${name}-transition-leave-from`, {
+ transform: "translateY(0)"
+ }), c(`&.${name}-transition-leave-to`, {
+ transform: "translateY(-100%)"
+ })];
+}
+const style = c([cB("drawer", `
+ word-break: break-word;
+ line-height: var(--n-line-height);
+ position: absolute;
+ pointer-events: all;
+ box-shadow: var(--n-box-shadow);
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ background-color: var(--n-color);
+ color: var(--n-text-color);
+ box-sizing: border-box;
+ `, [slideInFromRightTransition(), slideInFromLeftTransition(), slideInFromTopTransition(), slideInFromBottomTransition(), cM("unselectable", `
+ user-select: none;
+ -webkit-user-select: none;
+ `), cM("native-scrollbar", [cB("drawer-content-wrapper", `
+ overflow: auto;
+ height: 100%;
+ `)]), cE("resize-trigger", `
+ position: absolute;
+ background-color: #0000;
+ transition: background-color .3s var(--n-bezier);
+ `, [cM("hover", `
+ background-color: var(--n-resize-trigger-color-hover);
+ `)]), cB("drawer-content-wrapper", `
+ box-sizing: border-box;
+ `), cB("drawer-content", `
+ height: 100%;
+ display: flex;
+ flex-direction: column;
+ `, [cM("native-scrollbar", [cB("drawer-body-content-wrapper", `
+ height: 100%;
+ overflow: auto;
+ `)]), cB("drawer-body", `
+ flex: 1 0 0;
+ overflow: hidden;
+ `), cB("drawer-body-content-wrapper", `
+ box-sizing: border-box;
+ padding: var(--n-body-padding);
+ `), cB("drawer-header", `
+ font-weight: var(--n-title-font-weight);
+ line-height: 1;
+ font-size: var(--n-title-font-size);
+ color: var(--n-title-text-color);
+ padding: var(--n-header-padding);
+ transition: border .3s var(--n-bezier);
+ border-bottom: 1px solid var(--n-divider-color);
+ border-bottom: var(--n-header-border-bottom);
+ display: flex;
+ justify-content: space-between;
+ align-items: center;
+ `, [cE("main", `
+ flex: 1;
+ `), cE("close", `
+ margin-left: 6px;
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ `)]), cB("drawer-footer", `
+ display: flex;
+ justify-content: flex-end;
+ border-top: var(--n-footer-border-top);
+ transition: border .3s var(--n-bezier);
+ padding: var(--n-footer-padding);
+ `)]), cM("right-placement", `
+ top: 0;
+ bottom: 0;
+ right: 0;
+ border-top-left-radius: var(--n-border-radius);
+ border-bottom-left-radius: var(--n-border-radius);
+ `, [cE("resize-trigger", `
+ width: 3px;
+ height: 100%;
+ top: 0;
+ left: 0;
+ transform: translateX(-1.5px);
+ cursor: ew-resize;
+ `)]), cM("left-placement", `
+ top: 0;
+ bottom: 0;
+ left: 0;
+ border-top-right-radius: var(--n-border-radius);
+ border-bottom-right-radius: var(--n-border-radius);
+ `, [cE("resize-trigger", `
+ width: 3px;
+ height: 100%;
+ top: 0;
+ right: 0;
+ transform: translateX(1.5px);
+ cursor: ew-resize;
+ `)]), cM("top-placement", `
+ top: 0;
+ left: 0;
+ right: 0;
+ border-bottom-left-radius: var(--n-border-radius);
+ border-bottom-right-radius: var(--n-border-radius);
+ `, [cE("resize-trigger", `
+ width: 100%;
+ height: 3px;
+ bottom: 0;
+ left: 0;
+ transform: translateY(1.5px);
+ cursor: ns-resize;
+ `)]), cM("bottom-placement", `
+ left: 0;
+ bottom: 0;
+ right: 0;
+ border-top-left-radius: var(--n-border-radius);
+ border-top-right-radius: var(--n-border-radius);
+ `, [cE("resize-trigger", `
+ width: 100%;
+ height: 3px;
+ top: 0;
+ left: 0;
+ transform: translateY(-1.5px);
+ cursor: ns-resize;
+ `)])]), c("body", [c(">", [cB("drawer-container", `
+ position: fixed;
+ `)])]), cB("drawer-container", `
+ position: relative;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ pointer-events: none;
+ `, [c("> *", `
+ pointer-events: all;
+ `)]), cB("drawer-mask", `
+ background-color: rgba(0, 0, 0, .3);
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ `, [cM("invisible", `
+ background-color: rgba(0, 0, 0, 0)
+ `), fadeInTransition({
+ enterDuration: "0.2s",
+ leaveDuration: "0.2s",
+ enterCubicBezier: "var(--n-bezier-in)",
+ leaveCubicBezier: "var(--n-bezier-out)"
+})])]);
+const drawerProps = Object.assign(Object.assign({}, useTheme.props), {
+ show: Boolean,
+ width: [Number, String],
+ height: [Number, String],
+ placement: {
+ type: String,
+ default: "right"
+ },
+ maskClosable: {
+ type: Boolean,
+ default: true
+ },
+ showMask: {
+ type: [Boolean, String],
+ default: true
+ },
+ to: [String, Object],
+ displayDirective: {
+ type: String,
+ default: "if"
+ },
+ nativeScrollbar: {
+ type: Boolean,
+ default: true
+ },
+ zIndex: Number,
+ onMaskClick: Function,
+ scrollbarProps: Object,
+ contentClass: String,
+ contentStyle: [Object, String],
+ trapFocus: {
+ type: Boolean,
+ default: true
+ },
+ onEsc: Function,
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ closeOnEsc: {
+ type: Boolean,
+ default: true
+ },
+ blockScroll: {
+ type: Boolean,
+ default: true
+ },
+ maxWidth: Number,
+ maxHeight: Number,
+ minWidth: Number,
+ minHeight: Number,
+ resizable: Boolean,
+ defaultWidth: {
+ type: [Number, String],
+ default: 251
+ },
+ defaultHeight: {
+ type: [Number, String],
+ default: 251
+ },
+ onUpdateWidth: [Function, Array],
+ onUpdateHeight: [Function, Array],
+ "onUpdate:width": [Function, Array],
+ "onUpdate:height": [Function, Array],
+ "onUpdate:show": [Function, Array],
+ onUpdateShow: [Function, Array],
+ onAfterEnter: Function,
+ onAfterLeave: Function,
+ /** @deprecated */
+ drawerStyle: [String, Object],
+ drawerClass: String,
+ target: null,
+ onShow: Function,
+ onHide: Function
+});
+const __unplugin_components_2 = defineComponent({
+ name: "Drawer",
+ inheritAttrs: false,
+ props: drawerProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ namespaceRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const isMountedRef = isMounted();
+ const themeRef = useTheme("Drawer", "-drawer", style, drawerLight, props, mergedClsPrefixRef);
+ const uncontrolledWidthRef = ref(props.defaultWidth);
+ const uncontrolledHeightRef = ref(props.defaultHeight);
+ const mergedWidthRef = useMergedState(toRef(props, "width"), uncontrolledWidthRef);
+ const mergedHeightRef = useMergedState(toRef(props, "height"), uncontrolledHeightRef);
+ const styleWidthRef = computed(() => {
+ const {
+ placement
+ } = props;
+ if (placement === "top" || placement === "bottom") return "";
+ return formatLength(mergedWidthRef.value);
+ });
+ const styleHeightRef = computed(() => {
+ const {
+ placement
+ } = props;
+ if (placement === "left" || placement === "right") return "";
+ return formatLength(mergedHeightRef.value);
+ });
+ const doUpdateWidth = (value) => {
+ const {
+ onUpdateWidth,
+ "onUpdate:width": _onUpdateWidth
+ } = props;
+ if (onUpdateWidth) call(onUpdateWidth, value);
+ if (_onUpdateWidth) call(_onUpdateWidth, value);
+ uncontrolledWidthRef.value = value;
+ };
+ const doUpdateHeight = (value) => {
+ const {
+ onUpdateHeight,
+ "onUpdate:width": _onUpdateHeight
+ } = props;
+ if (onUpdateHeight) call(onUpdateHeight, value);
+ if (_onUpdateHeight) call(_onUpdateHeight, value);
+ uncontrolledHeightRef.value = value;
+ };
+ const mergedBodyStyleRef = computed(() => {
+ return [{
+ width: styleWidthRef.value,
+ height: styleHeightRef.value
+ }, props.drawerStyle || ""];
+ });
+ function handleMaskClick(e) {
+ const {
+ onMaskClick,
+ maskClosable
+ } = props;
+ if (maskClosable) {
+ doUpdateShow(false);
+ }
+ if (onMaskClick) onMaskClick(e);
+ }
+ function handleOutsideClick(e) {
+ handleMaskClick(e);
+ }
+ const isComposingRef = useIsComposing();
+ function handleEsc(e) {
+ var _a;
+ (_a = props.onEsc) === null || _a === void 0 ? void 0 : _a.call(props);
+ if (props.show && props.closeOnEsc && eventEffectNotPerformed(e)) {
+ if (!isComposingRef.value) {
+ doUpdateShow(false);
+ }
+ }
+ }
+ function doUpdateShow(show) {
+ const {
+ onHide,
+ onUpdateShow,
+ "onUpdate:show": _onUpdateShow
+ } = props;
+ if (onUpdateShow) call(onUpdateShow, show);
+ if (_onUpdateShow) call(_onUpdateShow, show);
+ if (onHide && !show) call(onHide, show);
+ }
+ provide(drawerInjectionKey, {
+ isMountedRef,
+ mergedThemeRef: themeRef,
+ mergedClsPrefixRef,
+ doUpdateShow,
+ doUpdateHeight,
+ doUpdateWidth
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseInOut,
+ cubicBezierEaseIn: cubicBezierEaseIn2,
+ cubicBezierEaseOut: cubicBezierEaseOut2
+ },
+ self: {
+ color,
+ textColor,
+ boxShadow,
+ lineHeight,
+ headerPadding,
+ footerPadding,
+ borderRadius,
+ bodyPadding,
+ titleFontSize,
+ titleTextColor,
+ titleFontWeight,
+ headerBorderBottom,
+ footerBorderTop,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ closeIconSize,
+ closeSize,
+ closeBorderRadius,
+ resizableTriggerColorHover
+ }
+ } = themeRef.value;
+ return {
+ "--n-line-height": lineHeight,
+ "--n-color": color,
+ "--n-border-radius": borderRadius,
+ "--n-text-color": textColor,
+ "--n-box-shadow": boxShadow,
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-bezier-out": cubicBezierEaseOut2,
+ "--n-bezier-in": cubicBezierEaseIn2,
+ "--n-header-padding": headerPadding,
+ "--n-body-padding": bodyPadding,
+ "--n-footer-padding": footerPadding,
+ "--n-title-text-color": titleTextColor,
+ "--n-title-font-size": titleFontSize,
+ "--n-title-font-weight": titleFontWeight,
+ "--n-header-border-bottom": headerBorderBottom,
+ "--n-footer-border-top": footerBorderTop,
+ "--n-close-icon-color": closeIconColor,
+ "--n-close-icon-color-hover": closeIconColorHover,
+ "--n-close-icon-color-pressed": closeIconColorPressed,
+ "--n-close-size": closeSize,
+ "--n-close-color-hover": closeColorHover,
+ "--n-close-color-pressed": closeColorPressed,
+ "--n-close-icon-size": closeIconSize,
+ "--n-close-border-radius": closeBorderRadius,
+ "--n-resize-trigger-color-hover": resizableTriggerColorHover
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("drawer", void 0, cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ namespace: namespaceRef,
+ mergedBodyStyle: mergedBodyStyleRef,
+ handleOutsideClick,
+ handleMaskClick,
+ handleEsc,
+ mergedTheme: themeRef,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender,
+ isMounted: isMountedRef
+ };
+ },
+ render() {
+ const {
+ mergedClsPrefix
+ } = this;
+ return h(LazyTeleport, {
+ to: this.to,
+ show: this.show
+ }, {
+ default: () => {
+ var _a;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ return withDirectives(h("div", {
+ class: [`${mergedClsPrefix}-drawer-container`, this.namespace, this.themeClass],
+ style: this.cssVars,
+ role: "none"
+ }, this.showMask ? h(Transition, {
+ name: "fade-in-transition",
+ appear: this.isMounted
+ }, {
+ default: () => this.show ? h("div", {
+ "aria-hidden": true,
+ class: [`${mergedClsPrefix}-drawer-mask`, this.showMask === "transparent" && `${mergedClsPrefix}-drawer-mask--invisible`],
+ onClick: this.handleMaskClick
+ }) : null
+ }) : null, h(NDrawerBodyWrapper, Object.assign({}, this.$attrs, {
+ class: [this.drawerClass, this.$attrs.class],
+ style: [this.mergedBodyStyle, this.$attrs.style],
+ blockScroll: this.blockScroll,
+ contentStyle: this.contentStyle,
+ contentClass: this.contentClass,
+ placement: this.placement,
+ scrollbarProps: this.scrollbarProps,
+ show: this.show,
+ displayDirective: this.displayDirective,
+ nativeScrollbar: this.nativeScrollbar,
+ onAfterEnter: this.onAfterEnter,
+ onAfterLeave: this.onAfterLeave,
+ trapFocus: this.trapFocus,
+ autoFocus: this.autoFocus,
+ resizable: this.resizable,
+ maxHeight: this.maxHeight,
+ minHeight: this.minHeight,
+ maxWidth: this.maxWidth,
+ minWidth: this.minWidth,
+ showMask: this.showMask,
+ onEsc: this.handleEsc,
+ onClickoutside: this.handleOutsideClick
+ }), this.$slots)), [[zindexable, {
+ zIndex: this.zIndex,
+ enabled: this.show
+ }]]);
+ }
+ });
+ }
+});
+export {
+ __unplugin_components_2 as _
+};
diff --git a/out/renderer/assets/Drawer-BEJ8Ydua.js.gz b/out/renderer/assets/Drawer-BEJ8Ydua.js.gz
new file mode 100644
index 0000000..26c87e9
Binary files /dev/null and b/out/renderer/assets/Drawer-BEJ8Ydua.js.gz differ
diff --git a/out/renderer/assets/Ellipsis-D4R5dIX2.js b/out/renderer/assets/Ellipsis-D4R5dIX2.js
new file mode 100644
index 0000000..a30ba00
--- /dev/null
+++ b/out/renderer/assets/Ellipsis-D4R5dIX2.js
@@ -0,0 +1,195 @@
+import { p as cB, V as cNotM, W as cM, q as useTheme, d as defineComponent, b6 as useMergedClsPrefix, b7 as ellipsisLight, r as ref, G as computed, au as onDeactivated, l as h, ax as mergeProps } from "./index-DKaFsuse.js";
+import { _ as __unplugin_components_3 } from "./Image-DXClIklC.js";
+const style = cB("ellipsis", {
+ overflow: "hidden"
+}, [cNotM("line-clamp", `
+ white-space: nowrap;
+ display: inline-block;
+ vertical-align: bottom;
+ max-width: 100%;
+ `), cM("line-clamp", `
+ display: -webkit-inline-box;
+ -webkit-box-orient: vertical;
+ `), cM("cursor-pointer", `
+ cursor: pointer;
+ `)]);
+function createLineClampClass(clsPrefix) {
+ return `${clsPrefix}-ellipsis--line-clamp`;
+}
+function createCursorClass(clsPrefix, cursor) {
+ return `${clsPrefix}-ellipsis--cursor-${cursor}`;
+}
+const ellipsisProps = Object.assign(Object.assign({}, useTheme.props), {
+ expandTrigger: String,
+ lineClamp: [Number, String],
+ tooltip: {
+ type: [Boolean, Object],
+ default: true
+ }
+});
+const __unplugin_components_2 = defineComponent({
+ name: "Ellipsis",
+ inheritAttrs: false,
+ props: ellipsisProps,
+ setup(props, {
+ slots,
+ attrs
+ }) {
+ const mergedClsPrefixRef = useMergedClsPrefix();
+ const mergedTheme = useTheme("Ellipsis", "-ellipsis", style, ellipsisLight, props, mergedClsPrefixRef);
+ const triggerRef = ref(null);
+ const triggerInnerRef = ref(null);
+ const tooltipRef = ref(null);
+ const expandedRef = ref(false);
+ const ellipsisStyleRef = computed(() => {
+ const {
+ lineClamp
+ } = props;
+ const {
+ value: expanded
+ } = expandedRef;
+ if (lineClamp !== void 0) {
+ return {
+ textOverflow: "",
+ "-webkit-line-clamp": expanded ? "" : lineClamp
+ };
+ } else {
+ return {
+ textOverflow: expanded ? "" : "ellipsis",
+ "-webkit-line-clamp": ""
+ };
+ }
+ });
+ function getTooltipDisabled() {
+ let tooltipDisabled = false;
+ const {
+ value: expanded
+ } = expandedRef;
+ if (expanded) return true;
+ const {
+ value: trigger
+ } = triggerRef;
+ if (trigger) {
+ const {
+ lineClamp
+ } = props;
+ syncEllipsisStyle(trigger);
+ if (lineClamp !== void 0) {
+ tooltipDisabled = trigger.scrollHeight <= trigger.offsetHeight;
+ } else {
+ const {
+ value: triggerInner
+ } = triggerInnerRef;
+ if (triggerInner) {
+ tooltipDisabled = triggerInner.getBoundingClientRect().width <= trigger.getBoundingClientRect().width;
+ }
+ }
+ syncCursorStyle(trigger, tooltipDisabled);
+ }
+ return tooltipDisabled;
+ }
+ const handleClickRef = computed(() => {
+ return props.expandTrigger === "click" ? () => {
+ var _a;
+ const {
+ value: expanded
+ } = expandedRef;
+ if (expanded) {
+ (_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.setShow(false);
+ }
+ expandedRef.value = !expanded;
+ } : void 0;
+ });
+ onDeactivated(() => {
+ var _a;
+ if (props.tooltip) {
+ (_a = tooltipRef.value) === null || _a === void 0 ? void 0 : _a.setShow(false);
+ }
+ });
+ const renderTrigger = () => h("span", Object.assign({}, mergeProps(attrs, {
+ class: [`${mergedClsPrefixRef.value}-ellipsis`, props.lineClamp !== void 0 ? createLineClampClass(mergedClsPrefixRef.value) : void 0, props.expandTrigger === "click" ? createCursorClass(mergedClsPrefixRef.value, "pointer") : void 0],
+ style: ellipsisStyleRef.value
+ }), {
+ ref: "triggerRef",
+ onClick: handleClickRef.value,
+ onMouseenter: (
+ // get tooltip disabled will derive cursor style
+ props.expandTrigger === "click" ? getTooltipDisabled : void 0
+ )
+ }), props.lineClamp ? slots : h("span", {
+ ref: "triggerInnerRef"
+ }, slots));
+ function syncEllipsisStyle(trigger) {
+ if (!trigger) return;
+ const latestStyle = ellipsisStyleRef.value;
+ const lineClampClass = createLineClampClass(mergedClsPrefixRef.value);
+ if (props.lineClamp !== void 0) {
+ syncTriggerClass(trigger, lineClampClass, "add");
+ } else {
+ syncTriggerClass(trigger, lineClampClass, "remove");
+ }
+ for (const key in latestStyle) {
+ if (trigger.style[key] !== latestStyle[key]) {
+ trigger.style[key] = latestStyle[key];
+ }
+ }
+ }
+ function syncCursorStyle(trigger, tooltipDisabled) {
+ const cursorClass = createCursorClass(mergedClsPrefixRef.value, "pointer");
+ if (props.expandTrigger === "click" && !tooltipDisabled) {
+ syncTriggerClass(trigger, cursorClass, "add");
+ } else {
+ syncTriggerClass(trigger, cursorClass, "remove");
+ }
+ }
+ function syncTriggerClass(trigger, styleClass, action) {
+ if (action === "add") {
+ if (!trigger.classList.contains(styleClass)) {
+ trigger.classList.add(styleClass);
+ }
+ } else {
+ if (trigger.classList.contains(styleClass)) {
+ trigger.classList.remove(styleClass);
+ }
+ }
+ }
+ return {
+ mergedTheme,
+ triggerRef,
+ triggerInnerRef,
+ tooltipRef,
+ handleClick: handleClickRef,
+ renderTrigger,
+ getTooltipDisabled
+ };
+ },
+ render() {
+ var _a;
+ const {
+ tooltip,
+ renderTrigger,
+ $slots
+ } = this;
+ if (tooltip) {
+ const {
+ mergedTheme
+ } = this;
+ return h(__unplugin_components_3, Object.assign({
+ ref: "tooltipRef",
+ placement: "top"
+ }, tooltip, {
+ getDisabled: this.getTooltipDisabled,
+ theme: mergedTheme.peers.Tooltip,
+ themeOverrides: mergedTheme.peerOverrides.Tooltip
+ }), {
+ trigger: renderTrigger,
+ default: (_a = $slots.tooltip) !== null && _a !== void 0 ? _a : $slots.default
+ });
+ } else {
+ return renderTrigger();
+ }
+ }
+});
+export {
+ __unplugin_components_2 as _
+};
diff --git a/out/renderer/assets/Ellipsis-D4R5dIX2.js.gz b/out/renderer/assets/Ellipsis-D4R5dIX2.js.gz
new file mode 100644
index 0000000..210f650
Binary files /dev/null and b/out/renderer/assets/Ellipsis-D4R5dIX2.js.gz differ
diff --git a/out/renderer/assets/FiraCode-Regular-CRwVj4V2.woff2 b/out/renderer/assets/FiraCode-Regular-CRwVj4V2.woff2
new file mode 100644
index 0000000..d58667c
Binary files /dev/null and b/out/renderer/assets/FiraCode-Regular-CRwVj4V2.woff2 differ
diff --git a/out/renderer/assets/Icon-DucaliTK.js b/out/renderer/assets/Icon-DucaliTK.js
new file mode 100644
index 0000000..c25b924
--- /dev/null
+++ b/out/renderer/assets/Icon-DucaliTK.js
@@ -0,0 +1,111 @@
+import { p as cB, W as cM, m as c, q as useTheme, d as defineComponent, x as useConfig, bv as iconLight, G as computed, ap as useThemeClass, bd as warn, l as h, ax as mergeProps } from "./index-DKaFsuse.js";
+import { f as formatLength } from "./Image-DXClIklC.js";
+const style = cB("icon", `
+ height: 1em;
+ width: 1em;
+ line-height: 1em;
+ text-align: center;
+ display: inline-block;
+ position: relative;
+ fill: currentColor;
+ transform: translateZ(0);
+`, [cM("color-transition", {
+ transition: "color .3s var(--n-bezier)"
+}), cM("depth", {
+ color: "var(--n-color)"
+}, [c("svg", {
+ opacity: "var(--n-opacity)",
+ transition: "opacity .3s var(--n-bezier)"
+})]), c("svg", {
+ height: "1em",
+ width: "1em"
+})]);
+const iconProps = Object.assign(Object.assign({}, useTheme.props), {
+ depth: [String, Number],
+ size: [Number, String],
+ color: String,
+ component: [Object, Function]
+});
+const NIcon = defineComponent({
+ _n_icon__: true,
+ name: "Icon",
+ inheritAttrs: false,
+ props: iconProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Icon", "-icon", style, iconLight, props, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ depth
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self
+ } = themeRef.value;
+ if (depth !== void 0) {
+ const {
+ color,
+ [`opacity${depth}Depth`]: opacity
+ } = self;
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-color": color,
+ "--n-opacity": opacity
+ };
+ }
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-color": "",
+ "--n-opacity": ""
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("icon", computed(() => `${props.depth || "d"}`), cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedStyle: computed(() => {
+ const {
+ size,
+ color
+ } = props;
+ return {
+ fontSize: formatLength(size),
+ color
+ };
+ }),
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ var _a;
+ const {
+ $parent,
+ depth,
+ mergedClsPrefix,
+ component,
+ onRender,
+ themeClass
+ } = this;
+ if ((_a = $parent === null || $parent === void 0 ? void 0 : $parent.$options) === null || _a === void 0 ? void 0 : _a._n_icon__) {
+ warn("icon", "don't wrap `n-icon` inside `n-icon`");
+ }
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ return h("i", mergeProps(this.$attrs, {
+ role: "img",
+ class: [`${mergedClsPrefix}-icon`, themeClass, {
+ [`${mergedClsPrefix}-icon--depth`]: depth,
+ [`${mergedClsPrefix}-icon--color-transition`]: depth !== void 0
+ }],
+ style: [this.cssVars, this.mergedStyle]
+ }), component ? h(component) : this.$slots);
+ }
+});
+export {
+ NIcon as N
+};
diff --git a/out/renderer/assets/Icon-DucaliTK.js.gz b/out/renderer/assets/Icon-DucaliTK.js.gz
new file mode 100644
index 0000000..43f451e
Binary files /dev/null and b/out/renderer/assets/Icon-DucaliTK.js.gz differ
diff --git a/out/renderer/assets/Image-DXClIklC.js b/out/renderer/assets/Image-DXClIklC.js
new file mode 100644
index 0000000..591c965
--- /dev/null
+++ b/out/renderer/assets/Image-DXClIklC.js
@@ -0,0 +1,2864 @@
+import { J as on, aS as off, bA as getNative, bB as root, bC as overArg, bD as isPrototype, bE as isArrayLike, bF as arrayLikeKeys, bG as isArray, bH as isSymbol, bI as MapCache, bJ as toString, bK as toSource, bL as Map$1, bM as baseGetTag, bN as Symbol$1, bO as eq, bP as Uint8Array, bQ as isBuffer, bR as Stack, bS as isTypedArray, bT as isObjectLike, bU as isObject, bV as isLength, bW as isIndex, bX as isArguments, bY as identity, bZ as baseFor, b_ as arrayMap, bk as replaceable, l as h, d as defineComponent, m as c, p as cB, V as cNotM, Y as cE, W as cM, b$ as cCB, x as useConfig, q as useTheme, c0 as popoverLight, r as ref, as as inject, a8 as watchEffect, G as computed, aT as clickoutside, a6 as vShow, ap as useThemeClass, a as onBeforeUnmount, E as watch, A as toRef, c1 as getPreciseEventTarget, $ as provide, ak as Transition, aY as popoverBodyInjectionKey, aX as drawerBodyInjectionKey, aZ as modalBodyInjectionKey, bu as isSlotEmpty, aV as FocusTrap, ax as mergeProps, w as withDirectives, I as resolveWrappedSlot, a3 as Fragment, az as XScrollbar, aR as isMounted, C as useMergedState, D as useMemo, c2 as useCompitable, c3 as getFirstSlotVNode, c4 as cloneVNode, c5 as Text, b4 as zindexable, bf as keep, L as call, c6 as isBrowser, c7 as tooltipLight, aL as createInjectionKey, a$ as fadeInTransition, aM as fadeInScaleUpTransition, c8 as imageLight, N as NBaseIcon, b1 as LazyTeleport, a2 as normalizeStyle, o as onMounted, K as resolveSlot } from "./index-DKaFsuse.js";
+import { d as useAdjustedTo, e as VFollower, V as VTarget, B as Binder, u as useLocale, b as beforeNextFrameOnce } from "./use-locale-DLWAOXez.js";
+const ctxKey = "@@mmoContext";
+const mousemoveoutside = {
+ mounted(el, { value }) {
+ el[ctxKey] = {
+ handler: void 0
+ };
+ if (typeof value === "function") {
+ el[ctxKey].handler = value;
+ on("mousemoveoutside", el, value);
+ }
+ },
+ updated(el, { value }) {
+ const ctx = el[ctxKey];
+ if (typeof value === "function") {
+ if (ctx.handler) {
+ if (ctx.handler !== value) {
+ off("mousemoveoutside", el, ctx.handler);
+ ctx.handler = value;
+ on("mousemoveoutside", el, value);
+ }
+ } else {
+ el[ctxKey].handler = value;
+ on("mousemoveoutside", el, value);
+ }
+ } else {
+ if (ctx.handler) {
+ off("mousemoveoutside", el, ctx.handler);
+ ctx.handler = void 0;
+ }
+ }
+ },
+ unmounted(el) {
+ const { handler } = el[ctxKey];
+ if (handler) {
+ off("mousemoveoutside", el, handler);
+ }
+ el[ctxKey].handler = void 0;
+ }
+};
+const pureNumberRegex = /^(\d|\.)+$/;
+const numberRegex = /(\d|\.)+/;
+function formatLength(length, {
+ c: c2 = 1,
+ offset = 0,
+ attachPx = true
+} = {}) {
+ if (typeof length === "number") {
+ const result = (length + offset) * c2;
+ if (result === 0) return "0";
+ return `${result}px`;
+ } else if (typeof length === "string") {
+ if (pureNumberRegex.test(length)) {
+ const result = (Number(length) + offset) * c2;
+ if (attachPx) {
+ if (result === 0) return "0";
+ return `${result}px`;
+ } else {
+ return `${result}`;
+ }
+ } else {
+ const result = numberRegex.exec(length);
+ if (!result) return length;
+ return length.replace(numberRegex, String((Number(result[0]) + offset) * c2));
+ }
+ }
+ return length;
+}
+function download(url, name) {
+ if (!url) return;
+ const a = document.createElement("a");
+ a.href = url;
+ document.body.appendChild(a);
+ a.click();
+ document.body.removeChild(a);
+}
+let _isJsdom;
+function isJsdom() {
+ if (_isJsdom === void 0) {
+ _isJsdom = navigator.userAgent.includes("Node.js") || navigator.userAgent.includes("jsdom");
+ }
+ return _isJsdom;
+}
+var WeakMap$1 = getNative(root, "WeakMap");
+var nativeKeys = overArg(Object.keys, Object);
+var objectProto$3 = Object.prototype;
+var hasOwnProperty$2 = objectProto$3.hasOwnProperty;
+function baseKeys(object) {
+ if (!isPrototype(object)) {
+ return nativeKeys(object);
+ }
+ var result = [];
+ for (var key in Object(object)) {
+ if (hasOwnProperty$2.call(object, key) && key != "constructor") {
+ result.push(key);
+ }
+ }
+ return result;
+}
+function keys(object) {
+ return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
+}
+var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/;
+function isKey(value, object) {
+ if (isArray(value)) {
+ return false;
+ }
+ var type = typeof value;
+ if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol(value)) {
+ return true;
+ }
+ return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
+}
+var FUNC_ERROR_TEXT = "Expected a function";
+function memoize(func, resolver) {
+ if (typeof func != "function" || resolver != null && typeof resolver != "function") {
+ throw new TypeError(FUNC_ERROR_TEXT);
+ }
+ var memoized = function() {
+ var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
+ if (cache.has(key)) {
+ return cache.get(key);
+ }
+ var result = func.apply(this, args);
+ memoized.cache = cache.set(key, result) || cache;
+ return result;
+ };
+ memoized.cache = new (memoize.Cache || MapCache)();
+ return memoized;
+}
+memoize.Cache = MapCache;
+var MAX_MEMOIZE_SIZE = 500;
+function memoizeCapped(func) {
+ var result = memoize(func, function(key) {
+ if (cache.size === MAX_MEMOIZE_SIZE) {
+ cache.clear();
+ }
+ return key;
+ });
+ var cache = result.cache;
+ return result;
+}
+var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
+var reEscapeChar = /\\(\\)?/g;
+var stringToPath = memoizeCapped(function(string) {
+ var result = [];
+ if (string.charCodeAt(0) === 46) {
+ result.push("");
+ }
+ string.replace(rePropName, function(match, number, quote, subString) {
+ result.push(quote ? subString.replace(reEscapeChar, "$1") : number || match);
+ });
+ return result;
+});
+function castPath(value, object) {
+ if (isArray(value)) {
+ return value;
+ }
+ return isKey(value, object) ? [value] : stringToPath(toString(value));
+}
+var INFINITY = 1 / 0;
+function toKey(value) {
+ if (typeof value == "string" || isSymbol(value)) {
+ return value;
+ }
+ var result = value + "";
+ return result == "0" && 1 / value == -INFINITY ? "-0" : result;
+}
+function baseGet(object, path) {
+ path = castPath(path, object);
+ var index = 0, length = path.length;
+ while (object != null && index < length) {
+ object = object[toKey(path[index++])];
+ }
+ return index && index == length ? object : void 0;
+}
+function get(object, path, defaultValue) {
+ var result = object == null ? void 0 : baseGet(object, path);
+ return result === void 0 ? defaultValue : result;
+}
+function arrayPush(array, values) {
+ var index = -1, length = values.length, offset = array.length;
+ while (++index < length) {
+ array[offset + index] = values[index];
+ }
+ return array;
+}
+function arrayReduce(array, iteratee, accumulator, initAccum) {
+ var index = -1, length = array == null ? 0 : array.length;
+ while (++index < length) {
+ accumulator = iteratee(accumulator, array[index], index, array);
+ }
+ return accumulator;
+}
+function basePropertyOf(object) {
+ return function(key) {
+ return object == null ? void 0 : object[key];
+ };
+}
+var deburredLetters = {
+ // Latin-1 Supplement block.
+ "À": "A",
+ "Á": "A",
+ "Â": "A",
+ "Ã": "A",
+ "Ä": "A",
+ "Å": "A",
+ "à": "a",
+ "á": "a",
+ "â": "a",
+ "ã": "a",
+ "ä": "a",
+ "å": "a",
+ "Ç": "C",
+ "ç": "c",
+ "Ð": "D",
+ "ð": "d",
+ "È": "E",
+ "É": "E",
+ "Ê": "E",
+ "Ë": "E",
+ "è": "e",
+ "é": "e",
+ "ê": "e",
+ "ë": "e",
+ "Ì": "I",
+ "Í": "I",
+ "Î": "I",
+ "Ï": "I",
+ "ì": "i",
+ "í": "i",
+ "î": "i",
+ "ï": "i",
+ "Ñ": "N",
+ "ñ": "n",
+ "Ò": "O",
+ "Ó": "O",
+ "Ô": "O",
+ "Õ": "O",
+ "Ö": "O",
+ "Ø": "O",
+ "ò": "o",
+ "ó": "o",
+ "ô": "o",
+ "õ": "o",
+ "ö": "o",
+ "ø": "o",
+ "Ù": "U",
+ "Ú": "U",
+ "Û": "U",
+ "Ü": "U",
+ "ù": "u",
+ "ú": "u",
+ "û": "u",
+ "ü": "u",
+ "Ý": "Y",
+ "ý": "y",
+ "ÿ": "y",
+ "Æ": "Ae",
+ "æ": "ae",
+ "Þ": "Th",
+ "þ": "th",
+ "ß": "ss",
+ // Latin Extended-A block.
+ "Ā": "A",
+ "Ă": "A",
+ "Ą": "A",
+ "ā": "a",
+ "ă": "a",
+ "ą": "a",
+ "Ć": "C",
+ "Ĉ": "C",
+ "Ċ": "C",
+ "Č": "C",
+ "ć": "c",
+ "ĉ": "c",
+ "ċ": "c",
+ "č": "c",
+ "Ď": "D",
+ "Đ": "D",
+ "ď": "d",
+ "đ": "d",
+ "Ē": "E",
+ "Ĕ": "E",
+ "Ė": "E",
+ "Ę": "E",
+ "Ě": "E",
+ "ē": "e",
+ "ĕ": "e",
+ "ė": "e",
+ "ę": "e",
+ "ě": "e",
+ "Ĝ": "G",
+ "Ğ": "G",
+ "Ġ": "G",
+ "Ģ": "G",
+ "ĝ": "g",
+ "ğ": "g",
+ "ġ": "g",
+ "ģ": "g",
+ "Ĥ": "H",
+ "Ħ": "H",
+ "ĥ": "h",
+ "ħ": "h",
+ "Ĩ": "I",
+ "Ī": "I",
+ "Ĭ": "I",
+ "Į": "I",
+ "İ": "I",
+ "ĩ": "i",
+ "ī": "i",
+ "ĭ": "i",
+ "į": "i",
+ "ı": "i",
+ "Ĵ": "J",
+ "ĵ": "j",
+ "Ķ": "K",
+ "ķ": "k",
+ "ĸ": "k",
+ "Ĺ": "L",
+ "Ļ": "L",
+ "Ľ": "L",
+ "Ŀ": "L",
+ "Ł": "L",
+ "ĺ": "l",
+ "ļ": "l",
+ "ľ": "l",
+ "ŀ": "l",
+ "ł": "l",
+ "Ń": "N",
+ "Ņ": "N",
+ "Ň": "N",
+ "Ŋ": "N",
+ "ń": "n",
+ "ņ": "n",
+ "ň": "n",
+ "ŋ": "n",
+ "Ō": "O",
+ "Ŏ": "O",
+ "Ő": "O",
+ "ō": "o",
+ "ŏ": "o",
+ "ő": "o",
+ "Ŕ": "R",
+ "Ŗ": "R",
+ "Ř": "R",
+ "ŕ": "r",
+ "ŗ": "r",
+ "ř": "r",
+ "Ś": "S",
+ "Ŝ": "S",
+ "Ş": "S",
+ "Š": "S",
+ "ś": "s",
+ "ŝ": "s",
+ "ş": "s",
+ "š": "s",
+ "Ţ": "T",
+ "Ť": "T",
+ "Ŧ": "T",
+ "ţ": "t",
+ "ť": "t",
+ "ŧ": "t",
+ "Ũ": "U",
+ "Ū": "U",
+ "Ŭ": "U",
+ "Ů": "U",
+ "Ű": "U",
+ "Ų": "U",
+ "ũ": "u",
+ "ū": "u",
+ "ŭ": "u",
+ "ů": "u",
+ "ű": "u",
+ "ų": "u",
+ "Ŵ": "W",
+ "ŵ": "w",
+ "Ŷ": "Y",
+ "ŷ": "y",
+ "Ÿ": "Y",
+ "Ź": "Z",
+ "Ż": "Z",
+ "Ž": "Z",
+ "ź": "z",
+ "ż": "z",
+ "ž": "z",
+ "IJ": "IJ",
+ "ij": "ij",
+ "Œ": "Oe",
+ "œ": "oe",
+ "ʼn": "'n",
+ "ſ": "s"
+};
+var deburrLetter = basePropertyOf(deburredLetters);
+var reLatin = /[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g;
+var rsComboMarksRange$1 = "\\u0300-\\u036f", reComboHalfMarksRange$1 = "\\ufe20-\\ufe2f", rsComboSymbolsRange$1 = "\\u20d0-\\u20ff", rsComboRange$1 = rsComboMarksRange$1 + reComboHalfMarksRange$1 + rsComboSymbolsRange$1;
+var rsCombo$1 = "[" + rsComboRange$1 + "]";
+var reComboMark = RegExp(rsCombo$1, "g");
+function deburr(string) {
+ string = toString(string);
+ return string && string.replace(reLatin, deburrLetter).replace(reComboMark, "");
+}
+var reAsciiWord = /[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;
+function asciiWords(string) {
+ return string.match(reAsciiWord) || [];
+}
+var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;
+function hasUnicodeWord(string) {
+ return reHasUnicodeWord.test(string);
+}
+var rsAstralRange = "\\ud800-\\udfff", rsComboMarksRange = "\\u0300-\\u036f", reComboHalfMarksRange = "\\ufe20-\\ufe2f", rsComboSymbolsRange = "\\u20d0-\\u20ff", rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange, rsDingbatRange = "\\u2700-\\u27bf", rsLowerRange = "a-z\\xdf-\\xf6\\xf8-\\xff", rsMathOpRange = "\\xac\\xb1\\xd7\\xf7", rsNonCharRange = "\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf", rsPunctuationRange = "\\u2000-\\u206f", rsSpaceRange = " \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000", rsUpperRange = "A-Z\\xc0-\\xd6\\xd8-\\xde", rsVarRange = "\\ufe0e\\ufe0f", rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;
+var rsApos$1 = "['’]", rsBreak = "[" + rsBreakRange + "]", rsCombo = "[" + rsComboRange + "]", rsDigits = "\\d+", rsDingbat = "[" + rsDingbatRange + "]", rsLower = "[" + rsLowerRange + "]", rsMisc = "[^" + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + "]", rsFitz = "\\ud83c[\\udffb-\\udfff]", rsModifier = "(?:" + rsCombo + "|" + rsFitz + ")", rsNonAstral = "[^" + rsAstralRange + "]", rsRegional = "(?:\\ud83c[\\udde6-\\uddff]){2}", rsSurrPair = "[\\ud800-\\udbff][\\udc00-\\udfff]", rsUpper = "[" + rsUpperRange + "]", rsZWJ = "\\u200d";
+var rsMiscLower = "(?:" + rsLower + "|" + rsMisc + ")", rsMiscUpper = "(?:" + rsUpper + "|" + rsMisc + ")", rsOptContrLower = "(?:" + rsApos$1 + "(?:d|ll|m|re|s|t|ve))?", rsOptContrUpper = "(?:" + rsApos$1 + "(?:D|LL|M|RE|S|T|VE))?", reOptMod = rsModifier + "?", rsOptVar = "[" + rsVarRange + "]?", rsOptJoin = "(?:" + rsZWJ + "(?:" + [rsNonAstral, rsRegional, rsSurrPair].join("|") + ")" + rsOptVar + reOptMod + ")*", rsOrdLower = "\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])", rsOrdUpper = "\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])", rsSeq = rsOptVar + reOptMod + rsOptJoin, rsEmoji = "(?:" + [rsDingbat, rsRegional, rsSurrPair].join("|") + ")" + rsSeq;
+var reUnicodeWord = RegExp([
+ rsUpper + "?" + rsLower + "+" + rsOptContrLower + "(?=" + [rsBreak, rsUpper, "$"].join("|") + ")",
+ rsMiscUpper + "+" + rsOptContrUpper + "(?=" + [rsBreak, rsUpper + rsMiscLower, "$"].join("|") + ")",
+ rsUpper + "?" + rsMiscLower + "+" + rsOptContrLower,
+ rsUpper + "+" + rsOptContrUpper,
+ rsOrdUpper,
+ rsOrdLower,
+ rsDigits,
+ rsEmoji
+].join("|"), "g");
+function unicodeWords(string) {
+ return string.match(reUnicodeWord) || [];
+}
+function words(string, pattern, guard) {
+ string = toString(string);
+ pattern = pattern;
+ if (pattern === void 0) {
+ return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);
+ }
+ return string.match(pattern) || [];
+}
+var rsApos = "['’]";
+var reApos = RegExp(rsApos, "g");
+function createCompounder(callback) {
+ return function(string) {
+ return arrayReduce(words(deburr(string).replace(reApos, "")), callback, "");
+ };
+}
+function arrayFilter(array, predicate) {
+ var index = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
+ while (++index < length) {
+ var value = array[index];
+ if (predicate(value, index, array)) {
+ result[resIndex++] = value;
+ }
+ }
+ return result;
+}
+function stubArray() {
+ return [];
+}
+var objectProto$2 = Object.prototype;
+var propertyIsEnumerable = objectProto$2.propertyIsEnumerable;
+var nativeGetSymbols = Object.getOwnPropertySymbols;
+var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
+ if (object == null) {
+ return [];
+ }
+ object = Object(object);
+ return arrayFilter(nativeGetSymbols(object), function(symbol) {
+ return propertyIsEnumerable.call(object, symbol);
+ });
+};
+function baseGetAllKeys(object, keysFunc, symbolsFunc) {
+ var result = keysFunc(object);
+ return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
+}
+function getAllKeys(object) {
+ return baseGetAllKeys(object, keys, getSymbols);
+}
+var DataView = getNative(root, "DataView");
+var Promise$1 = getNative(root, "Promise");
+var Set$1 = getNative(root, "Set");
+var mapTag$1 = "[object Map]", objectTag$1 = "[object Object]", promiseTag = "[object Promise]", setTag$1 = "[object Set]", weakMapTag = "[object WeakMap]";
+var dataViewTag$1 = "[object DataView]";
+var dataViewCtorString = toSource(DataView), mapCtorString = toSource(Map$1), promiseCtorString = toSource(Promise$1), setCtorString = toSource(Set$1), weakMapCtorString = toSource(WeakMap$1);
+var getTag = baseGetTag;
+if (DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag$1 || Map$1 && getTag(new Map$1()) != mapTag$1 || Promise$1 && getTag(Promise$1.resolve()) != promiseTag || Set$1 && getTag(new Set$1()) != setTag$1 || WeakMap$1 && getTag(new WeakMap$1()) != weakMapTag) {
+ getTag = function(value) {
+ var result = baseGetTag(value), Ctor = result == objectTag$1 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
+ if (ctorString) {
+ switch (ctorString) {
+ case dataViewCtorString:
+ return dataViewTag$1;
+ case mapCtorString:
+ return mapTag$1;
+ case promiseCtorString:
+ return promiseTag;
+ case setCtorString:
+ return setTag$1;
+ case weakMapCtorString:
+ return weakMapTag;
+ }
+ }
+ return result;
+ };
+}
+var HASH_UNDEFINED = "__lodash_hash_undefined__";
+function setCacheAdd(value) {
+ this.__data__.set(value, HASH_UNDEFINED);
+ return this;
+}
+function setCacheHas(value) {
+ return this.__data__.has(value);
+}
+function SetCache(values) {
+ var index = -1, length = values == null ? 0 : values.length;
+ this.__data__ = new MapCache();
+ while (++index < length) {
+ this.add(values[index]);
+ }
+}
+SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
+SetCache.prototype.has = setCacheHas;
+function arraySome(array, predicate) {
+ var index = -1, length = array == null ? 0 : array.length;
+ while (++index < length) {
+ if (predicate(array[index], index, array)) {
+ return true;
+ }
+ }
+ return false;
+}
+function cacheHas(cache, key) {
+ return cache.has(key);
+}
+var COMPARE_PARTIAL_FLAG$5 = 1, COMPARE_UNORDERED_FLAG$3 = 2;
+function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$5, arrLength = array.length, othLength = other.length;
+ if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
+ return false;
+ }
+ var arrStacked = stack.get(array);
+ var othStacked = stack.get(other);
+ if (arrStacked && othStacked) {
+ return arrStacked == other && othStacked == array;
+ }
+ var index = -1, result = true, seen = bitmask & COMPARE_UNORDERED_FLAG$3 ? new SetCache() : void 0;
+ stack.set(array, other);
+ stack.set(other, array);
+ while (++index < arrLength) {
+ var arrValue = array[index], othValue = other[index];
+ if (customizer) {
+ var compared = isPartial ? customizer(othValue, arrValue, index, other, array, stack) : customizer(arrValue, othValue, index, array, other, stack);
+ }
+ if (compared !== void 0) {
+ if (compared) {
+ continue;
+ }
+ result = false;
+ break;
+ }
+ if (seen) {
+ if (!arraySome(other, function(othValue2, othIndex) {
+ if (!cacheHas(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack))) {
+ return seen.push(othIndex);
+ }
+ })) {
+ result = false;
+ break;
+ }
+ } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
+ result = false;
+ break;
+ }
+ }
+ stack["delete"](array);
+ stack["delete"](other);
+ return result;
+}
+function mapToArray(map2) {
+ var index = -1, result = Array(map2.size);
+ map2.forEach(function(value, key) {
+ result[++index] = [key, value];
+ });
+ return result;
+}
+function setToArray(set) {
+ var index = -1, result = Array(set.size);
+ set.forEach(function(value) {
+ result[++index] = value;
+ });
+ return result;
+}
+var COMPARE_PARTIAL_FLAG$4 = 1, COMPARE_UNORDERED_FLAG$2 = 2;
+var boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", mapTag = "[object Map]", numberTag = "[object Number]", regexpTag = "[object RegExp]", setTag = "[object Set]", stringTag = "[object String]", symbolTag = "[object Symbol]";
+var arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]";
+var symbolProto = Symbol$1 ? Symbol$1.prototype : void 0, symbolValueOf = symbolProto ? symbolProto.valueOf : void 0;
+function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {
+ switch (tag) {
+ case dataViewTag:
+ if (object.byteLength != other.byteLength || object.byteOffset != other.byteOffset) {
+ return false;
+ }
+ object = object.buffer;
+ other = other.buffer;
+ case arrayBufferTag:
+ if (object.byteLength != other.byteLength || !equalFunc(new Uint8Array(object), new Uint8Array(other))) {
+ return false;
+ }
+ return true;
+ case boolTag:
+ case dateTag:
+ case numberTag:
+ return eq(+object, +other);
+ case errorTag:
+ return object.name == other.name && object.message == other.message;
+ case regexpTag:
+ case stringTag:
+ return object == other + "";
+ case mapTag:
+ var convert = mapToArray;
+ case setTag:
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$4;
+ convert || (convert = setToArray);
+ if (object.size != other.size && !isPartial) {
+ return false;
+ }
+ var stacked = stack.get(object);
+ if (stacked) {
+ return stacked == other;
+ }
+ bitmask |= COMPARE_UNORDERED_FLAG$2;
+ stack.set(object, other);
+ var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);
+ stack["delete"](object);
+ return result;
+ case symbolTag:
+ if (symbolValueOf) {
+ return symbolValueOf.call(object) == symbolValueOf.call(other);
+ }
+ }
+ return false;
+}
+var COMPARE_PARTIAL_FLAG$3 = 1;
+var objectProto$1 = Object.prototype;
+var hasOwnProperty$1 = objectProto$1.hasOwnProperty;
+function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG$3, objProps = getAllKeys(object), objLength = objProps.length, othProps = getAllKeys(other), othLength = othProps.length;
+ if (objLength != othLength && !isPartial) {
+ return false;
+ }
+ var index = objLength;
+ while (index--) {
+ var key = objProps[index];
+ if (!(isPartial ? key in other : hasOwnProperty$1.call(other, key))) {
+ return false;
+ }
+ }
+ var objStacked = stack.get(object);
+ var othStacked = stack.get(other);
+ if (objStacked && othStacked) {
+ return objStacked == other && othStacked == object;
+ }
+ var result = true;
+ stack.set(object, other);
+ stack.set(other, object);
+ var skipCtor = isPartial;
+ while (++index < objLength) {
+ key = objProps[index];
+ var objValue = object[key], othValue = other[key];
+ if (customizer) {
+ var compared = isPartial ? customizer(othValue, objValue, key, other, object, stack) : customizer(objValue, othValue, key, object, other, stack);
+ }
+ if (!(compared === void 0 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared)) {
+ result = false;
+ break;
+ }
+ skipCtor || (skipCtor = key == "constructor");
+ }
+ if (result && !skipCtor) {
+ var objCtor = object.constructor, othCtor = other.constructor;
+ if (objCtor != othCtor && ("constructor" in object && "constructor" in other) && !(typeof objCtor == "function" && objCtor instanceof objCtor && typeof othCtor == "function" && othCtor instanceof othCtor)) {
+ result = false;
+ }
+ }
+ stack["delete"](object);
+ stack["delete"](other);
+ return result;
+}
+var COMPARE_PARTIAL_FLAG$2 = 1;
+var argsTag = "[object Arguments]", arrayTag = "[object Array]", objectTag = "[object Object]";
+var objectProto = Object.prototype;
+var hasOwnProperty = objectProto.hasOwnProperty;
+function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {
+ var objIsArr = isArray(object), othIsArr = isArray(other), objTag = objIsArr ? arrayTag : getTag(object), othTag = othIsArr ? arrayTag : getTag(other);
+ objTag = objTag == argsTag ? objectTag : objTag;
+ othTag = othTag == argsTag ? objectTag : othTag;
+ var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag;
+ if (isSameTag && isBuffer(object)) {
+ if (!isBuffer(other)) {
+ return false;
+ }
+ objIsArr = true;
+ objIsObj = false;
+ }
+ if (isSameTag && !objIsObj) {
+ stack || (stack = new Stack());
+ return objIsArr || isTypedArray(object) ? equalArrays(object, other, bitmask, customizer, equalFunc, stack) : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
+ }
+ if (!(bitmask & COMPARE_PARTIAL_FLAG$2)) {
+ var objIsWrapped = objIsObj && hasOwnProperty.call(object, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty.call(other, "__wrapped__");
+ if (objIsWrapped || othIsWrapped) {
+ var objUnwrapped = objIsWrapped ? object.value() : object, othUnwrapped = othIsWrapped ? other.value() : other;
+ stack || (stack = new Stack());
+ return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
+ }
+ }
+ if (!isSameTag) {
+ return false;
+ }
+ stack || (stack = new Stack());
+ return equalObjects(object, other, bitmask, customizer, equalFunc, stack);
+}
+function baseIsEqual(value, other, bitmask, customizer, stack) {
+ if (value === other) {
+ return true;
+ }
+ if (value == null || other == null || !isObjectLike(value) && !isObjectLike(other)) {
+ return value !== value && other !== other;
+ }
+ return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);
+}
+var COMPARE_PARTIAL_FLAG$1 = 1, COMPARE_UNORDERED_FLAG$1 = 2;
+function baseIsMatch(object, source, matchData, customizer) {
+ var index = matchData.length, length = index;
+ if (object == null) {
+ return !length;
+ }
+ object = Object(object);
+ while (index--) {
+ var data = matchData[index];
+ if (data[2] ? data[1] !== object[data[0]] : !(data[0] in object)) {
+ return false;
+ }
+ }
+ while (++index < length) {
+ data = matchData[index];
+ var key = data[0], objValue = object[key], srcValue = data[1];
+ if (data[2]) {
+ if (objValue === void 0 && !(key in object)) {
+ return false;
+ }
+ } else {
+ var stack = new Stack();
+ var result;
+ if (!(result === void 0 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG$1 | COMPARE_UNORDERED_FLAG$1, customizer, stack) : result)) {
+ return false;
+ }
+ }
+ }
+ return true;
+}
+function isStrictComparable(value) {
+ return value === value && !isObject(value);
+}
+function getMatchData(object) {
+ var result = keys(object), length = result.length;
+ while (length--) {
+ var key = result[length], value = object[key];
+ result[length] = [key, value, isStrictComparable(value)];
+ }
+ return result;
+}
+function matchesStrictComparable(key, srcValue) {
+ return function(object) {
+ if (object == null) {
+ return false;
+ }
+ return object[key] === srcValue && (srcValue !== void 0 || key in Object(object));
+ };
+}
+function baseMatches(source) {
+ var matchData = getMatchData(source);
+ if (matchData.length == 1 && matchData[0][2]) {
+ return matchesStrictComparable(matchData[0][0], matchData[0][1]);
+ }
+ return function(object) {
+ return object === source || baseIsMatch(object, source, matchData);
+ };
+}
+function baseHasIn(object, key) {
+ return object != null && key in Object(object);
+}
+function hasPath(object, path, hasFunc) {
+ path = castPath(path, object);
+ var index = -1, length = path.length, result = false;
+ while (++index < length) {
+ var key = toKey(path[index]);
+ if (!(result = object != null && hasFunc(object, key))) {
+ break;
+ }
+ object = object[key];
+ }
+ if (result || ++index != length) {
+ return result;
+ }
+ length = object == null ? 0 : object.length;
+ return !!length && isLength(length) && isIndex(key, length) && (isArray(object) || isArguments(object));
+}
+function hasIn(object, path) {
+ return object != null && hasPath(object, path, baseHasIn);
+}
+var COMPARE_PARTIAL_FLAG = 1, COMPARE_UNORDERED_FLAG = 2;
+function baseMatchesProperty(path, srcValue) {
+ if (isKey(path) && isStrictComparable(srcValue)) {
+ return matchesStrictComparable(toKey(path), srcValue);
+ }
+ return function(object) {
+ var objValue = get(object, path);
+ return objValue === void 0 && objValue === srcValue ? hasIn(object, path) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
+ };
+}
+function baseProperty(key) {
+ return function(object) {
+ return object == null ? void 0 : object[key];
+ };
+}
+function basePropertyDeep(path) {
+ return function(object) {
+ return baseGet(object, path);
+ };
+}
+function property(path) {
+ return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
+}
+function baseIteratee(value) {
+ if (typeof value == "function") {
+ return value;
+ }
+ if (value == null) {
+ return identity;
+ }
+ if (typeof value == "object") {
+ return isArray(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value);
+ }
+ return property(value);
+}
+function baseForOwn(object, iteratee) {
+ return object && baseFor(object, iteratee, keys);
+}
+function createBaseEach(eachFunc, fromRight) {
+ return function(collection, iteratee) {
+ if (collection == null) {
+ return collection;
+ }
+ if (!isArrayLike(collection)) {
+ return eachFunc(collection, iteratee);
+ }
+ var length = collection.length, index = -1, iterable = Object(collection);
+ while (++index < length) {
+ if (iteratee(iterable[index], index, iterable) === false) {
+ break;
+ }
+ }
+ return collection;
+ };
+}
+var baseEach = createBaseEach(baseForOwn);
+function baseMap(collection, iteratee) {
+ var index = -1, result = isArrayLike(collection) ? Array(collection.length) : [];
+ baseEach(collection, function(value, key, collection2) {
+ result[++index] = iteratee(value, key, collection2);
+ });
+ return result;
+}
+function map(collection, iteratee) {
+ var func = isArray(collection) ? arrayMap : baseMap;
+ return func(collection, baseIteratee(iteratee));
+}
+var kebabCase = createCompounder(function(result, word, index) {
+ return result + (index ? "-" : "") + word.toLowerCase();
+});
+const DownloadIcon = replaceable("download", () => h("svg", {
+ viewBox: "0 0 16 16",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ fill: "none",
+ "fill-rule": "evenodd"
+}, h("g", {
+ fill: "currentColor",
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M3.5,13 L12.5,13 C12.7761424,13 13,13.2238576 13,13.5 C13,13.7454599 12.8231248,13.9496084 12.5898756,13.9919443 L12.5,14 L3.5,14 C3.22385763,14 3,13.7761424 3,13.5 C3,13.2545401 3.17687516,13.0503916 3.41012437,13.0080557 L3.5,13 L12.5,13 L3.5,13 Z M7.91012437,1.00805567 L8,1 C8.24545989,1 8.44960837,1.17687516 8.49194433,1.41012437 L8.5,1.5 L8.5,10.292 L11.1819805,7.6109127 C11.3555469,7.43734635 11.6249713,7.4180612 11.8198394,7.55305725 L11.8890873,7.6109127 C12.0626536,7.78447906 12.0819388,8.05390346 11.9469427,8.2487716 L11.8890873,8.31801948 L8.35355339,11.8535534 C8.17998704,12.0271197 7.91056264,12.0464049 7.7156945,11.9114088 L7.64644661,11.8535534 L4.1109127,8.31801948 C3.91565056,8.12275734 3.91565056,7.80617485 4.1109127,7.6109127 C4.28447906,7.43734635 4.55390346,7.4180612 4.7487716,7.55305725 L4.81801948,7.6109127 L7.5,10.292 L7.5,1.5 C7.5,1.25454011 7.67687516,1.05039163 7.91012437,1.00805567 L8,1 L7.91012437,1.00805567 Z"
+})))));
+const ResizeSmallIcon = defineComponent({
+ name: "ResizeSmall",
+ render() {
+ return h("svg", {
+ xmlns: "http://www.w3.org/2000/svg",
+ viewBox: "0 0 20 20"
+ }, h("g", {
+ fill: "none"
+ }, h("path", {
+ d: "M5.5 4A1.5 1.5 0 0 0 4 5.5v1a.5.5 0 0 1-1 0v-1A2.5 2.5 0 0 1 5.5 3h1a.5.5 0 0 1 0 1h-1zM16 5.5A1.5 1.5 0 0 0 14.5 4h-1a.5.5 0 0 1 0-1h1A2.5 2.5 0 0 1 17 5.5v1a.5.5 0 0 1-1 0v-1zm0 9a1.5 1.5 0 0 1-1.5 1.5h-1a.5.5 0 0 0 0 1h1a2.5 2.5 0 0 0 2.5-2.5v-1a.5.5 0 0 0-1 0v1zm-12 0A1.5 1.5 0 0 0 5.5 16h1.25a.5.5 0 0 1 0 1H5.5A2.5 2.5 0 0 1 3 14.5v-1.25a.5.5 0 0 1 1 0v1.25zM8.5 7A1.5 1.5 0 0 0 7 8.5v3A1.5 1.5 0 0 0 8.5 13h3a1.5 1.5 0 0 0 1.5-1.5v-3A1.5 1.5 0 0 0 11.5 7h-3zM8 8.5a.5.5 0 0 1 .5-.5h3a.5.5 0 0 1 .5.5v3a.5.5 0 0 1-.5.5h-3a.5.5 0 0 1-.5-.5v-3z",
+ fill: "currentColor"
+ })));
+ }
+});
+const RotateClockwiseIcon = replaceable("rotateClockwise", () => h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("path", {
+ d: "M3 10C3 6.13401 6.13401 3 10 3C13.866 3 17 6.13401 17 10C17 12.7916 15.3658 15.2026 13 16.3265V14.5C13 14.2239 12.7761 14 12.5 14C12.2239 14 12 14.2239 12 14.5V17.5C12 17.7761 12.2239 18 12.5 18H15.5C15.7761 18 16 17.7761 16 17.5C16 17.2239 15.7761 17 15.5 17H13.8758C16.3346 15.6357 18 13.0128 18 10C18 5.58172 14.4183 2 10 2C5.58172 2 2 5.58172 2 10C2 10.2761 2.22386 10.5 2.5 10.5C2.77614 10.5 3 10.2761 3 10Z",
+ fill: "currentColor"
+}), h("path", {
+ d: "M10 12C11.1046 12 12 11.1046 12 10C12 8.89543 11.1046 8 10 8C8.89543 8 8 8.89543 8 10C8 11.1046 8.89543 12 10 12ZM10 11C9.44772 11 9 10.5523 9 10C9 9.44772 9.44772 9 10 9C10.5523 9 11 9.44772 11 10C11 10.5523 10.5523 11 10 11Z",
+ fill: "currentColor"
+})));
+const RotateCounterclockwiseIcon = replaceable("rotateClockwise", () => h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("path", {
+ d: "M17 10C17 6.13401 13.866 3 10 3C6.13401 3 3 6.13401 3 10C3 12.7916 4.63419 15.2026 7 16.3265V14.5C7 14.2239 7.22386 14 7.5 14C7.77614 14 8 14.2239 8 14.5V17.5C8 17.7761 7.77614 18 7.5 18H4.5C4.22386 18 4 17.7761 4 17.5C4 17.2239 4.22386 17 4.5 17H6.12422C3.66539 15.6357 2 13.0128 2 10C2 5.58172 5.58172 2 10 2C14.4183 2 18 5.58172 18 10C18 10.2761 17.7761 10.5 17.5 10.5C17.2239 10.5 17 10.2761 17 10Z",
+ fill: "currentColor"
+}), h("path", {
+ d: "M10 12C8.89543 12 8 11.1046 8 10C8 8.89543 8.89543 8 10 8C11.1046 8 12 8.89543 12 10C12 11.1046 11.1046 12 10 12ZM10 11C10.5523 11 11 10.5523 11 10C11 9.44772 10.5523 9 10 9C9.44772 9 9 9.44772 9 10C9 10.5523 9.44772 11 10 11Z",
+ fill: "currentColor"
+})));
+const ZoomInIcon = replaceable("zoomIn", () => h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("path", {
+ d: "M11.5 8.5C11.5 8.22386 11.2761 8 11 8H9V6C9 5.72386 8.77614 5.5 8.5 5.5C8.22386 5.5 8 5.72386 8 6V8H6C5.72386 8 5.5 8.22386 5.5 8.5C5.5 8.77614 5.72386 9 6 9H8V11C8 11.2761 8.22386 11.5 8.5 11.5C8.77614 11.5 9 11.2761 9 11V9H11C11.2761 9 11.5 8.77614 11.5 8.5Z",
+ fill: "currentColor"
+}), h("path", {
+ d: "M8.5 3C11.5376 3 14 5.46243 14 8.5C14 9.83879 13.5217 11.0659 12.7266 12.0196L16.8536 16.1464C17.0488 16.3417 17.0488 16.6583 16.8536 16.8536C16.68 17.0271 16.4106 17.0464 16.2157 16.9114L16.1464 16.8536L12.0196 12.7266C11.0659 13.5217 9.83879 14 8.5 14C5.46243 14 3 11.5376 3 8.5C3 5.46243 5.46243 3 8.5 3ZM8.5 4C6.01472 4 4 6.01472 4 8.5C4 10.9853 6.01472 13 8.5 13C10.9853 13 13 10.9853 13 8.5C13 6.01472 10.9853 4 8.5 4Z",
+ fill: "currentColor"
+})));
+const ZoomOutIcon = replaceable("zoomOut", () => h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("path", {
+ d: "M11 8C11.2761 8 11.5 8.22386 11.5 8.5C11.5 8.77614 11.2761 9 11 9H6C5.72386 9 5.5 8.77614 5.5 8.5C5.5 8.22386 5.72386 8 6 8H11Z",
+ fill: "currentColor"
+}), h("path", {
+ d: "M14 8.5C14 5.46243 11.5376 3 8.5 3C5.46243 3 3 5.46243 3 8.5C3 11.5376 5.46243 14 8.5 14C9.83879 14 11.0659 13.5217 12.0196 12.7266L16.1464 16.8536L16.2157 16.9114C16.4106 17.0464 16.68 17.0271 16.8536 16.8536C17.0488 16.6583 17.0488 16.3417 16.8536 16.1464L12.7266 12.0196C13.5217 11.0659 14 9.83879 14 8.5ZM4 8.5C4 6.01472 6.01472 4 8.5 4C10.9853 4 13 6.01472 13 8.5C13 10.9853 10.9853 13 8.5 13C6.01472 13 4 10.9853 4 8.5Z",
+ fill: "currentColor"
+})));
+const oppositePlacement = {
+ top: "bottom",
+ bottom: "top",
+ left: "right",
+ right: "left"
+};
+const arrowSize = "var(--n-arrow-height) * 1.414";
+const style$1 = c([cB("popover", `
+ transition:
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ position: relative;
+ font-size: var(--n-font-size);
+ color: var(--n-text-color);
+ box-shadow: var(--n-box-shadow);
+ word-break: break-word;
+ `, [c(">", [cB("scrollbar", `
+ height: inherit;
+ max-height: inherit;
+ `)]), cNotM("raw", `
+ background-color: var(--n-color);
+ border-radius: var(--n-border-radius);
+ `, [cNotM("scrollable", [cNotM("show-header-or-footer", "padding: var(--n-padding);")])]), cE("header", `
+ padding: var(--n-padding);
+ border-bottom: 1px solid var(--n-divider-color);
+ transition: border-color .3s var(--n-bezier);
+ `), cE("footer", `
+ padding: var(--n-padding);
+ border-top: 1px solid var(--n-divider-color);
+ transition: border-color .3s var(--n-bezier);
+ `), cM("scrollable, show-header-or-footer", [cE("content", `
+ padding: var(--n-padding);
+ `)])]), cB("popover-shared", `
+ transform-origin: inherit;
+ `, [
+ cB("popover-arrow-wrapper", `
+ position: absolute;
+ overflow: hidden;
+ pointer-events: none;
+ `, [cB("popover-arrow", `
+ transition: background-color .3s var(--n-bezier);
+ position: absolute;
+ display: block;
+ width: calc(${arrowSize});
+ height: calc(${arrowSize});
+ box-shadow: 0 0 8px 0 rgba(0, 0, 0, .12);
+ transform: rotate(45deg);
+ background-color: var(--n-color);
+ pointer-events: all;
+ `)]),
+ // body transition
+ c("&.popover-transition-enter-from, &.popover-transition-leave-to", `
+ opacity: 0;
+ transform: scale(.85);
+ `),
+ c("&.popover-transition-enter-to, &.popover-transition-leave-from", `
+ transform: scale(1);
+ opacity: 1;
+ `),
+ c("&.popover-transition-enter-active", `
+ transition:
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier),
+ opacity .15s var(--n-bezier-ease-out),
+ transform .15s var(--n-bezier-ease-out);
+ `),
+ c("&.popover-transition-leave-active", `
+ transition:
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier),
+ opacity .15s var(--n-bezier-ease-in),
+ transform .15s var(--n-bezier-ease-in);
+ `)
+]), placementStyle("top-start", `
+ top: calc(${arrowSize} / -2);
+ left: calc(${getArrowOffset("top-start")} - var(--v-offset-left));
+ `), placementStyle("top", `
+ top: calc(${arrowSize} / -2);
+ transform: translateX(calc(${arrowSize} / -2)) rotate(45deg);
+ left: 50%;
+ `), placementStyle("top-end", `
+ top: calc(${arrowSize} / -2);
+ right: calc(${getArrowOffset("top-end")} + var(--v-offset-left));
+ `), placementStyle("bottom-start", `
+ bottom: calc(${arrowSize} / -2);
+ left: calc(${getArrowOffset("bottom-start")} - var(--v-offset-left));
+ `), placementStyle("bottom", `
+ bottom: calc(${arrowSize} / -2);
+ transform: translateX(calc(${arrowSize} / -2)) rotate(45deg);
+ left: 50%;
+ `), placementStyle("bottom-end", `
+ bottom: calc(${arrowSize} / -2);
+ right: calc(${getArrowOffset("bottom-end")} + var(--v-offset-left));
+ `), placementStyle("left-start", `
+ left: calc(${arrowSize} / -2);
+ top: calc(${getArrowOffset("left-start")} - var(--v-offset-top));
+ `), placementStyle("left", `
+ left: calc(${arrowSize} / -2);
+ transform: translateY(calc(${arrowSize} / -2)) rotate(45deg);
+ top: 50%;
+ `), placementStyle("left-end", `
+ left: calc(${arrowSize} / -2);
+ bottom: calc(${getArrowOffset("left-end")} + var(--v-offset-top));
+ `), placementStyle("right-start", `
+ right: calc(${arrowSize} / -2);
+ top: calc(${getArrowOffset("right-start")} - var(--v-offset-top));
+ `), placementStyle("right", `
+ right: calc(${arrowSize} / -2);
+ transform: translateY(calc(${arrowSize} / -2)) rotate(45deg);
+ top: 50%;
+ `), placementStyle("right-end", `
+ right: calc(${arrowSize} / -2);
+ bottom: calc(${getArrowOffset("right-end")} + var(--v-offset-top));
+ `), ...map({
+ top: ["right-start", "left-start"],
+ right: ["top-end", "bottom-end"],
+ bottom: ["right-end", "left-end"],
+ left: ["top-start", "bottom-start"]
+}, (placements, direction) => {
+ const isVertical = ["right", "left"].includes(direction);
+ const sizeType = isVertical ? "width" : "height";
+ return placements.map((placement) => {
+ const isReverse = placement.split("-")[1] === "end";
+ const targetSize = `var(--v-target-${sizeType}, 0px)`;
+ const centerOffset = `calc((${targetSize} - ${arrowSize}) / 2)`;
+ const offset = getArrowOffset(placement);
+ return c(`[v-placement="${placement}"] >`, [cB("popover-shared", [cM("center-arrow", [cB("popover-arrow", `${direction}: calc(max(${centerOffset}, ${offset}) ${isReverse ? "+" : "-"} var(--v-offset-${isVertical ? "left" : "top"}));`)])])]);
+ });
+})]);
+function getArrowOffset(placement) {
+ return ["top", "bottom"].includes(placement.split("-")[0]) ? "var(--n-arrow-offset)" : "var(--n-arrow-offset-vertical)";
+}
+function placementStyle(placement, arrowStyleLiteral) {
+ const position = placement.split("-")[0];
+ const sizeStyle = ["top", "bottom"].includes(position) ? "height: var(--n-space-arrow);" : "width: var(--n-space-arrow);";
+ return c(`[v-placement="${placement}"] >`, [cB("popover-shared", `
+ margin-${oppositePlacement[position]}: var(--n-space);
+ `, [cM("show-arrow", `
+ margin-${oppositePlacement[position]}: var(--n-space-arrow);
+ `), cM("overlap", `
+ margin: 0;
+ `), cCB("popover-arrow-wrapper", `
+ right: 0;
+ left: 0;
+ top: 0;
+ bottom: 0;
+ ${position}: 100%;
+ ${oppositePlacement[position]}: auto;
+ ${sizeStyle}
+ `, [cB("popover-arrow", arrowStyleLiteral)])])]);
+}
+const popoverBodyProps = Object.assign(Object.assign({}, useTheme.props), {
+ to: useAdjustedTo.propTo,
+ show: Boolean,
+ trigger: String,
+ showArrow: Boolean,
+ delay: Number,
+ duration: Number,
+ raw: Boolean,
+ arrowPointToCenter: Boolean,
+ arrowClass: String,
+ arrowStyle: [String, Object],
+ arrowWrapperClass: String,
+ arrowWrapperStyle: [String, Object],
+ displayDirective: String,
+ x: Number,
+ y: Number,
+ flip: Boolean,
+ overlap: Boolean,
+ placement: String,
+ width: [Number, String],
+ keepAliveOnHover: Boolean,
+ scrollable: Boolean,
+ contentClass: String,
+ contentStyle: [Object, String],
+ headerClass: String,
+ headerStyle: [Object, String],
+ footerClass: String,
+ footerStyle: [Object, String],
+ // private
+ internalDeactivateImmediately: Boolean,
+ animated: Boolean,
+ onClickoutside: Function,
+ internalTrapFocus: Boolean,
+ internalOnAfterLeave: Function,
+ // deprecated
+ minWidth: Number,
+ maxWidth: Number
+});
+function renderArrow({
+ arrowClass,
+ arrowStyle,
+ arrowWrapperClass,
+ arrowWrapperStyle,
+ clsPrefix
+}) {
+ return h("div", {
+ key: "__popover-arrow__",
+ style: arrowWrapperStyle,
+ class: [`${clsPrefix}-popover-arrow-wrapper`, arrowWrapperClass]
+ }, h("div", {
+ class: [`${clsPrefix}-popover-arrow`, arrowClass],
+ style: arrowStyle
+ }));
+}
+const NPopoverBody = defineComponent({
+ name: "PopoverBody",
+ inheritAttrs: false,
+ props: popoverBodyProps,
+ setup(props, {
+ slots,
+ attrs
+ }) {
+ const {
+ namespaceRef,
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Popover", "-popover", style$1, popoverLight, props, mergedClsPrefixRef);
+ const followerRef = ref(null);
+ const NPopover = inject("NPopover");
+ const bodyRef = ref(null);
+ const followerEnabledRef = ref(props.show);
+ const displayedRef = ref(false);
+ watchEffect(() => {
+ const {
+ show
+ } = props;
+ if (show && !isJsdom() && !props.internalDeactivateImmediately) {
+ displayedRef.value = true;
+ }
+ });
+ const directivesRef = computed(() => {
+ const {
+ trigger,
+ onClickoutside
+ } = props;
+ const directives = [];
+ const {
+ positionManuallyRef: {
+ value: positionManually
+ }
+ } = NPopover;
+ if (!positionManually) {
+ if (trigger === "click" && !onClickoutside) {
+ directives.push([clickoutside, handleClickOutside, void 0, {
+ capture: true
+ }]);
+ }
+ if (trigger === "hover") {
+ directives.push([mousemoveoutside, handleMouseMoveOutside]);
+ }
+ }
+ if (onClickoutside) {
+ directives.push([clickoutside, handleClickOutside, void 0, {
+ capture: true
+ }]);
+ }
+ if (props.displayDirective === "show" || props.animated && displayedRef.value) {
+ directives.push([vShow, props.show]);
+ }
+ return directives;
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseInOut,
+ cubicBezierEaseIn,
+ cubicBezierEaseOut
+ },
+ self: {
+ space,
+ spaceArrow,
+ padding,
+ fontSize,
+ textColor,
+ dividerColor,
+ color,
+ boxShadow,
+ borderRadius,
+ arrowHeight,
+ arrowOffset,
+ arrowOffsetVertical
+ }
+ } = themeRef.value;
+ return {
+ "--n-box-shadow": boxShadow,
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-bezier-ease-in": cubicBezierEaseIn,
+ "--n-bezier-ease-out": cubicBezierEaseOut,
+ "--n-font-size": fontSize,
+ "--n-text-color": textColor,
+ "--n-color": color,
+ "--n-divider-color": dividerColor,
+ "--n-border-radius": borderRadius,
+ "--n-arrow-height": arrowHeight,
+ "--n-arrow-offset": arrowOffset,
+ "--n-arrow-offset-vertical": arrowOffsetVertical,
+ "--n-padding": padding,
+ "--n-space": space,
+ "--n-space-arrow": spaceArrow
+ };
+ });
+ const styleRef = computed(() => {
+ const width = props.width === "trigger" ? void 0 : formatLength(props.width);
+ const style2 = [];
+ if (width) {
+ style2.push({
+ width
+ });
+ }
+ const {
+ maxWidth,
+ minWidth
+ } = props;
+ if (maxWidth) {
+ style2.push({
+ maxWidth: formatLength(maxWidth)
+ });
+ }
+ if (minWidth) {
+ style2.push({
+ maxWidth: formatLength(minWidth)
+ });
+ }
+ if (!inlineThemeDisabled) {
+ style2.push(cssVarsRef.value);
+ }
+ return style2;
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("popover", void 0, cssVarsRef, props) : void 0;
+ NPopover.setBodyInstance({
+ syncPosition
+ });
+ onBeforeUnmount(() => {
+ NPopover.setBodyInstance(null);
+ });
+ watch(toRef(props, "show"), (value) => {
+ if (props.animated) return;
+ if (value) {
+ followerEnabledRef.value = true;
+ } else {
+ followerEnabledRef.value = false;
+ }
+ });
+ function syncPosition() {
+ var _a;
+ (_a = followerRef.value) === null || _a === void 0 ? void 0 : _a.syncPosition();
+ }
+ function handleMouseEnter(e) {
+ if (props.trigger === "hover" && props.keepAliveOnHover && props.show) {
+ NPopover.handleMouseEnter(e);
+ }
+ }
+ function handleMouseLeave(e) {
+ if (props.trigger === "hover" && props.keepAliveOnHover) {
+ NPopover.handleMouseLeave(e);
+ }
+ }
+ function handleMouseMoveOutside(e) {
+ if (props.trigger === "hover" && !getTriggerElement().contains(getPreciseEventTarget(e))) {
+ NPopover.handleMouseMoveOutside(e);
+ }
+ }
+ function handleClickOutside(e) {
+ if (props.trigger === "click" && !getTriggerElement().contains(getPreciseEventTarget(e)) || props.onClickoutside) {
+ NPopover.handleClickOutside(e);
+ }
+ }
+ function getTriggerElement() {
+ return NPopover.getTriggerElement();
+ }
+ provide(popoverBodyInjectionKey, bodyRef);
+ provide(drawerBodyInjectionKey, null);
+ provide(modalBodyInjectionKey, null);
+ function renderContentNode() {
+ themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender();
+ const shouldRenderDom = props.displayDirective === "show" || props.show || props.animated && displayedRef.value;
+ if (!shouldRenderDom) {
+ return null;
+ }
+ let contentNode;
+ const renderBody = NPopover.internalRenderBodyRef.value;
+ const {
+ value: mergedClsPrefix
+ } = mergedClsPrefixRef;
+ if (!renderBody) {
+ const {
+ value: extraClass
+ } = NPopover.extraClassRef;
+ const {
+ internalTrapFocus
+ } = props;
+ const hasHeaderOrFooter = !isSlotEmpty(slots.header) || !isSlotEmpty(slots.footer);
+ const renderContentInnerNode = () => {
+ var _a, _b;
+ const body = hasHeaderOrFooter ? h(Fragment, null, resolveWrappedSlot(slots.header, (children) => {
+ return children ? h("div", {
+ class: [`${mergedClsPrefix}-popover__header`, props.headerClass],
+ style: props.headerStyle
+ }, children) : null;
+ }), resolveWrappedSlot(slots.default, (children) => {
+ return children ? h("div", {
+ class: [`${mergedClsPrefix}-popover__content`, props.contentClass],
+ style: props.contentStyle
+ }, slots) : null;
+ }), resolveWrappedSlot(slots.footer, (children) => {
+ return children ? h("div", {
+ class: [`${mergedClsPrefix}-popover__footer`, props.footerClass],
+ style: props.footerStyle
+ }, children) : null;
+ })) : props.scrollable ? (_a = slots.default) === null || _a === void 0 ? void 0 : _a.call(slots) : h("div", {
+ class: [`${mergedClsPrefix}-popover__content`, props.contentClass],
+ style: props.contentStyle
+ }, slots);
+ const maybeScrollableBody = props.scrollable ? h(XScrollbar, {
+ contentClass: hasHeaderOrFooter ? void 0 : `${mergedClsPrefix}-popover__content ${(_b = props.contentClass) !== null && _b !== void 0 ? _b : ""}`,
+ contentStyle: hasHeaderOrFooter ? void 0 : props.contentStyle
+ }, {
+ default: () => body
+ }) : body;
+ const arrow = props.showArrow ? renderArrow({
+ arrowClass: props.arrowClass,
+ arrowStyle: props.arrowStyle,
+ arrowWrapperClass: props.arrowWrapperClass,
+ arrowWrapperStyle: props.arrowWrapperStyle,
+ clsPrefix: mergedClsPrefix
+ }) : null;
+ return [maybeScrollableBody, arrow];
+ };
+ contentNode = h("div", mergeProps({
+ class: [`${mergedClsPrefix}-popover`, `${mergedClsPrefix}-popover-shared`, themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass.value, extraClass.map((v) => `${mergedClsPrefix}-${v}`), {
+ [`${mergedClsPrefix}-popover--scrollable`]: props.scrollable,
+ [`${mergedClsPrefix}-popover--show-header-or-footer`]: hasHeaderOrFooter,
+ [`${mergedClsPrefix}-popover--raw`]: props.raw,
+ [`${mergedClsPrefix}-popover-shared--overlap`]: props.overlap,
+ [`${mergedClsPrefix}-popover-shared--show-arrow`]: props.showArrow,
+ [`${mergedClsPrefix}-popover-shared--center-arrow`]: props.arrowPointToCenter
+ }],
+ ref: bodyRef,
+ style: styleRef.value,
+ onKeydown: NPopover.handleKeydown,
+ onMouseenter: handleMouseEnter,
+ onMouseleave: handleMouseLeave
+ }, attrs), internalTrapFocus ? h(FocusTrap, {
+ active: props.show,
+ autoFocus: true
+ }, {
+ default: renderContentInnerNode
+ }) : renderContentInnerNode());
+ } else {
+ contentNode = renderBody(
+ // The popover class and overlap class must exists, they will be used
+ // to place the body & transition animation.
+ // Shadow class exists for reuse box-shadow.
+ [`${mergedClsPrefix}-popover-shared`, themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass.value, props.overlap && `${mergedClsPrefix}-popover-shared--overlap`, props.showArrow && `${mergedClsPrefix}-popover-shared--show-arrow`, props.arrowPointToCenter && `${mergedClsPrefix}-popover-shared--center-arrow`],
+ bodyRef,
+ styleRef.value,
+ handleMouseEnter,
+ handleMouseLeave
+ );
+ }
+ return withDirectives(contentNode, directivesRef.value);
+ }
+ return {
+ displayed: displayedRef,
+ namespace: namespaceRef,
+ isMounted: NPopover.isMountedRef,
+ zIndex: NPopover.zIndexRef,
+ followerRef,
+ adjustedTo: useAdjustedTo(props),
+ followerEnabled: followerEnabledRef,
+ renderContentNode
+ };
+ },
+ render() {
+ return h(VFollower, {
+ ref: "followerRef",
+ zIndex: this.zIndex,
+ show: this.show,
+ enabled: this.followerEnabled,
+ to: this.adjustedTo,
+ x: this.x,
+ y: this.y,
+ flip: this.flip,
+ placement: this.placement,
+ containerClass: this.namespace,
+ overlap: this.overlap,
+ width: this.width === "trigger" ? "target" : void 0,
+ teleportDisabled: this.adjustedTo === useAdjustedTo.tdkey
+ }, {
+ default: () => {
+ return this.animated ? h(Transition, {
+ name: "popover-transition",
+ appear: this.isMounted,
+ // Don't use watch to enable follower, since the transition may
+ // make position sync timing very subtle and buggy.
+ onEnter: () => {
+ this.followerEnabled = true;
+ },
+ onAfterLeave: () => {
+ var _a;
+ (_a = this.internalOnAfterLeave) === null || _a === void 0 ? void 0 : _a.call(this);
+ this.followerEnabled = false;
+ this.displayed = false;
+ }
+ }, {
+ default: this.renderContentNode
+ }) : this.renderContentNode();
+ }
+ });
+ }
+});
+const bodyPropKeys = Object.keys(popoverBodyProps);
+const triggerEventMap = {
+ focus: ["onFocus", "onBlur"],
+ click: ["onClick"],
+ hover: ["onMouseenter", "onMouseleave"],
+ manual: [],
+ nested: ["onFocus", "onBlur", "onMouseenter", "onMouseleave", "onClick"]
+};
+function appendEvents(vNode, trigger, events) {
+ triggerEventMap[trigger].forEach((eventName) => {
+ if (!vNode.props) {
+ vNode.props = {};
+ } else {
+ vNode.props = Object.assign({}, vNode.props);
+ }
+ const originalHandler = vNode.props[eventName];
+ const handler = events[eventName];
+ if (!originalHandler) {
+ vNode.props[eventName] = handler;
+ } else {
+ vNode.props[eventName] = (...args) => {
+ originalHandler(...args);
+ handler(...args);
+ };
+ }
+ });
+}
+const popoverBaseProps = {
+ show: {
+ type: Boolean,
+ default: void 0
+ },
+ defaultShow: Boolean,
+ showArrow: {
+ type: Boolean,
+ default: true
+ },
+ trigger: {
+ type: String,
+ default: "hover"
+ },
+ delay: {
+ type: Number,
+ default: 100
+ },
+ duration: {
+ type: Number,
+ default: 100
+ },
+ raw: Boolean,
+ placement: {
+ type: String,
+ default: "top"
+ },
+ x: Number,
+ y: Number,
+ arrowPointToCenter: Boolean,
+ disabled: Boolean,
+ getDisabled: Function,
+ displayDirective: {
+ type: String,
+ default: "if"
+ },
+ arrowClass: String,
+ arrowStyle: [String, Object],
+ arrowWrapperClass: String,
+ arrowWrapperStyle: [String, Object],
+ flip: {
+ type: Boolean,
+ default: true
+ },
+ animated: {
+ type: Boolean,
+ default: true
+ },
+ width: {
+ type: [Number, String],
+ default: void 0
+ },
+ overlap: Boolean,
+ keepAliveOnHover: {
+ type: Boolean,
+ default: true
+ },
+ zIndex: Number,
+ to: useAdjustedTo.propTo,
+ scrollable: Boolean,
+ contentClass: String,
+ contentStyle: [Object, String],
+ headerClass: String,
+ headerStyle: [Object, String],
+ footerClass: String,
+ footerStyle: [Object, String],
+ // events
+ onClickoutside: Function,
+ "onUpdate:show": [Function, Array],
+ onUpdateShow: [Function, Array],
+ // internal
+ internalDeactivateImmediately: Boolean,
+ internalSyncTargetWithParent: Boolean,
+ internalInheritedEventHandlers: {
+ type: Array,
+ default: () => []
+ },
+ internalTrapFocus: Boolean,
+ internalExtraClass: {
+ type: Array,
+ default: () => []
+ },
+ // deprecated
+ onShow: [Function, Array],
+ onHide: [Function, Array],
+ arrow: {
+ type: Boolean,
+ default: void 0
+ },
+ minWidth: Number,
+ maxWidth: Number
+};
+const popoverProps = Object.assign(Object.assign(Object.assign({}, useTheme.props), popoverBaseProps), {
+ internalOnAfterLeave: Function,
+ internalRenderBody: Function
+});
+const __unplugin_components_5 = defineComponent({
+ name: "Popover",
+ inheritAttrs: false,
+ props: popoverProps,
+ __popover__: true,
+ setup(props) {
+ const isMountedRef = isMounted();
+ const binderInstRef = ref(null);
+ const controlledShowRef = computed(() => props.show);
+ const uncontrolledShowRef = ref(props.defaultShow);
+ const mergedShowWithoutDisabledRef = useMergedState(controlledShowRef, uncontrolledShowRef);
+ const mergedShowConsideringDisabledPropRef = useMemo(() => {
+ if (props.disabled) return false;
+ return mergedShowWithoutDisabledRef.value;
+ });
+ const getMergedDisabled = () => {
+ if (props.disabled) return true;
+ const {
+ getDisabled
+ } = props;
+ if (getDisabled === null || getDisabled === void 0 ? void 0 : getDisabled()) return true;
+ return false;
+ };
+ const getMergedShow = () => {
+ if (getMergedDisabled()) return false;
+ return mergedShowWithoutDisabledRef.value;
+ };
+ const compatibleShowArrowRef = useCompitable(props, ["arrow", "showArrow"]);
+ const mergedShowArrowRef = computed(() => {
+ if (props.overlap) return false;
+ return compatibleShowArrowRef.value;
+ });
+ let bodyInstance = null;
+ const showTimerIdRef = ref(null);
+ const hideTimerIdRef = ref(null);
+ const positionManuallyRef = useMemo(() => {
+ return props.x !== void 0 && props.y !== void 0;
+ });
+ function doUpdateShow(value) {
+ const {
+ "onUpdate:show": _onUpdateShow,
+ onUpdateShow,
+ onShow,
+ onHide
+ } = props;
+ uncontrolledShowRef.value = value;
+ if (_onUpdateShow) {
+ call(_onUpdateShow, value);
+ }
+ if (onUpdateShow) {
+ call(onUpdateShow, value);
+ }
+ if (value && onShow) {
+ call(onShow, true);
+ }
+ if (value && onHide) {
+ call(onHide, false);
+ }
+ }
+ function syncPosition() {
+ if (bodyInstance) {
+ bodyInstance.syncPosition();
+ }
+ }
+ function clearShowTimer() {
+ const {
+ value: showTimerId
+ } = showTimerIdRef;
+ if (showTimerId) {
+ window.clearTimeout(showTimerId);
+ showTimerIdRef.value = null;
+ }
+ }
+ function clearHideTimer() {
+ const {
+ value: hideTimerId
+ } = hideTimerIdRef;
+ if (hideTimerId) {
+ window.clearTimeout(hideTimerId);
+ hideTimerIdRef.value = null;
+ }
+ }
+ function handleFocus() {
+ const mergedDisabled = getMergedDisabled();
+ if (props.trigger === "focus" && !mergedDisabled) {
+ if (getMergedShow()) return;
+ doUpdateShow(true);
+ }
+ }
+ function handleBlur() {
+ const mergedDisabled = getMergedDisabled();
+ if (props.trigger === "focus" && !mergedDisabled) {
+ if (!getMergedShow()) return;
+ doUpdateShow(false);
+ }
+ }
+ function handleMouseEnter() {
+ const mergedDisabled = getMergedDisabled();
+ if (props.trigger === "hover" && !mergedDisabled) {
+ clearHideTimer();
+ if (showTimerIdRef.value !== null) return;
+ if (getMergedShow()) return;
+ const delayCallback = () => {
+ doUpdateShow(true);
+ showTimerIdRef.value = null;
+ };
+ const {
+ delay
+ } = props;
+ if (delay === 0) {
+ delayCallback();
+ } else {
+ showTimerIdRef.value = window.setTimeout(delayCallback, delay);
+ }
+ }
+ }
+ function handleMouseLeave() {
+ const mergedDisabled = getMergedDisabled();
+ if (props.trigger === "hover" && !mergedDisabled) {
+ clearShowTimer();
+ if (hideTimerIdRef.value !== null) return;
+ if (!getMergedShow()) return;
+ const delayedCallback = () => {
+ doUpdateShow(false);
+ hideTimerIdRef.value = null;
+ };
+ const {
+ duration
+ } = props;
+ if (duration === 0) {
+ delayedCallback();
+ } else {
+ hideTimerIdRef.value = window.setTimeout(delayedCallback, duration);
+ }
+ }
+ }
+ function handleMouseMoveOutside() {
+ handleMouseLeave();
+ }
+ function handleClickOutside(e) {
+ var _a;
+ if (!getMergedShow()) return;
+ if (props.trigger === "click") {
+ clearShowTimer();
+ clearHideTimer();
+ doUpdateShow(false);
+ }
+ (_a = props.onClickoutside) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ }
+ function handleClick() {
+ if (props.trigger === "click" && !getMergedDisabled()) {
+ clearShowTimer();
+ clearHideTimer();
+ const nextShow = !getMergedShow();
+ doUpdateShow(nextShow);
+ }
+ }
+ function handleKeydown(e) {
+ if (!props.internalTrapFocus) return;
+ if (e.key === "Escape") {
+ clearShowTimer();
+ clearHideTimer();
+ doUpdateShow(false);
+ }
+ }
+ function setShow(value) {
+ uncontrolledShowRef.value = value;
+ }
+ function getTriggerElement() {
+ var _a;
+ return (_a = binderInstRef.value) === null || _a === void 0 ? void 0 : _a.targetRef;
+ }
+ function setBodyInstance(value) {
+ bodyInstance = value;
+ }
+ provide("NPopover", {
+ getTriggerElement,
+ handleKeydown,
+ handleMouseEnter,
+ handleMouseLeave,
+ handleClickOutside,
+ handleMouseMoveOutside,
+ setBodyInstance,
+ positionManuallyRef,
+ isMountedRef,
+ zIndexRef: toRef(props, "zIndex"),
+ extraClassRef: toRef(props, "internalExtraClass"),
+ internalRenderBodyRef: toRef(props, "internalRenderBody")
+ });
+ watchEffect(() => {
+ if (mergedShowWithoutDisabledRef.value && getMergedDisabled()) {
+ doUpdateShow(false);
+ }
+ });
+ const returned = {
+ binderInstRef,
+ positionManually: positionManuallyRef,
+ mergedShowConsideringDisabledProp: mergedShowConsideringDisabledPropRef,
+ // if to show popover body
+ uncontrolledShow: uncontrolledShowRef,
+ mergedShowArrow: mergedShowArrowRef,
+ getMergedShow,
+ setShow,
+ handleClick,
+ handleMouseEnter,
+ handleMouseLeave,
+ handleFocus,
+ handleBlur,
+ syncPosition
+ };
+ return returned;
+ },
+ render() {
+ var _a;
+ const {
+ positionManually,
+ $slots: slots
+ } = this;
+ let triggerVNode;
+ let popoverInside = false;
+ if (!positionManually) {
+ if (slots.activator) {
+ triggerVNode = getFirstSlotVNode(slots, "activator");
+ } else {
+ triggerVNode = getFirstSlotVNode(slots, "trigger");
+ }
+ if (triggerVNode) {
+ triggerVNode = cloneVNode(triggerVNode);
+ triggerVNode = triggerVNode.type === Text ? h("span", [triggerVNode]) : triggerVNode;
+ const handlers = {
+ onClick: this.handleClick,
+ onMouseenter: this.handleMouseEnter,
+ onMouseleave: this.handleMouseLeave,
+ onFocus: this.handleFocus,
+ onBlur: this.handleBlur
+ };
+ if ((_a = triggerVNode.type) === null || _a === void 0 ? void 0 : _a.__popover__) {
+ popoverInside = true;
+ if (!triggerVNode.props) {
+ triggerVNode.props = {
+ internalSyncTargetWithParent: true,
+ internalInheritedEventHandlers: []
+ };
+ }
+ triggerVNode.props.internalSyncTargetWithParent = true;
+ if (!triggerVNode.props.internalInheritedEventHandlers) {
+ triggerVNode.props.internalInheritedEventHandlers = [handlers];
+ } else {
+ triggerVNode.props.internalInheritedEventHandlers = [handlers, ...triggerVNode.props.internalInheritedEventHandlers];
+ }
+ } else {
+ const {
+ internalInheritedEventHandlers
+ } = this;
+ const ascendantAndCurrentHandlers = [handlers, ...internalInheritedEventHandlers];
+ const mergedHandlers = {
+ onBlur: (e) => {
+ ascendantAndCurrentHandlers.forEach((_handlers) => {
+ _handlers.onBlur(e);
+ });
+ },
+ onFocus: (e) => {
+ ascendantAndCurrentHandlers.forEach((_handlers) => {
+ _handlers.onFocus(e);
+ });
+ },
+ onClick: (e) => {
+ ascendantAndCurrentHandlers.forEach((_handlers) => {
+ _handlers.onClick(e);
+ });
+ },
+ onMouseenter: (e) => {
+ ascendantAndCurrentHandlers.forEach((_handlers) => {
+ _handlers.onMouseenter(e);
+ });
+ },
+ onMouseleave: (e) => {
+ ascendantAndCurrentHandlers.forEach((_handlers) => {
+ _handlers.onMouseleave(e);
+ });
+ }
+ };
+ appendEvents(triggerVNode, internalInheritedEventHandlers ? "nested" : positionManually ? "manual" : this.trigger, mergedHandlers);
+ }
+ }
+ }
+ return h(Binder, {
+ ref: "binderInstRef",
+ syncTarget: !popoverInside,
+ syncTargetWithParent: this.internalSyncTargetWithParent
+ }, {
+ default: () => {
+ void this.mergedShowConsideringDisabledProp;
+ const mergedShow = this.getMergedShow();
+ return [this.internalTrapFocus && mergedShow ? withDirectives(h("div", {
+ style: {
+ position: "fixed",
+ top: 0,
+ right: 0,
+ bottom: 0,
+ left: 0
+ }
+ }), [[zindexable, {
+ enabled: mergedShow,
+ zIndex: this.zIndex
+ }]]) : null, positionManually ? null : h(VTarget, null, {
+ default: () => triggerVNode
+ }), h(NPopoverBody, keep(this.$props, bodyPropKeys, Object.assign(Object.assign({}, this.$attrs), {
+ showArrow: this.mergedShowArrow,
+ show: mergedShow
+ })), {
+ default: () => {
+ var _a2, _b;
+ return (_b = (_a2 = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a2);
+ },
+ header: () => {
+ var _a2, _b;
+ return (_b = (_a2 = this.$slots).header) === null || _b === void 0 ? void 0 : _b.call(_a2);
+ },
+ footer: () => {
+ var _a2, _b;
+ return (_b = (_a2 = this.$slots).footer) === null || _b === void 0 ? void 0 : _b.call(_a2);
+ }
+ })];
+ }
+ });
+ }
+});
+const isImageSupportNativeLazy = isBrowser && "loading" in document.createElement("img");
+function resolveOptionsAndHash(options = {}) {
+ var _a;
+ const {
+ root: root2 = null
+ } = options;
+ return {
+ hash: `${options.rootMargin || "0px 0px 0px 0px"}-${Array.isArray(options.threshold) ? options.threshold.join(",") : (_a = options.threshold) !== null && _a !== void 0 ? _a : "0"}`,
+ options: Object.assign(Object.assign({}, options), {
+ root: (typeof root2 === "string" ? document.querySelector(root2) : root2) || document.documentElement
+ })
+ };
+}
+const observers = /* @__PURE__ */ new WeakMap();
+const unobserveHandleMap = /* @__PURE__ */ new WeakMap();
+const shouldStartLoadingRefMap = /* @__PURE__ */ new WeakMap();
+const observeIntersection = (el, options, shouldStartLoadingRef) => {
+ if (!el) return () => {
+ };
+ const resolvedOptionsAndHash = resolveOptionsAndHash(options);
+ const {
+ root: root2
+ } = resolvedOptionsAndHash.options;
+ let rootObservers;
+ const _rootObservers = observers.get(root2);
+ if (_rootObservers) {
+ rootObservers = _rootObservers;
+ } else {
+ rootObservers = /* @__PURE__ */ new Map();
+ observers.set(root2, rootObservers);
+ }
+ let observer;
+ let observerAndObservedElements;
+ if (rootObservers.has(resolvedOptionsAndHash.hash)) {
+ observerAndObservedElements = rootObservers.get(resolvedOptionsAndHash.hash);
+ if (!observerAndObservedElements[1].has(el)) {
+ observer = observerAndObservedElements[0];
+ observerAndObservedElements[1].add(el);
+ observer.observe(el);
+ }
+ } else {
+ observer = new IntersectionObserver((entries) => {
+ entries.forEach((entry) => {
+ if (entry.isIntersecting) {
+ const _unobserve = unobserveHandleMap.get(entry.target);
+ const _shouldStartLoadingRef = shouldStartLoadingRefMap.get(entry.target);
+ if (_unobserve) _unobserve();
+ if (_shouldStartLoadingRef) {
+ _shouldStartLoadingRef.value = true;
+ }
+ }
+ });
+ }, resolvedOptionsAndHash.options);
+ observer.observe(el);
+ observerAndObservedElements = [observer, /* @__PURE__ */ new Set([el])];
+ rootObservers.set(resolvedOptionsAndHash.hash, observerAndObservedElements);
+ }
+ let unobservered = false;
+ const unobserve = () => {
+ if (unobservered) return;
+ unobserveHandleMap.delete(el);
+ shouldStartLoadingRefMap.delete(el);
+ unobservered = true;
+ if (observerAndObservedElements[1].has(el)) {
+ observerAndObservedElements[0].unobserve(el);
+ observerAndObservedElements[1].delete(el);
+ }
+ if (observerAndObservedElements[1].size <= 0) {
+ rootObservers.delete(resolvedOptionsAndHash.hash);
+ }
+ if (!rootObservers.size) {
+ observers.delete(root2);
+ }
+ };
+ unobserveHandleMap.set(el, unobserve);
+ shouldStartLoadingRefMap.set(el, shouldStartLoadingRef);
+ return unobserve;
+};
+const tooltipProps = Object.assign(Object.assign({}, popoverBaseProps), useTheme.props);
+const __unplugin_components_3 = defineComponent({
+ name: "Tooltip",
+ props: tooltipProps,
+ __popover__: true,
+ setup(props) {
+ const {
+ mergedClsPrefixRef
+ } = useConfig(props);
+ const themeRef = useTheme("Tooltip", "-tooltip", void 0, tooltipLight, props, mergedClsPrefixRef);
+ const popoverRef = ref(null);
+ const tooltipExposedMethod = {
+ syncPosition() {
+ popoverRef.value.syncPosition();
+ },
+ setShow(show) {
+ popoverRef.value.setShow(show);
+ }
+ };
+ return Object.assign(Object.assign({}, tooltipExposedMethod), {
+ popoverRef,
+ mergedTheme: themeRef,
+ popoverThemeOverrides: computed(() => {
+ return themeRef.value.self;
+ })
+ });
+ },
+ render() {
+ const {
+ mergedTheme,
+ internalExtraClass
+ } = this;
+ return h(__unplugin_components_5, Object.assign(Object.assign({}, this.$props), {
+ theme: mergedTheme.peers.Popover,
+ themeOverrides: mergedTheme.peerOverrides.Popover,
+ builtinThemeOverrides: this.popoverThemeOverrides,
+ internalExtraClass: internalExtraClass.concat("tooltip"),
+ ref: "popoverRef"
+ }), this.$slots);
+ }
+});
+function renderPrevIcon() {
+ return h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M6 5C5.75454 5 5.55039 5.17688 5.50806 5.41012L5.5 5.5V14.5C5.5 14.7761 5.72386 15 6 15C6.24546 15 6.44961 14.8231 6.49194 14.5899L6.5 14.5V5.5C6.5 5.22386 6.27614 5 6 5ZM13.8536 5.14645C13.68 4.97288 13.4106 4.9536 13.2157 5.08859L13.1464 5.14645L8.64645 9.64645C8.47288 9.82001 8.4536 10.0894 8.58859 10.2843L8.64645 10.3536L13.1464 14.8536C13.3417 15.0488 13.6583 15.0488 13.8536 14.8536C14.0271 14.68 14.0464 14.4106 13.9114 14.2157L13.8536 14.1464L9.70711 10L13.8536 5.85355C14.0488 5.65829 14.0488 5.34171 13.8536 5.14645Z",
+ fill: "currentColor"
+ }));
+}
+function renderNextIcon() {
+ return h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M13.5 5C13.7455 5 13.9496 5.17688 13.9919 5.41012L14 5.5V14.5C14 14.7761 13.7761 15 13.5 15C13.2545 15 13.0504 14.8231 13.0081 14.5899L13 14.5V5.5C13 5.22386 13.2239 5 13.5 5ZM5.64645 5.14645C5.82001 4.97288 6.08944 4.9536 6.28431 5.08859L6.35355 5.14645L10.8536 9.64645C11.0271 9.82001 11.0464 10.0894 10.9114 10.2843L10.8536 10.3536L6.35355 14.8536C6.15829 15.0488 5.84171 15.0488 5.64645 14.8536C5.47288 14.68 5.4536 14.4106 5.58859 14.2157L5.64645 14.1464L9.79289 10L5.64645 5.85355C5.45118 5.65829 5.45118 5.34171 5.64645 5.14645Z",
+ fill: "currentColor"
+ }));
+}
+function renderCloseIcon() {
+ return h("svg", {
+ viewBox: "0 0 20 20",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M4.089 4.216l.057-.07a.5.5 0 0 1 .638-.057l.07.057L10 9.293l5.146-5.147a.5.5 0 0 1 .638-.057l.07.057a.5.5 0 0 1 .057.638l-.057.07L10.707 10l5.147 5.146a.5.5 0 0 1 .057.638l-.057.07a.5.5 0 0 1-.638.057l-.07-.057L10 10.707l-5.146 5.147a.5.5 0 0 1-.638.057l-.07-.057a.5.5 0 0 1-.057-.638l.057-.07L9.293 10L4.146 4.854a.5.5 0 0 1-.057-.638l.057-.07l-.057.07z",
+ fill: "currentColor"
+ }));
+}
+const imagePreviewSharedProps = Object.assign(Object.assign({}, useTheme.props), {
+ onPreviewPrev: Function,
+ onPreviewNext: Function,
+ showToolbar: {
+ type: Boolean,
+ default: true
+ },
+ showToolbarTooltip: Boolean,
+ renderToolbar: Function
+});
+const imageContextKey = createInjectionKey("n-image");
+const style = c([c("body >", [cB("image-container", "position: fixed;")]), cB("image-preview-container", `
+ position: fixed;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ display: flex;
+ `), cB("image-preview-overlay", `
+ z-index: -1;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ background: rgba(0, 0, 0, .3);
+ `, [fadeInTransition()]), cB("image-preview-toolbar", `
+ z-index: 1;
+ position: absolute;
+ left: 50%;
+ transform: translateX(-50%);
+ border-radius: var(--n-toolbar-border-radius);
+ height: 48px;
+ bottom: 40px;
+ padding: 0 12px;
+ background: var(--n-toolbar-color);
+ box-shadow: var(--n-toolbar-box-shadow);
+ color: var(--n-toolbar-icon-color);
+ transition: color .3s var(--n-bezier);
+ display: flex;
+ align-items: center;
+ `, [cB("base-icon", `
+ padding: 0 8px;
+ font-size: 28px;
+ cursor: pointer;
+ `), fadeInTransition()]), cB("image-preview-wrapper", `
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ display: flex;
+ pointer-events: none;
+ `, [fadeInScaleUpTransition()]), cB("image-preview", `
+ user-select: none;
+ -webkit-user-select: none;
+ pointer-events: all;
+ margin: auto;
+ max-height: calc(100vh - 32px);
+ max-width: calc(100vw - 32px);
+ transition: transform .3s var(--n-bezier);
+ `), cB("image", `
+ display: inline-flex;
+ max-height: 100%;
+ max-width: 100%;
+ `, [cNotM("preview-disabled", `
+ cursor: pointer;
+ `), c("img", `
+ border-radius: inherit;
+ `)])]);
+const BLEEDING = 32;
+const NImagePreview = defineComponent({
+ name: "ImagePreview",
+ props: Object.assign(Object.assign({}, imagePreviewSharedProps), {
+ onNext: Function,
+ onPrev: Function,
+ clsPrefix: {
+ type: String,
+ required: true
+ }
+ }),
+ setup(props) {
+ const themeRef = useTheme("Image", "-image", style, imageLight, props, toRef(props, "clsPrefix"));
+ let thumbnailEl = null;
+ const previewRef = ref(null);
+ const previewWrapperRef = ref(null);
+ const previewSrcRef = ref(void 0);
+ const showRef = ref(false);
+ const displayedRef = ref(false);
+ const {
+ localeRef
+ } = useLocale("Image");
+ function syncTransformOrigin() {
+ const {
+ value: previewWrapper
+ } = previewWrapperRef;
+ if (!thumbnailEl || !previewWrapper) return;
+ const {
+ style: style2
+ } = previewWrapper;
+ const tbox = thumbnailEl.getBoundingClientRect();
+ const tx = tbox.left + tbox.width / 2;
+ const ty = tbox.top + tbox.height / 2;
+ style2.transformOrigin = `${tx}px ${ty}px`;
+ }
+ function handleKeydown(e) {
+ var _a, _b;
+ switch (e.key) {
+ case " ":
+ e.preventDefault();
+ break;
+ case "ArrowLeft":
+ (_a = props.onPrev) === null || _a === void 0 ? void 0 : _a.call(props);
+ break;
+ case "ArrowRight":
+ (_b = props.onNext) === null || _b === void 0 ? void 0 : _b.call(props);
+ break;
+ case "Escape":
+ toggleShow();
+ break;
+ }
+ }
+ watch(showRef, (value) => {
+ if (value) {
+ on("keydown", document, handleKeydown);
+ } else {
+ off("keydown", document, handleKeydown);
+ }
+ });
+ onBeforeUnmount(() => {
+ off("keydown", document, handleKeydown);
+ });
+ let startX = 0;
+ let startY = 0;
+ let offsetX = 0;
+ let offsetY = 0;
+ let startOffsetX = 0;
+ let startOffsetY = 0;
+ let mouseDownClientX = 0;
+ let mouseDownClientY = 0;
+ let dragging = false;
+ function handleMouseMove(e) {
+ const {
+ clientX,
+ clientY
+ } = e;
+ offsetX = clientX - startX;
+ offsetY = clientY - startY;
+ beforeNextFrameOnce(derivePreviewStyle);
+ }
+ function getMoveStrategy(opts) {
+ const {
+ mouseUpClientX,
+ mouseUpClientY,
+ mouseDownClientX: mouseDownClientX2,
+ mouseDownClientY: mouseDownClientY2
+ } = opts;
+ const deltaHorizontal = mouseDownClientX2 - mouseUpClientX;
+ const deltaVertical = mouseDownClientY2 - mouseUpClientY;
+ const moveVerticalDirection = `vertical${deltaVertical > 0 ? "Top" : "Bottom"}`;
+ const moveHorizontalDirection = `horizontal${deltaHorizontal > 0 ? "Left" : "Right"}`;
+ return {
+ moveVerticalDirection,
+ moveHorizontalDirection,
+ deltaHorizontal,
+ deltaVertical
+ };
+ }
+ function getDerivedOffset(moveStrategy) {
+ const {
+ value: preview
+ } = previewRef;
+ if (!preview) return {
+ offsetX: 0,
+ offsetY: 0
+ };
+ const pbox = preview.getBoundingClientRect();
+ const {
+ moveVerticalDirection,
+ moveHorizontalDirection,
+ deltaHorizontal,
+ deltaVertical
+ } = moveStrategy || {};
+ let nextOffsetX = 0;
+ let nextOffsetY = 0;
+ if (pbox.width <= window.innerWidth) {
+ nextOffsetX = 0;
+ } else if (pbox.left > 0) {
+ nextOffsetX = (pbox.width - window.innerWidth) / 2;
+ } else if (pbox.right < window.innerWidth) {
+ nextOffsetX = -(pbox.width - window.innerWidth) / 2;
+ } else if (moveHorizontalDirection === "horizontalRight") {
+ nextOffsetX = Math.min((pbox.width - window.innerWidth) / 2, startOffsetX - (deltaHorizontal !== null && deltaHorizontal !== void 0 ? deltaHorizontal : 0));
+ } else {
+ nextOffsetX = Math.max(-((pbox.width - window.innerWidth) / 2), startOffsetX - (deltaHorizontal !== null && deltaHorizontal !== void 0 ? deltaHorizontal : 0));
+ }
+ if (pbox.height <= window.innerHeight) {
+ nextOffsetY = 0;
+ } else if (pbox.top > 0) {
+ nextOffsetY = (pbox.height - window.innerHeight) / 2;
+ } else if (pbox.bottom < window.innerHeight) {
+ nextOffsetY = -(pbox.height - window.innerHeight) / 2;
+ } else if (moveVerticalDirection === "verticalBottom") {
+ nextOffsetY = Math.min((pbox.height - window.innerHeight) / 2, startOffsetY - (deltaVertical !== null && deltaVertical !== void 0 ? deltaVertical : 0));
+ } else {
+ nextOffsetY = Math.max(-((pbox.height - window.innerHeight) / 2), startOffsetY - (deltaVertical !== null && deltaVertical !== void 0 ? deltaVertical : 0));
+ }
+ return {
+ offsetX: nextOffsetX,
+ offsetY: nextOffsetY
+ };
+ }
+ function handleMouseUp(e) {
+ off("mousemove", document, handleMouseMove);
+ off("mouseup", document, handleMouseUp);
+ const {
+ clientX: mouseUpClientX,
+ clientY: mouseUpClientY
+ } = e;
+ dragging = false;
+ const moveStrategy = getMoveStrategy({
+ mouseUpClientX,
+ mouseUpClientY,
+ mouseDownClientX,
+ mouseDownClientY
+ });
+ const offset = getDerivedOffset(moveStrategy);
+ offsetX = offset.offsetX;
+ offsetY = offset.offsetY;
+ derivePreviewStyle();
+ }
+ const imageContext = inject(imageContextKey, null);
+ function handlePreviewMousedown(e) {
+ var _a, _b;
+ (_b = (_a = imageContext === null || imageContext === void 0 ? void 0 : imageContext.previewedImgPropsRef.value) === null || _a === void 0 ? void 0 : _a.onMousedown) === null || _b === void 0 ? void 0 : _b.call(_a, e);
+ if (e.button !== 0) return;
+ const {
+ clientX,
+ clientY
+ } = e;
+ dragging = true;
+ startX = clientX - offsetX;
+ startY = clientY - offsetY;
+ startOffsetX = offsetX;
+ startOffsetY = offsetY;
+ mouseDownClientX = clientX;
+ mouseDownClientY = clientY;
+ derivePreviewStyle();
+ on("mousemove", document, handleMouseMove);
+ on("mouseup", document, handleMouseUp);
+ }
+ const scaleRadix = 1.5;
+ let scaleExp = 0;
+ let scale = 1;
+ let rotate = 0;
+ function handlePreviewDblclick(e) {
+ var _a, _b;
+ (_b = (_a = imageContext === null || imageContext === void 0 ? void 0 : imageContext.previewedImgPropsRef.value) === null || _a === void 0 ? void 0 : _a.onDblclick) === null || _b === void 0 ? void 0 : _b.call(_a, e);
+ const originalImageSizeScale = getOrignalImageSizeScale();
+ scale = scale === originalImageSizeScale ? 1 : originalImageSizeScale;
+ derivePreviewStyle();
+ }
+ function resetScale() {
+ scale = 1;
+ scaleExp = 0;
+ }
+ function handleSwitchPrev() {
+ var _a;
+ resetScale();
+ rotate = 0;
+ (_a = props.onPrev) === null || _a === void 0 ? void 0 : _a.call(props);
+ }
+ function handleSwitchNext() {
+ var _a;
+ resetScale();
+ rotate = 0;
+ (_a = props.onNext) === null || _a === void 0 ? void 0 : _a.call(props);
+ }
+ function rotateCounterclockwise() {
+ rotate -= 90;
+ derivePreviewStyle();
+ }
+ function rotateClockwise() {
+ rotate += 90;
+ derivePreviewStyle();
+ }
+ function getMaxScale() {
+ const {
+ value: preview
+ } = previewRef;
+ if (!preview) return 1;
+ const {
+ innerWidth,
+ innerHeight
+ } = window;
+ const heightMaxScale = Math.max(1, preview.naturalHeight / (innerHeight - BLEEDING));
+ const widthMaxScale = Math.max(1, preview.naturalWidth / (innerWidth - BLEEDING));
+ return Math.max(3, heightMaxScale * 2, widthMaxScale * 2);
+ }
+ function getOrignalImageSizeScale() {
+ const {
+ value: preview
+ } = previewRef;
+ if (!preview) return 1;
+ const {
+ innerWidth,
+ innerHeight
+ } = window;
+ const heightScale = preview.naturalHeight / (innerHeight - BLEEDING);
+ const widthScale = preview.naturalWidth / (innerWidth - BLEEDING);
+ if (heightScale < 1 && widthScale < 1) {
+ return 1;
+ }
+ return Math.max(heightScale, widthScale);
+ }
+ function zoomIn() {
+ const maxScale = getMaxScale();
+ if (scale < maxScale) {
+ scaleExp += 1;
+ scale = Math.min(maxScale, Math.pow(scaleRadix, scaleExp));
+ derivePreviewStyle();
+ }
+ }
+ function zoomOut() {
+ if (scale > 0.5) {
+ const originalScale = scale;
+ scaleExp -= 1;
+ scale = Math.max(0.5, Math.pow(scaleRadix, scaleExp));
+ const diff = originalScale - scale;
+ derivePreviewStyle(false);
+ const offset = getDerivedOffset();
+ scale += diff;
+ derivePreviewStyle(false);
+ scale -= diff;
+ offsetX = offset.offsetX;
+ offsetY = offset.offsetY;
+ derivePreviewStyle();
+ }
+ }
+ function handleDownloadClick() {
+ const src = previewSrcRef.value;
+ if (src) {
+ download(src);
+ }
+ }
+ function derivePreviewStyle(transition = true) {
+ var _a;
+ const {
+ value: preview
+ } = previewRef;
+ if (!preview) return;
+ const {
+ style: style2
+ } = preview;
+ const controlledStyle = normalizeStyle((_a = imageContext === null || imageContext === void 0 ? void 0 : imageContext.previewedImgPropsRef.value) === null || _a === void 0 ? void 0 : _a.style);
+ let controlledStyleString = "";
+ if (typeof controlledStyle === "string") {
+ controlledStyleString = `${controlledStyle};`;
+ } else {
+ for (const key in controlledStyle) {
+ controlledStyleString += `${kebabCase(key)}: ${controlledStyle[key]};`;
+ }
+ }
+ const transformStyle = `transform-origin: center; transform: translateX(${offsetX}px) translateY(${offsetY}px) rotate(${rotate}deg) scale(${scale});`;
+ if (dragging) {
+ style2.cssText = `${controlledStyleString}cursor: grabbing; transition: none;${transformStyle}`;
+ } else {
+ style2.cssText = `${controlledStyleString}cursor: grab;${transformStyle}${transition ? "" : "transition: none;"}`;
+ }
+ if (!transition) {
+ void preview.offsetHeight;
+ }
+ }
+ function toggleShow() {
+ showRef.value = !showRef.value;
+ displayedRef.value = true;
+ }
+ function resizeToOrignalImageSize() {
+ scale = getOrignalImageSizeScale();
+ scaleExp = Math.ceil(Math.log(scale) / Math.log(scaleRadix));
+ offsetX = 0;
+ offsetY = 0;
+ derivePreviewStyle();
+ }
+ const exposedMethods = {
+ setPreviewSrc: (src) => {
+ previewSrcRef.value = src;
+ },
+ setThumbnailEl: (el) => {
+ thumbnailEl = el;
+ },
+ toggleShow
+ };
+ function withTooltip(node, tooltipKey) {
+ if (props.showToolbarTooltip) {
+ const {
+ value: theme
+ } = themeRef;
+ return h(__unplugin_components_3, {
+ to: false,
+ theme: theme.peers.Tooltip,
+ themeOverrides: theme.peerOverrides.Tooltip,
+ keepAliveOnHover: false
+ }, {
+ default: () => {
+ return localeRef.value[tooltipKey];
+ },
+ trigger: () => node
+ });
+ } else {
+ return node;
+ }
+ }
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self: {
+ toolbarIconColor,
+ toolbarBorderRadius,
+ toolbarBoxShadow,
+ toolbarColor
+ }
+ } = themeRef.value;
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-toolbar-icon-color": toolbarIconColor,
+ "--n-toolbar-color": toolbarColor,
+ "--n-toolbar-border-radius": toolbarBorderRadius,
+ "--n-toolbar-box-shadow": toolbarBoxShadow
+ };
+ });
+ const {
+ inlineThemeDisabled
+ } = useConfig();
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("image-preview", void 0, cssVarsRef, props) : void 0;
+ return Object.assign({
+ previewRef,
+ previewWrapperRef,
+ previewSrc: previewSrcRef,
+ show: showRef,
+ appear: isMounted(),
+ displayed: displayedRef,
+ previewedImgProps: imageContext === null || imageContext === void 0 ? void 0 : imageContext.previewedImgPropsRef,
+ handleWheel(e) {
+ e.preventDefault();
+ },
+ handlePreviewMousedown,
+ handlePreviewDblclick,
+ syncTransformOrigin,
+ handleAfterLeave: () => {
+ resetScale();
+ rotate = 0;
+ displayedRef.value = false;
+ },
+ handleDragStart: (e) => {
+ var _a, _b;
+ (_b = (_a = imageContext === null || imageContext === void 0 ? void 0 : imageContext.previewedImgPropsRef.value) === null || _a === void 0 ? void 0 : _a.onDragstart) === null || _b === void 0 ? void 0 : _b.call(_a, e);
+ e.preventDefault();
+ },
+ zoomIn,
+ zoomOut,
+ handleDownloadClick,
+ rotateCounterclockwise,
+ rotateClockwise,
+ handleSwitchPrev,
+ handleSwitchNext,
+ withTooltip,
+ resizeToOrignalImageSize,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ }, exposedMethods);
+ },
+ render() {
+ var _a, _b;
+ const {
+ clsPrefix,
+ renderToolbar,
+ withTooltip
+ } = this;
+ const prevNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.handleSwitchPrev
+ }, {
+ default: renderPrevIcon
+ }), "tipPrevious");
+ const nextNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.handleSwitchNext
+ }, {
+ default: renderNextIcon
+ }), "tipNext");
+ const rotateCounterclockwiseNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.rotateCounterclockwise
+ }, {
+ default: () => h(RotateCounterclockwiseIcon, null)
+ }), "tipCounterclockwise");
+ const rotateClockwiseNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.rotateClockwise
+ }, {
+ default: () => h(RotateClockwiseIcon, null)
+ }), "tipClockwise");
+ const originalSizeNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.resizeToOrignalImageSize
+ }, {
+ default: () => {
+ return h(ResizeSmallIcon, null);
+ }
+ }), "tipOriginalSize");
+ const zoomOutNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.zoomOut
+ }, {
+ default: () => h(ZoomOutIcon, null)
+ }), "tipZoomOut");
+ const downloadNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.handleDownloadClick
+ }, {
+ default: () => h(DownloadIcon, null)
+ }), "tipDownload");
+ const closeNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.toggleShow
+ }, {
+ default: renderCloseIcon
+ }), "tipClose");
+ const zoomInNode = withTooltip(h(NBaseIcon, {
+ clsPrefix,
+ onClick: this.zoomIn
+ }, {
+ default: () => h(ZoomInIcon, null)
+ }), "tipZoomIn");
+ return h(Fragment, null, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a), h(LazyTeleport, {
+ show: this.show
+ }, {
+ default: () => {
+ var _a2;
+ if (!(this.show || this.displayed)) {
+ return null;
+ }
+ (_a2 = this.onRender) === null || _a2 === void 0 ? void 0 : _a2.call(this);
+ return withDirectives(h("div", {
+ class: [`${clsPrefix}-image-preview-container`, this.themeClass],
+ style: this.cssVars,
+ onWheel: this.handleWheel
+ }, h(Transition, {
+ name: "fade-in-transition",
+ appear: this.appear
+ }, {
+ default: () => this.show ? h("div", {
+ class: `${clsPrefix}-image-preview-overlay`,
+ onClick: this.toggleShow
+ }) : null
+ }), this.showToolbar ? h(Transition, {
+ name: "fade-in-transition",
+ appear: this.appear
+ }, {
+ default: () => {
+ if (!this.show) return null;
+ return h("div", {
+ class: `${clsPrefix}-image-preview-toolbar`
+ }, renderToolbar ? renderToolbar({
+ nodes: {
+ prev: prevNode,
+ next: nextNode,
+ rotateCounterclockwise: rotateCounterclockwiseNode,
+ rotateClockwise: rotateClockwiseNode,
+ resizeToOriginalSize: originalSizeNode,
+ zoomOut: zoomOutNode,
+ zoomIn: zoomInNode,
+ download: downloadNode,
+ close: closeNode
+ }
+ }) : h(Fragment, null, this.onPrev ? h(Fragment, null, prevNode, nextNode) : null, rotateCounterclockwiseNode, rotateClockwiseNode, originalSizeNode, zoomOutNode, zoomInNode, downloadNode, closeNode));
+ }
+ }) : null, h(Transition, {
+ name: "fade-in-scale-up-transition",
+ onAfterLeave: this.handleAfterLeave,
+ appear: this.appear,
+ // BUG:
+ // onEnter will be called twice, I don't know why
+ // Maybe it is a bug of vue
+ onEnter: this.syncTransformOrigin,
+ onBeforeLeave: this.syncTransformOrigin
+ }, {
+ default: () => {
+ const {
+ previewedImgProps = {}
+ } = this;
+ return withDirectives(h("div", {
+ class: `${clsPrefix}-image-preview-wrapper`,
+ ref: "previewWrapperRef"
+ }, h("img", Object.assign({}, previewedImgProps, {
+ draggable: false,
+ onMousedown: this.handlePreviewMousedown,
+ onDblclick: this.handlePreviewDblclick,
+ class: [`${clsPrefix}-image-preview`, previewedImgProps.class],
+ key: this.previewSrc,
+ src: this.previewSrc,
+ ref: "previewRef",
+ onDragstart: this.handleDragStart
+ }))), [[vShow, this.show]]);
+ }
+ })), [[zindexable, {
+ enabled: this.show
+ }]]);
+ }
+ }));
+ }
+});
+const imageGroupInjectionKey = createInjectionKey("n-image-group");
+const imageProps = Object.assign({
+ alt: String,
+ height: [String, Number],
+ imgProps: Object,
+ previewedImgProps: Object,
+ lazy: Boolean,
+ intersectionObserverOptions: Object,
+ objectFit: {
+ type: String,
+ default: "fill"
+ },
+ previewSrc: String,
+ fallbackSrc: String,
+ width: [String, Number],
+ src: String,
+ previewDisabled: Boolean,
+ loadDescription: String,
+ onError: Function,
+ onLoad: Function
+}, imagePreviewSharedProps);
+const NImage = defineComponent({
+ name: "Image",
+ props: imageProps,
+ inheritAttrs: false,
+ setup(props) {
+ const imageRef = ref(null);
+ const showErrorRef = ref(false);
+ const previewInstRef = ref(null);
+ const imageGroupHandle = inject(imageGroupInjectionKey, null);
+ const {
+ mergedClsPrefixRef
+ } = imageGroupHandle || useConfig(props);
+ const exposedMethods = {
+ click: () => {
+ if (props.previewDisabled || showErrorRef.value) return;
+ const mergedPreviewSrc = props.previewSrc || props.src;
+ if (imageGroupHandle) {
+ imageGroupHandle.setPreviewSrc(mergedPreviewSrc);
+ imageGroupHandle.setThumbnailEl(imageRef.value);
+ imageGroupHandle.toggleShow();
+ return;
+ }
+ const {
+ value: previewInst
+ } = previewInstRef;
+ if (!previewInst) return;
+ previewInst.setPreviewSrc(mergedPreviewSrc);
+ previewInst.setThumbnailEl(imageRef.value);
+ previewInst.toggleShow();
+ }
+ };
+ const shouldStartLoadingRef = ref(!props.lazy);
+ onMounted(() => {
+ var _a;
+ (_a = imageRef.value) === null || _a === void 0 ? void 0 : _a.setAttribute("data-group-id", (imageGroupHandle === null || imageGroupHandle === void 0 ? void 0 : imageGroupHandle.groupId) || "");
+ });
+ onMounted(() => {
+ if (props.lazy && props.intersectionObserverOptions) {
+ let unobserve;
+ const stopWatchHandle = watchEffect(() => {
+ unobserve === null || unobserve === void 0 ? void 0 : unobserve();
+ unobserve = void 0;
+ unobserve = observeIntersection(imageRef.value, props.intersectionObserverOptions, shouldStartLoadingRef);
+ });
+ onBeforeUnmount(() => {
+ stopWatchHandle();
+ unobserve === null || unobserve === void 0 ? void 0 : unobserve();
+ });
+ }
+ });
+ watchEffect(() => {
+ var _a;
+ void (props.src || ((_a = props.imgProps) === null || _a === void 0 ? void 0 : _a.src));
+ showErrorRef.value = false;
+ });
+ const loadedRef = ref(false);
+ provide(imageContextKey, {
+ previewedImgPropsRef: toRef(props, "previewedImgProps")
+ });
+ return Object.assign({
+ mergedClsPrefix: mergedClsPrefixRef,
+ groupId: imageGroupHandle === null || imageGroupHandle === void 0 ? void 0 : imageGroupHandle.groupId,
+ previewInstRef,
+ imageRef,
+ showError: showErrorRef,
+ shouldStartLoading: shouldStartLoadingRef,
+ loaded: loadedRef,
+ mergedOnClick: (e) => {
+ var _a, _b;
+ exposedMethods.click();
+ (_b = (_a = props.imgProps) === null || _a === void 0 ? void 0 : _a.onClick) === null || _b === void 0 ? void 0 : _b.call(_a, e);
+ },
+ mergedOnError: (e) => {
+ if (!shouldStartLoadingRef.value) return;
+ showErrorRef.value = true;
+ const {
+ onError,
+ imgProps: {
+ onError: imgPropsOnError
+ } = {}
+ } = props;
+ onError === null || onError === void 0 ? void 0 : onError(e);
+ imgPropsOnError === null || imgPropsOnError === void 0 ? void 0 : imgPropsOnError(e);
+ },
+ mergedOnLoad: (e) => {
+ const {
+ onLoad,
+ imgProps: {
+ onLoad: imgPropsOnLoad
+ } = {}
+ } = props;
+ onLoad === null || onLoad === void 0 ? void 0 : onLoad(e);
+ imgPropsOnLoad === null || imgPropsOnLoad === void 0 ? void 0 : imgPropsOnLoad(e);
+ loadedRef.value = true;
+ }
+ }, exposedMethods);
+ },
+ render() {
+ var _a, _b;
+ const {
+ mergedClsPrefix,
+ imgProps = {},
+ loaded,
+ $attrs,
+ lazy
+ } = this;
+ const errorNode = resolveSlot(this.$slots.error, () => []);
+ const placeholderNode = (_b = (_a = this.$slots).placeholder) === null || _b === void 0 ? void 0 : _b.call(_a);
+ const loadSrc = this.src || imgProps.src;
+ const imgNode = this.showError && errorNode.length ? errorNode : h("img", Object.assign(Object.assign({}, imgProps), {
+ ref: "imageRef",
+ width: this.width || imgProps.width,
+ height: this.height || imgProps.height,
+ src: this.showError ? this.fallbackSrc : lazy && this.intersectionObserverOptions ? this.shouldStartLoading ? loadSrc : void 0 : loadSrc,
+ alt: this.alt || imgProps.alt,
+ "aria-label": this.alt || imgProps.alt,
+ onClick: this.mergedOnClick,
+ onError: this.mergedOnError,
+ onLoad: this.mergedOnLoad,
+ // If interseciton observer options is set, do not use native lazy
+ loading: isImageSupportNativeLazy && lazy && !this.intersectionObserverOptions ? "lazy" : "eager",
+ style: [imgProps.style || "", placeholderNode && !loaded ? {
+ height: "0",
+ width: "0",
+ visibility: "hidden"
+ } : "", {
+ objectFit: this.objectFit
+ }],
+ "data-error": this.showError,
+ "data-preview-src": this.previewSrc || this.src
+ }));
+ return h("div", Object.assign({}, $attrs, {
+ role: "none",
+ class: [$attrs.class, `${mergedClsPrefix}-image`, (this.previewDisabled || this.showError) && `${mergedClsPrefix}-image--preview-disabled`]
+ }), this.groupId ? imgNode : h(NImagePreview, {
+ theme: this.theme,
+ themeOverrides: this.themeOverrides,
+ clsPrefix: mergedClsPrefix,
+ ref: "previewInstRef",
+ showToolbar: this.showToolbar,
+ showToolbarTooltip: this.showToolbarTooltip,
+ renderToolbar: this.renderToolbar
+ }, {
+ default: () => imgNode,
+ toolbar: () => {
+ var _a2, _b2;
+ return (_b2 = (_a2 = this.$slots).toolbar) === null || _b2 === void 0 ? void 0 : _b2.call(_a2);
+ }
+ }), !loaded && placeholderNode);
+ }
+});
+export {
+ NImage as N,
+ __unplugin_components_3 as _,
+ __unplugin_components_5 as a,
+ formatLength as f,
+ isImageSupportNativeLazy as i,
+ observeIntersection as o,
+ popoverBaseProps as p,
+ renderArrow as r
+};
diff --git a/out/renderer/assets/Image-DXClIklC.js.gz b/out/renderer/assets/Image-DXClIklC.js.gz
new file mode 100644
index 0000000..8358a20
Binary files /dev/null and b/out/renderer/assets/Image-DXClIklC.js.gz differ
diff --git a/out/renderer/assets/LatoLatin-Regular-Dmlz1U0B.woff2 b/out/renderer/assets/LatoLatin-Regular-Dmlz1U0B.woff2
new file mode 100644
index 0000000..a4d084b
Binary files /dev/null and b/out/renderer/assets/LatoLatin-Regular-Dmlz1U0B.woff2 differ
diff --git a/out/renderer/assets/LatoLatin-Semibold-Dbk81p2D.woff2 b/out/renderer/assets/LatoLatin-Semibold-Dbk81p2D.woff2
new file mode 100644
index 0000000..1861c24
Binary files /dev/null and b/out/renderer/assets/LatoLatin-Semibold-Dbk81p2D.woff2 differ
diff --git a/out/renderer/assets/Layout-CvYBg1vI.js b/out/renderer/assets/Layout-CvYBg1vI.js
new file mode 100644
index 0000000..346b0e7
--- /dev/null
+++ b/out/renderer/assets/Layout-CvYBg1vI.js
@@ -0,0 +1,170 @@
+import { p as cB, W as cM, d as defineComponent, q as useTheme, r as ref, x as useConfig, aI as layoutLight, $ as provide, aJ as useReactivated, G as computed, ap as useThemeClass, l as h, aK as Scrollbar, aL as createInjectionKey } from "./index-DKaFsuse.js";
+const positionProp = {
+ type: String,
+ default: "static"
+};
+const style = cB("layout", `
+ color: var(--n-text-color);
+ background-color: var(--n-color);
+ box-sizing: border-box;
+ position: relative;
+ z-index: auto;
+ flex: auto;
+ overflow: hidden;
+ transition:
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+`, [cB("layout-scroll-container", `
+ overflow-x: hidden;
+ box-sizing: border-box;
+ height: 100%;
+ `), cM("absolute-positioned", `
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ `)]);
+const layoutProps = {
+ embedded: Boolean,
+ position: positionProp,
+ nativeScrollbar: {
+ type: Boolean,
+ default: true
+ },
+ scrollbarProps: Object,
+ onScroll: Function,
+ contentClass: String,
+ contentStyle: {
+ type: [String, Object],
+ default: ""
+ },
+ hasSider: Boolean,
+ siderPlacement: {
+ type: String,
+ default: "left"
+ }
+};
+const layoutInjectionKey = createInjectionKey("n-layout");
+function createLayoutComponent(isContent) {
+ return defineComponent({
+ name: "Layout",
+ props: Object.assign(Object.assign({}, useTheme.props), layoutProps),
+ setup(props) {
+ const scrollableElRef = ref(null);
+ const scrollbarInstRef = ref(null);
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Layout", "-layout", style, layoutLight, props, mergedClsPrefixRef);
+ function scrollTo(options, y) {
+ if (props.nativeScrollbar) {
+ const {
+ value: scrollableEl
+ } = scrollableElRef;
+ if (scrollableEl) {
+ if (y === void 0) {
+ scrollableEl.scrollTo(options);
+ } else {
+ scrollableEl.scrollTo(options, y);
+ }
+ }
+ } else {
+ const {
+ value: scrollbarInst
+ } = scrollbarInstRef;
+ if (scrollbarInst) {
+ scrollbarInst.scrollTo(options, y);
+ }
+ }
+ }
+ provide(layoutInjectionKey, props);
+ let scrollX = 0;
+ let scrollY = 0;
+ const handleNativeElScroll = (e) => {
+ var _a;
+ const target = e.target;
+ scrollX = target.scrollLeft;
+ scrollY = target.scrollTop;
+ (_a = props.onScroll) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ };
+ useReactivated(() => {
+ if (props.nativeScrollbar) {
+ const el = scrollableElRef.value;
+ if (el) {
+ el.scrollTop = scrollY;
+ el.scrollLeft = scrollX;
+ }
+ }
+ });
+ const hasSiderStyle = {
+ display: "flex",
+ flexWrap: "nowrap",
+ width: "100%",
+ flexDirection: "row"
+ };
+ const exposedMethods = {
+ scrollTo
+ };
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self
+ } = themeRef.value;
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-color": props.embedded ? self.colorEmbedded : self.color,
+ "--n-text-color": self.textColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("layout", computed(() => {
+ return props.embedded ? "e" : "";
+ }), cssVarsRef, props) : void 0;
+ return Object.assign({
+ mergedClsPrefix: mergedClsPrefixRef,
+ scrollableElRef,
+ scrollbarInstRef,
+ hasSiderStyle,
+ mergedTheme: themeRef,
+ handleNativeElScroll,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ }, exposedMethods);
+ },
+ render() {
+ var _a;
+ const {
+ mergedClsPrefix,
+ hasSider
+ } = this;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ const hasSiderStyle = hasSider ? this.hasSiderStyle : void 0;
+ const layoutClass = [this.themeClass, isContent, `${mergedClsPrefix}-layout`, `${mergedClsPrefix}-layout--${this.position}-positioned`];
+ return h("div", {
+ class: layoutClass,
+ style: this.cssVars
+ }, this.nativeScrollbar ? h("div", {
+ ref: "scrollableElRef",
+ class: [`${mergedClsPrefix}-layout-scroll-container`, this.contentClass],
+ style: [this.contentStyle, hasSiderStyle],
+ onScroll: this.handleNativeElScroll
+ }, this.$slots) : h(Scrollbar, Object.assign({}, this.scrollbarProps, {
+ onScroll: this.onScroll,
+ ref: "scrollbarInstRef",
+ theme: this.mergedTheme.peers.Scrollbar,
+ themeOverrides: this.mergedTheme.peerOverrides.Scrollbar,
+ contentClass: this.contentClass,
+ contentStyle: [this.contentStyle, hasSiderStyle]
+ }), this.$slots));
+ }
+ });
+}
+const __unplugin_components_1 = createLayoutComponent(false);
+export {
+ __unplugin_components_1 as _
+};
diff --git a/out/renderer/assets/Layout-CvYBg1vI.js.gz b/out/renderer/assets/Layout-CvYBg1vI.js.gz
new file mode 100644
index 0000000..aa82070
Binary files /dev/null and b/out/renderer/assets/Layout-CvYBg1vI.js.gz differ
diff --git a/out/renderer/assets/MusicList-NCsRWE81.css b/out/renderer/assets/MusicList-NCsRWE81.css
new file mode 100644
index 0000000..e55e713
--- /dev/null
+++ b/out/renderer/assets/MusicList-NCsRWE81.css
@@ -0,0 +1,162 @@
+.music-title[data-v-1b137c3d] {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.music-title[data-v-1b137c3d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.music-page[data-v-1b137c3d] {
+ height: 100%;
+ width: 100%;
+ border-top-left-radius: 1rem;
+ border-top-right-radius: 1rem;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.75;
+ padding-left: 2rem;
+ padding-right: 2rem;
+}
+.music-page[data-v-1b137c3d]:is(.dark *) {
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.75;
+}
+.music-page[data-v-1b137c3d] {
+ -webkit-backdrop-filter: blur(20px);
+ backdrop-filter: blur(20px);
+}
+.music-close[data-v-1b137c3d] {
+ display: flex;
+ cursor: pointer;
+ align-items: center;
+ gap: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.music-close[data-v-1b137c3d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.music-close .icon[data-v-1b137c3d] {
+ font-size: 1.875rem;
+ line-height: 2.25rem;
+}
+.music-content[data-v-1b137c3d] {
+ display: flex;
+ height: calc(100% - 60px);
+}
+.music-info[data-v-1b137c3d] {
+ display: flex;
+ width: 25%;
+ flex-shrink: 0;
+ flex-direction: column;
+ padding-right: 2rem;
+}
+.music-info .music-cover[data-v-1b137c3d] {
+ margin-bottom: 1rem;
+ aspect-ratio: 1 / 1;
+ min-height: 250px;
+ width: 100%;
+ overflow: hidden;
+ border-radius: 1rem;
+}
+.music-info .music-cover .cover-img[data-v-1b137c3d] {
+ height: 100%;
+ width: 100%;
+ -o-object-fit: cover;
+ object-fit: cover;
+}
+.music-info .creator-info[data-v-1b137c3d] {
+ margin-bottom: 1rem;
+ display: flex;
+ align-items: center;
+}
+.music-info .creator-info .creator-name[data-v-1b137c3d] {
+ margin-left: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(55 65 81 / var(--tw-text-opacity, 1));
+}
+.music-info .creator-info .creator-name[data-v-1b137c3d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1));
+}
+.music-info .music-desc[data-v-1b137c3d] {
+ padding-right: 1rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ line-height: 1.625;
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+.music-info .music-desc[data-v-1b137c3d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.music-list[data-v-1b137c3d] {
+ min-height: 0px;
+ flex-grow: 1;
+}
+.music-list-container[data-v-1b137c3d] {
+ position: relative;
+ display: flex;
+ min-height: 0px;
+ flex-grow: 1;
+ flex-direction: column;
+}
+.music-list-content[data-v-1b137c3d] {
+ min-height: calc(80vh - 60px);
+}
+.music-list[data-v-1b137c3d] .n-virtual-list__scroll {
+ scrollbar-width: none;
+}
+.music-list[data-v-1b137c3d] .n-virtual-list__scroll::-webkit-scrollbar {
+ display: none;
+}
+.mobile .music-page[data-v-1b137c3d] {
+ padding-left: 1rem;
+ padding-right: 1rem;
+}
+.mobile .music-content[data-v-1b137c3d] {
+ flex-direction: column;
+}
+.mobile .music-info[data-v-1b137c3d] {
+ margin-bottom: 0.5rem;
+ display: flex;
+ width: 100%;
+ flex-direction: row;
+ padding-right: 0px;
+}
+.mobile .music-info .music-cover[data-v-1b137c3d] {
+ margin-bottom: 1rem;
+ height: 100px;
+ width: 100px;
+ overflow: hidden;
+ border-radius: 0.5rem;
+}
+.mobile .music-info .music-detail[data-v-1b137c3d] {
+ margin-left: 1rem;
+ flex: 1 1 0%;
+}
+.loading-more[data-v-1b137c3d] {
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ text-align: center;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.loading-more[data-v-1b137c3d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.double-item[data-v-1b137c3d] {
+ margin-bottom: 0.5rem;
+ border-radius: 1.5rem;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.2;
+}
+.double-item[data-v-1b137c3d]:is(.dark *) {
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.2;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/MusicList-NCsRWE81.css.gz b/out/renderer/assets/MusicList-NCsRWE81.css.gz
new file mode 100644
index 0000000..11946ab
Binary files /dev/null and b/out/renderer/assets/MusicList-NCsRWE81.css.gz differ
diff --git a/out/renderer/assets/MusicList-s-QHu-iA.js b/out/renderer/assets/MusicList-s-QHu-iA.js
new file mode 100644
index 0000000..5fc8e31
--- /dev/null
+++ b/out/renderer/assets/MusicList-s-QHu-iA.js
@@ -0,0 +1,258 @@
+import { ad as request, d as defineComponent, r as ref, G as computed, E as watch, O as createBlock, f as withCtx, u as unref, g as useStore, j as openBlock, b as createBaseVNode, e as createVNode, t as toDisplayString, a7 as getImgUrl, n as normalizeClass, s as setAnimationClass, c as createElementBlock, T as createCommentVNode, U as PlayBottom, a4 as renderList, a2 as normalizeStyle, a3 as Fragment, ac as isMobile, a5 as setAnimationDelay, S as Scrollbar, aj as __unplugin_components_0, am as getMusicDetail, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { _ as __unplugin_components_2 } from "./Drawer-BEJ8Ydua.js";
+import { _ as __unplugin_components_2$2 } from "./Avatar-rQ2og-6c.js";
+import { _ as __unplugin_components_2$1 } from "./Ellipsis-D4R5dIX2.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+function getListByCat(params) {
+ return request.get("/top/playlist", {
+ params
+ });
+}
+function getListDetail(id) {
+ return request.get("/playlist/detail", { params: { id } });
+}
+function getAlbum(id) {
+ return request.get("/album", { params: { id } });
+}
+const _hoisted_1 = { class: "music-page" };
+const _hoisted_2 = { class: "music-header h-12 flex items-center justify-between" };
+const _hoisted_3 = { class: "music-title" };
+const _hoisted_4 = { class: "music-content" };
+const _hoisted_5 = { class: "music-info" };
+const _hoisted_6 = { class: "music-cover" };
+const _hoisted_7 = {
+ key: 0,
+ class: "creator-info"
+};
+const _hoisted_8 = { class: "creator-name" };
+const _hoisted_9 = {
+ key: 0,
+ class: "music-desc"
+};
+const _hoisted_10 = { class: "music-list-container" };
+const _hoisted_11 = { class: "music-list" };
+const _hoisted_12 = { class: "music-list-content" };
+const _hoisted_13 = {
+ key: 0,
+ class: "loading-more"
+};
+const pageSize = 20;
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "MusicList",
+ props: {
+ show: { type: Boolean },
+ name: {},
+ songList: {},
+ loading: { type: Boolean, default: false },
+ listInfo: {},
+ cover: { type: Boolean, default: true }
+ },
+ emits: ["update:show", "update:loading"],
+ setup(__props, { emit: __emit }) {
+ const store = useStore();
+ const props = __props;
+ const emit = __emit;
+ const page = ref(0);
+ const isLoadingMore = ref(false);
+ const displayedSongs = ref([]);
+ const loadingList = ref(false);
+ const total = computed(() => {
+ if (props.listInfo?.trackIds) {
+ return props.listInfo.trackIds.length;
+ }
+ return props.songList.length;
+ });
+ const formatDetail = computed(() => (detail) => {
+ const song = {
+ artists: detail.ar,
+ name: detail.al.name,
+ id: detail.al.id
+ };
+ detail.song = song;
+ detail.picUrl = detail.al.picUrl;
+ return detail;
+ });
+ const handlePlay = () => {
+ const tracks = props.songList || [];
+ store.commit(
+ "setPlayList",
+ tracks.map((item) => ({
+ ...item,
+ picUrl: item.al.picUrl,
+ song: {
+ artists: item.ar
+ }
+ }))
+ );
+ };
+ const close = () => {
+ emit("update:show", false);
+ };
+ const loadMoreSongs = async () => {
+ if (isLoadingMore.value || displayedSongs.value.length >= total.value) return;
+ isLoadingMore.value = true;
+ try {
+ if (props.listInfo?.trackIds) {
+ const start = page.value * pageSize;
+ const end = Math.min((page.value + 1) * pageSize, total.value);
+ const trackIds = props.listInfo.trackIds.slice(start, end).map((item) => item.id);
+ if (trackIds.length > 0) {
+ const { data } = await getMusicDetail(trackIds);
+ displayedSongs.value = [...displayedSongs.value, ...data.songs];
+ page.value++;
+ }
+ } else {
+ const start = page.value * pageSize;
+ const end = Math.min((page.value + 1) * pageSize, props.songList.length);
+ const newSongs = props.songList.slice(start, end);
+ displayedSongs.value = [...displayedSongs.value, ...newSongs];
+ page.value++;
+ }
+ } catch (error) {
+ console.error("加载歌曲失败:", error);
+ } finally {
+ isLoadingMore.value = false;
+ loadingList.value = false;
+ }
+ };
+ const getItemAnimationDelay = (index) => {
+ const currentPageIndex = index % pageSize;
+ return setAnimationDelay(currentPageIndex, 20);
+ };
+ const handleScroll = (e) => {
+ const target = e.target;
+ if (!target) return;
+ const { scrollTop, scrollHeight, clientHeight } = target;
+ if (scrollHeight - scrollTop - clientHeight < 100 && !isLoadingMore.value) {
+ loadMoreSongs();
+ }
+ };
+ watch(
+ () => props.show,
+ (newVal) => {
+ loadingList.value = newVal;
+ if (!props.cover) {
+ loadingList.value = false;
+ }
+ }
+ );
+ watch(
+ () => props.songList,
+ (newSongs) => {
+ page.value = 0;
+ displayedSongs.value = newSongs.slice(0, pageSize);
+ if (newSongs.length > pageSize) {
+ page.value = 1;
+ }
+ loadingList.value = false;
+ },
+ { immediate: true }
+ );
+ return (_ctx, _cache) => {
+ const _component_n_ellipsis = __unplugin_components_2$1;
+ const _component_n_image = NImage;
+ const _component_n_avatar = __unplugin_components_2$2;
+ const _component_n_scrollbar = Scrollbar;
+ const _component_n_spin = __unplugin_components_0;
+ const _component_n_drawer = __unplugin_components_2;
+ return openBlock(), createBlock(_component_n_drawer, {
+ show: _ctx.show,
+ height: unref(isMobile) ? "100%" : "80%",
+ placement: "bottom",
+ "block-scroll": "",
+ "mask-closable": "",
+ style: { backgroundColor: "transparent" },
+ to: `#layout-main`,
+ onMaskClick: close
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ createVNode(_component_n_ellipsis, { "line-clamp": 1 }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_3, toDisplayString(_ctx.name), 1)
+ ]),
+ _: 1
+ }),
+ createBaseVNode("div", { class: "music-close" }, [
+ createBaseVNode("i", {
+ class: "icon iconfont icon-icon_error",
+ onClick: close
+ })
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_4, [
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("div", _hoisted_6, [
+ createVNode(_component_n_image, {
+ src: unref(getImgUrl)(_ctx.cover ? _ctx.listInfo?.coverImgUrl : unref(displayedSongs)[0]?.picUrl, "500y500"),
+ class: normalizeClass(["cover-img", unref(setAnimationClass)("animate__fadeIn")]),
+ "preview-disabled": "",
+ "object-fit": "cover"
+ }, null, 8, ["src", "class"])
+ ]),
+ _ctx.listInfo?.creator ? (openBlock(), createElementBlock("div", _hoisted_7, [
+ createVNode(_component_n_avatar, {
+ round: "",
+ size: 24,
+ src: unref(getImgUrl)(_ctx.listInfo.creator.avatarUrl, "50y50")
+ }, null, 8, ["src"]),
+ createBaseVNode("span", _hoisted_8, toDisplayString(_ctx.listInfo.creator.nickname), 1)
+ ])) : createCommentVNode("", true),
+ createVNode(_component_n_scrollbar, { style: { "max-height": "200" } }, {
+ default: withCtx(() => [
+ _ctx.listInfo?.description ? (openBlock(), createElementBlock("div", _hoisted_9, toDisplayString(_ctx.listInfo.description), 1)) : createCommentVNode("", true),
+ createVNode(PlayBottom)
+ ]),
+ _: 1
+ })
+ ]),
+ createBaseVNode("div", _hoisted_10, [
+ createBaseVNode("div", _hoisted_11, [
+ createVNode(_component_n_scrollbar, { onScroll: handleScroll }, {
+ default: withCtx(() => [
+ createVNode(_component_n_spin, {
+ show: unref(loadingList) || _ctx.loading
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_12, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(displayedSongs), (item, index) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["double-item", unref(setAnimationClass)("animate__bounceInUp")]),
+ style: normalizeStyle(getItemAnimationDelay(index))
+ }, [
+ createVNode(SongItem, {
+ item: unref(formatDetail)(item),
+ onPlay: handlePlay
+ }, null, 8, ["item"])
+ ], 6);
+ }), 128)),
+ unref(isLoadingMore) ? (openBlock(), createElementBlock("div", _hoisted_13, "加载更多...")) : createCommentVNode("", true),
+ createVNode(PlayBottom)
+ ])
+ ]),
+ _: 1
+ }, 8, ["show"])
+ ]),
+ _: 1
+ })
+ ]),
+ createVNode(PlayBottom)
+ ])
+ ])
+ ])
+ ]),
+ _: 1
+ }, 8, ["show", "height"]);
+ };
+ }
+});
+const MusicList = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-1b137c3d"]]);
+export {
+ MusicList as M,
+ getListDetail as a,
+ getListByCat as b,
+ getAlbum as g
+};
diff --git a/out/renderer/assets/MusicList-s-QHu-iA.js.gz b/out/renderer/assets/MusicList-s-QHu-iA.js.gz
new file mode 100644
index 0000000..9984154
Binary files /dev/null and b/out/renderer/assets/MusicList-s-QHu-iA.js.gz differ
diff --git a/out/renderer/assets/MvPlayer-BPFZslTY.css b/out/renderer/assets/MvPlayer-BPFZslTY.css
new file mode 100644
index 0000000..fd0edf9
--- /dev/null
+++ b/out/renderer/assets/MvPlayer-BPFZslTY.css
@@ -0,0 +1,177 @@
+.mv-detail[data-v-f4c63e83] {
+ height: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.mv-detail[data-v-f4c63e83]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.mv-detail-title[data-v-f4c63e83] {
+ position: fixed;
+ top: 0px;
+ left: 0px;
+ right: 0px;
+ z-index: 10;
+ padding: 1rem;
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ background: linear-gradient(to bottom, rgba(0, 0, 0, 0.7), transparent);
+}
+.mv-detail-title .title[data-v-f4c63e83] {
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.video-container[data-v-f4c63e83] {
+ position: relative;
+ height: 100%;
+ width: 100%;
+}
+.video-container .video-player[data-v-f4c63e83] {
+ height: 100%;
+ width: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ -o-object-fit: contain;
+ object-fit: contain;
+}
+.video-container .play-hint[data-v-f4c63e83] {
+ position: absolute;
+ inset: 0px;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.5;
+}
+.video-container .play-hint .n-button[data-v-f4c63e83] {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.video-container .play-hint .n-button[data-v-f4c63e83]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.video-container .custom-controls[data-v-f4c63e83] {
+ position: absolute;
+ bottom: 0px;
+ left: 0px;
+ right: 0px;
+ padding: 1rem;
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
+}
+.video-container .custom-controls .controls-main[data-v-f4c63e83] {
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+}
+.video-container .custom-controls .controls-main .left-controls[data-v-f4c63e83],
+.video-container .custom-controls .controls-main .right-controls[data-v-f4c63e83] {
+ display: flex;
+ align-items: center;
+ gap: 0.5rem;
+}
+.video-container .custom-controls .controls-main .left-controls .n-button[data-v-f4c63e83],
+.video-container .custom-controls .controls-main .right-controls .n-button[data-v-f4c63e83] {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.video-container .custom-controls .controls-main .left-controls .n-button[data-v-f4c63e83]:hover,
+.video-container .custom-controls .controls-main .right-controls .n-button[data-v-f4c63e83]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.video-container .custom-controls .controls-main .left-controls .time-display[data-v-f4c63e83],
+.video-container .custom-controls .controls-main .right-controls .time-display[data-v-f4c63e83] {
+ margin-left: 1rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mode-hint[data-v-f4c63e83] {
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ display: flex;
+ --tw-translate-x: -50%;
+ --tw-translate-y: -50%;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+ flex-direction: column;
+ align-items: center;
+}
+.mode-hint .mode-icon[data-v-f4c63e83] {
+ margin-bottom: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mode-hint .mode-text[data-v-f4c63e83] {
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.custom-slider[data-v-f4c63e83] .n-slider {
+ --n-rail-height: 4px;
+ --n-rail-color: rgba(255, 255, 255, 0.2);
+ --n-fill-color: #10b981;
+ --n-handle-size: 12px;
+ --n-handle-color: #10b981;
+}
+.progress-bar[data-v-f4c63e83] {
+ margin-bottom: 1rem;
+}
+.progress-bar .progress-rail[data-v-f4c63e83] {
+ position: relative;
+ height: 0.25rem;
+ width: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(75 85 99 / var(--tw-bg-opacity, 1));
+}
+.progress-bar .progress-rail .progress-buffer[data-v-f4c63e83] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ height: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(156 163 175 / var(--tw-bg-opacity, 1));
+}
+.volume-control[data-v-f4c63e83] {
+ display: flex;
+ align-items: center;
+ gap: 0.5rem;
+}
+.volume-control .volume-slider[data-v-f4c63e83] {
+ width: 100px;
+}
+.controls-hidden[data-v-f4c63e83] {
+ opacity: 0;
+ pointer-events: none;
+}
+.cursor-hidden[data-v-f4c63e83] {
+ cursor: none;
+}
+.title-hidden[data-v-f4c63e83] {
+ opacity: 0;
+}
+.fade-enter-active[data-v-f4c63e83],
+.fade-leave-active[data-v-f4c63e83] {
+ transition: opacity 0.3s ease;
+}
+.fade-enter-from[data-v-f4c63e83],
+.fade-leave-to[data-v-f4c63e83] {
+ opacity: 0;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/MvPlayer-BPFZslTY.css.gz b/out/renderer/assets/MvPlayer-BPFZslTY.css.gz
new file mode 100644
index 0000000..c3be8aa
Binary files /dev/null and b/out/renderer/assets/MvPlayer-BPFZslTY.css.gz differ
diff --git a/out/renderer/assets/MvPlayer-I4IDK1xL.js b/out/renderer/assets/MvPlayer-I4IDK1xL.js
new file mode 100644
index 0000000..30aa195
--- /dev/null
+++ b/out/renderer/assets/MvPlayer-I4IDK1xL.js
@@ -0,0 +1,670 @@
+import { ad as request, d as defineComponent, r as ref, E as watch, o as onMounted, a1 as onUnmounted, G as computed, O as createBlock, f as withCtx, g as useStore, j as openBlock, b as createBaseVNode, n as normalizeClass, c as createElementBlock, e as createVNode, u as unref, B as Button, T as createCommentVNode, a2 as normalizeStyle, k as createTextVNode, t as toDisplayString, ak as Transition, M as nextTick, aj as __unplugin_components_0$1, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { N as NIcon } from "./Icon-DucaliTK.js";
+import { _ as __unplugin_components_0 } from "./Slider-BA6NituQ.js";
+import { _ as __unplugin_components_3 } from "./Image-DXClIklC.js";
+import { _ as __unplugin_components_2 } from "./Drawer-BEJ8Ydua.js";
+import { _ as __unplugin_components_2$1 } from "./Ellipsis-D4R5dIX2.js";
+const getTopMv = (params) => {
+ return request({
+ url: "/mv/all",
+ method: "get",
+ params
+ });
+};
+const getAllMv = (params) => {
+ return request({
+ url: "/mv/all",
+ method: "get",
+ params
+ });
+};
+const getMvUrl = (id) => {
+ return request.get("/mv/url", {
+ params: {
+ id
+ }
+ });
+};
+const _hoisted_1 = { class: "mv-detail" };
+const _hoisted_2 = ["src"];
+const _hoisted_3 = { class: "progress-bar custom-slider" };
+const _hoisted_4 = { class: "progress-rail" };
+const _hoisted_5 = { class: "controls-main" };
+const _hoisted_6 = { class: "left-controls" };
+const _hoisted_7 = {
+ key: 1,
+ class: "ri-skip-back-line"
+};
+const _hoisted_8 = {
+ key: 1,
+ class: "ri-skip-forward-line"
+};
+const _hoisted_9 = { class: "time-display" };
+const _hoisted_10 = { class: "right-controls" };
+const _hoisted_11 = {
+ key: 0,
+ class: "volume-control custom-slider"
+};
+const _hoisted_12 = {
+ key: 0,
+ class: "mode-hint"
+};
+const _hoisted_13 = { class: "mode-text" };
+const _hoisted_14 = { class: "title" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "MvPlayer",
+ props: {
+ show: { type: Boolean, default: false },
+ currentMv: { default: void 0 },
+ noList: { type: Boolean, default: false }
+ },
+ emits: ["update:show", "next", "prev"],
+ setup(__props, { emit: __emit }) {
+ const PLAY_MODE = {
+ Single: "single",
+ Auto: "auto"
+ };
+ const props = __props;
+ const emit = __emit;
+ const store = useStore();
+ const mvUrl = ref();
+ const playMode = ref(PLAY_MODE.Auto);
+ const videoRef = ref();
+ const isPlaying = ref(false);
+ const currentTime = ref(0);
+ const duration = ref(0);
+ const progress = ref(0);
+ const bufferedProgress = ref(0);
+ const volume = ref(100);
+ const showControls = ref(true);
+ let controlsTimer = null;
+ const formatTime = (seconds) => {
+ const minutes = Math.floor(seconds / 60);
+ const remainingSeconds = Math.floor(seconds % 60);
+ return `${minutes.toString().padStart(2, "0")}:${remainingSeconds.toString().padStart(2, "0")}`;
+ };
+ const togglePlay = () => {
+ if (!videoRef.value) return;
+ if (isPlaying.value) {
+ videoRef.value.pause();
+ } else {
+ videoRef.value.play();
+ }
+ resetCursorTimer();
+ };
+ const toggleMute = () => {
+ if (!videoRef.value) return;
+ if (volume.value === 0) {
+ volume.value = 100;
+ } else {
+ volume.value = 0;
+ }
+ };
+ watch(volume, (newVolume) => {
+ if (videoRef.value) {
+ videoRef.value.volume = newVolume / 100;
+ }
+ });
+ const handleProgressChange = (value) => {
+ if (!videoRef.value || !duration.value) return;
+ const newTime = value / 100 * duration.value;
+ videoRef.value.currentTime = newTime;
+ };
+ const handleTimeUpdate = () => {
+ if (!videoRef.value) return;
+ currentTime.value = videoRef.value.currentTime;
+ if (!isDragging.value) {
+ progress.value = currentTime.value / duration.value * 100;
+ }
+ if (videoRef.value.buffered.length > 0) {
+ bufferedProgress.value = videoRef.value.buffered.end(0) / duration.value * 100;
+ }
+ };
+ const handleLoadedMetadata = () => {
+ if (!videoRef.value) return;
+ duration.value = videoRef.value.duration;
+ };
+ const resetControlsTimer = () => {
+ if (controlsTimer) {
+ clearTimeout(controlsTimer);
+ }
+ showControls.value = true;
+ controlsTimer = setTimeout(() => {
+ if (isPlaying.value) {
+ showControls.value = false;
+ }
+ }, 3e3);
+ };
+ const handleMouseMove = () => {
+ resetControlsTimer();
+ resetCursorTimer();
+ };
+ onMounted(() => {
+ document.addEventListener("mousemove", handleMouseMove);
+ });
+ onUnmounted(() => {
+ document.removeEventListener("mousemove", handleMouseMove);
+ if (controlsTimer) {
+ clearTimeout(controlsTimer);
+ }
+ if (cursorTimer) {
+ clearTimeout(cursorTimer);
+ }
+ unlockScreenOrientation();
+ });
+ watch(
+ () => props.currentMv,
+ async (newMv) => {
+ if (newMv) {
+ await loadMvUrl(newMv);
+ }
+ }
+ );
+ const autoPlayBlocked = ref(false);
+ const playLoading = ref(false);
+ const loadMvUrl = async (mv) => {
+ playLoading.value = true;
+ autoPlayBlocked.value = false;
+ try {
+ const res = await getMvUrl(mv.id);
+ mvUrl.value = res.data.data.url;
+ await nextTick();
+ if (videoRef.value) {
+ try {
+ await videoRef.value.play();
+ } catch (error) {
+ console.warn("自动播放失败,可能需要用户交互:", error);
+ autoPlayBlocked.value = true;
+ }
+ }
+ } catch (error) {
+ console.error("加载MV地址失败:", error);
+ } finally {
+ playLoading.value = false;
+ }
+ };
+ const handleClose = () => {
+ emit("update:show", false);
+ if (store.state.playMusicUrl) {
+ store.commit("setIsPlay", true);
+ }
+ };
+ const handleEnded = () => {
+ if (playMode.value === PLAY_MODE.Single) {
+ if (props.currentMv) {
+ loadMvUrl(props.currentMv);
+ }
+ } else {
+ emit("next", (value) => {
+ nextLoading.value = value;
+ });
+ }
+ };
+ const togglePlayMode = () => {
+ playMode.value = playMode.value === PLAY_MODE.Auto ? PLAY_MODE.Single : PLAY_MODE.Auto;
+ showModeHint.value = true;
+ setTimeout(() => {
+ showModeHint.value = false;
+ }, 1500);
+ };
+ const isDragging = ref(false);
+ const videoContainerRef = ref();
+ const isFullscreen = ref(false);
+ const checkFullscreenAPI = () => {
+ const doc = document;
+ return {
+ requestFullscreen: videoContainerRef.value?.requestFullscreen || videoContainerRef.value?.webkitRequestFullscreen || videoContainerRef.value?.mozRequestFullScreen || videoContainerRef.value?.msRequestFullscreen,
+ exitFullscreen: doc.exitFullscreen || doc.webkitExitFullscreen || doc.mozCancelFullScreen || doc.msExitFullscreen,
+ fullscreenElement: doc.fullscreenElement || doc.webkitFullscreenElement || doc.mozFullScreenElement || doc.msFullscreenElement,
+ fullscreenEnabled: doc.fullscreenEnabled || doc.webkitFullscreenEnabled || doc.mozFullScreenEnabled || doc.msFullscreenEnabled
+ };
+ };
+ const lockScreenOrientation = async () => {
+ try {
+ if ("orientation" in screen) {
+ await screen.orientation.lock("landscape");
+ }
+ } catch (error) {
+ console.warn("无法锁定屏幕方向:", error);
+ }
+ };
+ const unlockScreenOrientation = () => {
+ try {
+ if ("orientation" in screen) {
+ screen.orientation.unlock();
+ }
+ } catch (error) {
+ console.warn("无法解锁屏幕方向:", error);
+ }
+ };
+ const toggleFullscreen = async () => {
+ const api = checkFullscreenAPI();
+ if (!api.fullscreenEnabled) {
+ console.warn("全屏API不可用");
+ return;
+ }
+ try {
+ if (!api.fullscreenElement) {
+ await videoContainerRef.value?.requestFullscreen();
+ isFullscreen.value = true;
+ if (window.innerWidth <= 768) {
+ await lockScreenOrientation();
+ }
+ } else {
+ await document.exitFullscreen();
+ isFullscreen.value = false;
+ if (window.innerWidth <= 768) {
+ unlockScreenOrientation();
+ }
+ }
+ } catch (error) {
+ console.error("切换全屏失败:", error);
+ }
+ };
+ const handleFullscreenChange = () => {
+ const api = checkFullscreenAPI();
+ isFullscreen.value = !!api.fullscreenElement;
+ };
+ onMounted(() => {
+ document.addEventListener("fullscreenchange", handleFullscreenChange);
+ document.addEventListener("webkitfullscreenchange", handleFullscreenChange);
+ document.addEventListener("mozfullscreenchange", handleFullscreenChange);
+ document.addEventListener("MSFullscreenChange", handleFullscreenChange);
+ });
+ onUnmounted(() => {
+ document.removeEventListener("fullscreenchange", handleFullscreenChange);
+ document.removeEventListener("webkitfullscreenchange", handleFullscreenChange);
+ document.removeEventListener("mozfullscreenchange", handleFullscreenChange);
+ document.removeEventListener("MSFullscreenChange", handleFullscreenChange);
+ });
+ const handleKeyPress = (e) => {
+ if (e.key === "f" || e.key === "F") {
+ toggleFullscreen();
+ }
+ };
+ onMounted(() => {
+ document.addEventListener("keydown", handleKeyPress);
+ });
+ onUnmounted(() => {
+ document.removeEventListener("keydown", handleKeyPress);
+ });
+ const showModeHint = ref(false);
+ const prevLoading = ref(false);
+ const nextLoading = ref(false);
+ const handlePrev = () => {
+ prevLoading.value = true;
+ emit("prev", (value) => {
+ prevLoading.value = value;
+ });
+ };
+ const handleNext = () => {
+ nextLoading.value = true;
+ emit("next", (value) => {
+ nextLoading.value = value;
+ });
+ };
+ const showCursor = ref(true);
+ let cursorTimer = null;
+ const resetCursorTimer = () => {
+ if (cursorTimer) {
+ clearTimeout(cursorTimer);
+ }
+ showCursor.value = true;
+ if (isPlaying.value && !showControls.value) {
+ cursorTimer = setTimeout(() => {
+ showCursor.value = false;
+ }, 3e3);
+ }
+ };
+ watch(isPlaying, (newValue) => {
+ if (!newValue) {
+ showCursor.value = true;
+ if (cursorTimer) {
+ clearTimeout(cursorTimer);
+ }
+ } else {
+ resetCursorTimer();
+ }
+ });
+ watch(showControls, (newValue) => {
+ if (newValue) {
+ showCursor.value = true;
+ if (cursorTimer) {
+ clearTimeout(cursorTimer);
+ }
+ } else {
+ resetCursorTimer();
+ }
+ });
+ const isMobile = computed(() => store.state.isMobile);
+ return (_ctx, _cache) => {
+ const _component_n_spin = __unplugin_components_0$1;
+ const _component_n_ellipsis = __unplugin_components_2$1;
+ const _component_n_drawer = __unplugin_components_2;
+ return openBlock(), createBlock(_component_n_drawer, {
+ show: _ctx.show,
+ height: "100%",
+ placement: "bottom",
+ "z-index": 999999999,
+ to: `#layout-main`
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1, [
+ createBaseVNode("div", {
+ ref_key: "videoContainerRef",
+ ref: videoContainerRef,
+ class: normalizeClass(["video-container", { "cursor-hidden": !showCursor.value }])
+ }, [
+ createBaseVNode("video", {
+ ref_key: "videoRef",
+ ref: videoRef,
+ src: mvUrl.value,
+ class: "video-player",
+ onEnded: handleEnded,
+ onTimeupdate: handleTimeUpdate,
+ onLoadedmetadata: handleLoadedMetadata,
+ onPlay: _cache[0] || (_cache[0] = ($event) => isPlaying.value = true),
+ onPause: _cache[1] || (_cache[1] = ($event) => isPlaying.value = false),
+ onClick: togglePlay
+ }, null, 40, _hoisted_2),
+ autoPlayBlocked.value ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: "play-hint",
+ onClick: togglePlay
+ }, [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ size: "large"
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "48" }, {
+ default: withCtx(() => _cache[4] || (_cache[4] = [
+ createBaseVNode("i", { class: "ri-play-circle-line" }, null, -1)
+ ])),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ])) : createCommentVNode("", true),
+ createBaseVNode("div", {
+ class: normalizeClass(["custom-controls", { "controls-hidden": !showControls.value }])
+ }, [
+ createBaseVNode("div", _hoisted_3, [
+ createVNode(unref(__unplugin_components_0), {
+ value: progress.value,
+ "onUpdate:value": [
+ _cache[2] || (_cache[2] = ($event) => progress.value = $event),
+ handleProgressChange
+ ],
+ min: 0,
+ max: 100,
+ tooltip: false,
+ step: 0.1
+ }, {
+ rail: withCtx(() => [
+ createBaseVNode("div", _hoisted_4, [
+ createBaseVNode("div", {
+ class: "progress-buffer",
+ style: normalizeStyle({ width: `${bufferedProgress.value}%` })
+ }, null, 4)
+ ])
+ ]),
+ _: 1
+ }, 8, ["value"])
+ ]),
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("div", _hoisted_6, [
+ !props.noList ? (openBlock(), createBlock(unref(__unplugin_components_3), {
+ key: 0,
+ placement: "top"
+ }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: handlePrev
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ prevLoading.value ? (openBlock(), createBlock(_component_n_spin, {
+ key: 0,
+ size: "small"
+ })) : (openBlock(), createElementBlock("i", _hoisted_7))
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ _cache[5] || (_cache[5] = createTextVNode(" 上一个 "))
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ createVNode(unref(__unplugin_components_3), { placement: "top" }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: togglePlay
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ playLoading.value ? (openBlock(), createBlock(_component_n_spin, {
+ key: 0,
+ size: "small"
+ })) : (openBlock(), createElementBlock("i", {
+ key: 1,
+ class: normalizeClass(isPlaying.value ? "ri-pause-line" : "ri-play-line")
+ }, null, 2))
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ createTextVNode(" " + toDisplayString(isPlaying.value ? "暂停" : "播放"), 1)
+ ]),
+ _: 1
+ }),
+ !props.noList ? (openBlock(), createBlock(unref(__unplugin_components_3), {
+ key: 1,
+ placement: "top"
+ }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: handleNext
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ nextLoading.value ? (openBlock(), createBlock(_component_n_spin, {
+ key: 0,
+ size: "small"
+ })) : (openBlock(), createElementBlock("i", _hoisted_8))
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ _cache[6] || (_cache[6] = createTextVNode(" 下一个 "))
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ createBaseVNode("div", _hoisted_9, toDisplayString(formatTime(currentTime.value)) + " / " + toDisplayString(formatTime(duration.value)), 1)
+ ]),
+ createBaseVNode("div", _hoisted_10, [
+ !isMobile.value ? (openBlock(), createElementBlock("div", _hoisted_11, [
+ createVNode(unref(__unplugin_components_3), { placement: "top" }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: toggleMute
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(volume.value === 0 ? "ri-volume-mute-line" : "ri-volume-up-line")
+ }, null, 2)
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ createTextVNode(" " + toDisplayString(volume.value === 0 ? "取消静音" : "静音"), 1)
+ ]),
+ _: 1
+ }),
+ createVNode(unref(__unplugin_components_0), {
+ value: volume.value,
+ "onUpdate:value": _cache[3] || (_cache[3] = ($event) => volume.value = $event),
+ min: 0,
+ max: 100,
+ tooltip: false,
+ class: "volume-slider"
+ }, null, 8, ["value"])
+ ])) : createCommentVNode("", true),
+ !props.noList ? (openBlock(), createBlock(unref(__unplugin_components_3), {
+ key: 1,
+ placement: "top"
+ }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ class: "play-mode-btn",
+ onClick: togglePlayMode
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(
+ playMode.value === "single" ? "ri-repeat-one-line" : "ri-play-list-line"
+ )
+ }, null, 2)
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ createTextVNode(" " + toDisplayString(playMode.value === "single" ? "单曲循环" : "列表循环"), 1)
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ createVNode(unref(__unplugin_components_3), { placement: "top" }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: toggleFullscreen
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(isFullscreen.value ? "ri-fullscreen-exit-line" : "ri-fullscreen-line")
+ }, null, 2)
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ createTextVNode(" " + toDisplayString(isFullscreen.value ? "退出全屏" : "全屏"), 1)
+ ]),
+ _: 1
+ }),
+ createVNode(unref(__unplugin_components_3), { placement: "top" }, {
+ trigger: withCtx(() => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ circle: "",
+ onClick: handleClose
+ }, {
+ icon: withCtx(() => [
+ createVNode(unref(NIcon), { size: "24" }, {
+ default: withCtx(() => _cache[7] || (_cache[7] = [
+ createBaseVNode("i", { class: "ri-close-line" }, null, -1)
+ ])),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ _cache[8] || (_cache[8] = createTextVNode(" 关闭 "))
+ ]),
+ _: 1
+ })
+ ])
+ ])
+ ], 2),
+ createVNode(Transition, { name: "fade" }, {
+ default: withCtx(() => [
+ showModeHint.value ? (openBlock(), createElementBlock("div", _hoisted_12, [
+ createVNode(unref(NIcon), {
+ size: "48",
+ class: "mode-icon"
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(playMode.value === "single" ? "ri-repeat-one-line" : "ri-play-list-line")
+ }, null, 2)
+ ]),
+ _: 1
+ }),
+ createBaseVNode("div", _hoisted_13, toDisplayString(playMode.value === "single" ? "单曲循环" : "自动播放下一个"), 1)
+ ])) : createCommentVNode("", true)
+ ]),
+ _: 1
+ })
+ ], 2),
+ createBaseVNode("div", {
+ class: normalizeClass(["mv-detail-title", { "title-hidden": !showControls.value }])
+ }, [
+ createBaseVNode("div", _hoisted_14, [
+ createVNode(_component_n_ellipsis, null, {
+ default: withCtx(() => [
+ createTextVNode(toDisplayString(_ctx.currentMv?.name), 1)
+ ]),
+ _: 1
+ })
+ ])
+ ], 2)
+ ])
+ ]),
+ _: 1
+ }, 8, ["show"]);
+ };
+ }
+});
+const MvPlayer = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f4c63e83"]]);
+export {
+ MvPlayer as M,
+ getAllMv as a,
+ getTopMv as g
+};
diff --git a/out/renderer/assets/MvPlayer-I4IDK1xL.js.gz b/out/renderer/assets/MvPlayer-I4IDK1xL.js.gz
new file mode 100644
index 0000000..fa6e166
Binary files /dev/null and b/out/renderer/assets/MvPlayer-I4IDK1xL.js.gz differ
diff --git a/out/renderer/assets/PlayBar-BNzUvTGp.js b/out/renderer/assets/PlayBar-BNzUvTGp.js
new file mode 100644
index 0000000..a12d40f
--- /dev/null
+++ b/out/renderer/assets/PlayBar-BNzUvTGp.js
@@ -0,0 +1,1620 @@
+import { r as ref, G as computed, D as useMemo, $ as provide, d as defineComponent, as as inject, at as useSsrAdapter, o as onMounted, aq as onActivated, au as onDeactivated, A as toRef, av as depx, aw as pxfy, l as h, ax as mergeProps, ay as VResizeObserver, az as XScrollbar, aA as store, ae as audioService, aB as getTextColors, E as watch, M as nextTick, R as isElectron, a1 as onUnmounted, aC as getHoverBackgroundColor, aD as animateGradient, a as onBeforeUnmount, j as openBlock, O as createBlock, f as withCtx, b as createBaseVNode, a2 as normalizeStyle, u as unref, e as createVNode, a7 as getImgUrl, t as toDisplayString, c as createElementBlock, a3 as Fragment, a4 as renderList, n as normalizeClass, T as createCommentVNode, aE as useDebounceFn, _ as _export_sfc, g as useStore, aF as useThrottleFn, aG as useTemplateRef, i as isRef, k as createTextVNode, ac as isMobile, s as setAnimationClass, aH as secondToMinute } from "./index-DKaFsuse.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { N as NImage, _ as __unplugin_components_3, a as __unplugin_components_5 } from "./Image-DXClIklC.js";
+import { _ as __unplugin_components_1 } from "./Layout-CvYBg1vI.js";
+import { _ as __unplugin_components_2 } from "./Drawer-BEJ8Ydua.js";
+import { c as cssrAnchorMetaName, a as c, b as beforeNextFrameOnce } from "./use-locale-DLWAOXez.js";
+import { _ as __unplugin_components_0 } from "./Slider-BA6NituQ.js";
+import { _ as __unplugin_components_2$1 } from "./Ellipsis-D4R5dIX2.js";
+function lowBit(n) {
+ return n & -n;
+}
+class FinweckTree {
+ /**
+ * @param l length of the array
+ * @param min min value of the array
+ */
+ constructor(l, min) {
+ this.l = l;
+ this.min = min;
+ const ft = new Array(l + 1);
+ for (let i = 0; i < l + 1; ++i) {
+ ft[i] = 0;
+ }
+ this.ft = ft;
+ }
+ /**
+ * Add arr[i] by n, start from 0
+ * @param i the index of the element to be added
+ * @param n the value to be added
+ */
+ add(i, n) {
+ if (n === 0)
+ return;
+ const { l, ft } = this;
+ i += 1;
+ while (i <= l) {
+ ft[i] += n;
+ i += lowBit(i);
+ }
+ }
+ /**
+ * Get the value of index i
+ * @param i index
+ * @returns value of the index
+ */
+ get(i) {
+ return this.sum(i + 1) - this.sum(i);
+ }
+ /**
+ * Get the sum of first i elements
+ * @param i count of head elements to be added
+ * @returns the sum of first i elements
+ */
+ sum(i) {
+ if (i === void 0)
+ i = this.l;
+ if (i <= 0)
+ return 0;
+ const { ft, min, l } = this;
+ if (i > l)
+ throw new Error("[FinweckTree.sum]: `i` is larger than length.");
+ let ret = i * min;
+ while (i > 0) {
+ ret += ft[i];
+ i -= lowBit(i);
+ }
+ return ret;
+ }
+ /**
+ * Get the largest count of head elements whose sum are <= threshold
+ * @param threshold
+ * @returns the largest count of head elements whose sum are <= threshold
+ */
+ getBound(threshold) {
+ let l = 0;
+ let r = this.l;
+ while (r > l) {
+ const m = Math.floor((l + r) / 2);
+ const sumM = this.sum(m);
+ if (sumM > threshold) {
+ r = m;
+ continue;
+ } else if (sumM < threshold) {
+ if (l === m) {
+ if (this.sum(l + 1) <= threshold)
+ return l + 1;
+ return m;
+ }
+ l = m;
+ } else {
+ return m;
+ }
+ }
+ return l;
+ }
+}
+let maybeTouch;
+function ensureMaybeTouch() {
+ if (typeof document === "undefined")
+ return false;
+ if (maybeTouch === void 0) {
+ if ("matchMedia" in window) {
+ maybeTouch = window.matchMedia("(pointer:coarse)").matches;
+ } else {
+ maybeTouch = false;
+ }
+ }
+ return maybeTouch;
+}
+let wheelScale;
+function ensureWheelScale() {
+ if (typeof document === "undefined")
+ return 1;
+ if (wheelScale === void 0) {
+ wheelScale = "chrome" in window ? window.devicePixelRatio : 1;
+ }
+ return wheelScale;
+}
+const xScrollInjextionKey = "VVirtualListXScroll";
+function setupXScroll({ columnsRef, renderColRef, renderItemWithColsRef }) {
+ const listWidthRef = ref(0);
+ const scrollLeftRef = ref(0);
+ const xFinweckTreeRef = computed(() => {
+ const columns = columnsRef.value;
+ if (columns.length === 0) {
+ return null;
+ }
+ const ft = new FinweckTree(columns.length, 0);
+ columns.forEach((column, index) => {
+ ft.add(index, column.width);
+ });
+ return ft;
+ });
+ const startIndexRef = useMemo(() => {
+ const xFinweckTree = xFinweckTreeRef.value;
+ if (xFinweckTree !== null) {
+ return Math.max(xFinweckTree.getBound(scrollLeftRef.value) - 1, 0);
+ } else {
+ return 0;
+ }
+ });
+ const getLeft = (index) => {
+ const xFinweckTree = xFinweckTreeRef.value;
+ if (xFinweckTree !== null) {
+ return xFinweckTree.sum(index);
+ } else {
+ return 0;
+ }
+ };
+ const endIndexRef = useMemo(() => {
+ const xFinweckTree = xFinweckTreeRef.value;
+ if (xFinweckTree !== null) {
+ return Math.min(xFinweckTree.getBound(scrollLeftRef.value + listWidthRef.value) + 1, columnsRef.value.length - 1);
+ } else {
+ return 0;
+ }
+ });
+ provide(xScrollInjextionKey, {
+ startIndexRef,
+ endIndexRef,
+ columnsRef,
+ renderColRef,
+ renderItemWithColsRef,
+ getLeft
+ });
+ return {
+ listWidthRef,
+ scrollLeftRef
+ };
+}
+const VirtualListRow = defineComponent({
+ name: "VirtualListRow",
+ props: {
+ index: { type: Number, required: true },
+ item: {
+ type: Object,
+ required: true
+ }
+ },
+ setup() {
+ const { startIndexRef, endIndexRef, columnsRef, getLeft, renderColRef, renderItemWithColsRef } = (
+ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
+ inject(xScrollInjextionKey)
+ );
+ return {
+ startIndex: startIndexRef,
+ endIndex: endIndexRef,
+ columns: columnsRef,
+ renderCol: renderColRef,
+ renderItemWithCols: renderItemWithColsRef,
+ getLeft
+ };
+ },
+ render() {
+ const { startIndex, endIndex, columns, renderCol, renderItemWithCols, getLeft, item } = this;
+ if (renderItemWithCols != null) {
+ return renderItemWithCols({
+ itemIndex: this.index,
+ startColIndex: startIndex,
+ endColIndex: endIndex,
+ allColumns: columns,
+ item,
+ getLeft
+ });
+ }
+ if (renderCol != null) {
+ const items = [];
+ for (let i = startIndex; i <= endIndex; ++i) {
+ const column = columns[i];
+ items.push(renderCol({ column, left: getLeft(i), item }));
+ }
+ return items;
+ }
+ return null;
+ }
+});
+const styles = c(".v-vl", {
+ maxHeight: "inherit",
+ height: "100%",
+ overflow: "auto",
+ minWidth: "1px"
+ // a zero width container won't be scrollable
+}, [
+ c("&:not(.v-vl--show-scrollbar)", {
+ scrollbarWidth: "none"
+ }, [
+ c("&::-webkit-scrollbar, &::-webkit-scrollbar-track-piece, &::-webkit-scrollbar-thumb", {
+ width: 0,
+ height: 0,
+ display: "none"
+ })
+ ])
+]);
+const VVirtualList = defineComponent({
+ name: "VirtualList",
+ inheritAttrs: false,
+ props: {
+ showScrollbar: {
+ type: Boolean,
+ default: true
+ },
+ columns: {
+ type: Array,
+ default: () => []
+ },
+ renderCol: Function,
+ renderItemWithCols: Function,
+ items: {
+ type: Array,
+ default: () => []
+ },
+ // it is suppose to be the min height
+ itemSize: {
+ type: Number,
+ required: true
+ },
+ itemResizable: Boolean,
+ itemsStyle: [String, Object],
+ visibleItemsTag: {
+ type: [String, Object],
+ default: "div"
+ },
+ visibleItemsProps: Object,
+ ignoreItemResize: Boolean,
+ onScroll: Function,
+ onWheel: Function,
+ onResize: Function,
+ defaultScrollKey: [Number, String],
+ defaultScrollIndex: Number,
+ keyField: {
+ type: String,
+ default: "key"
+ },
+ // Whether it is a good API?
+ // ResizeObserver + footer & header is not enough.
+ // Too complex for simple case
+ paddingTop: {
+ type: [Number, String],
+ default: 0
+ },
+ paddingBottom: {
+ type: [Number, String],
+ default: 0
+ }
+ },
+ setup(props) {
+ const ssrAdapter = useSsrAdapter();
+ styles.mount({
+ id: "vueuc/virtual-list",
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ ssr: ssrAdapter
+ });
+ onMounted(() => {
+ const { defaultScrollIndex, defaultScrollKey } = props;
+ if (defaultScrollIndex !== void 0 && defaultScrollIndex !== null) {
+ scrollTo({ index: defaultScrollIndex });
+ } else if (defaultScrollKey !== void 0 && defaultScrollKey !== null) {
+ scrollTo({ key: defaultScrollKey });
+ }
+ });
+ let isDeactivated = false;
+ let activateStateInitialized = false;
+ onActivated(() => {
+ isDeactivated = false;
+ if (!activateStateInitialized) {
+ activateStateInitialized = true;
+ return;
+ }
+ scrollTo({ top: scrollTopRef.value, left: scrollLeftRef.value });
+ });
+ onDeactivated(() => {
+ isDeactivated = true;
+ if (!activateStateInitialized) {
+ activateStateInitialized = true;
+ }
+ });
+ const totalWidthRef = useMemo(() => {
+ if (props.renderCol == null && props.renderItemWithCols == null) {
+ return void 0;
+ }
+ if (props.columns.length === 0)
+ return void 0;
+ let width = 0;
+ props.columns.forEach((column) => {
+ width += column.width;
+ });
+ return width;
+ });
+ const keyIndexMapRef = computed(() => {
+ const map = /* @__PURE__ */ new Map();
+ const { keyField } = props;
+ props.items.forEach((item, index) => {
+ map.set(item[keyField], index);
+ });
+ return map;
+ });
+ const { scrollLeftRef, listWidthRef } = setupXScroll({
+ columnsRef: toRef(props, "columns"),
+ renderColRef: toRef(props, "renderCol"),
+ renderItemWithColsRef: toRef(props, "renderItemWithCols")
+ });
+ const listElRef = ref(null);
+ const listHeightRef = ref(void 0);
+ const keyToHeightOffset = /* @__PURE__ */ new Map();
+ const finweckTreeRef = computed(() => {
+ const { items, itemSize, keyField } = props;
+ const ft = new FinweckTree(items.length, itemSize);
+ items.forEach((item, index) => {
+ const key = item[keyField];
+ const heightOffset = keyToHeightOffset.get(key);
+ if (heightOffset !== void 0) {
+ ft.add(index, heightOffset);
+ }
+ });
+ return ft;
+ });
+ const finweckTreeUpdateTrigger = ref(0);
+ const scrollTopRef = ref(0);
+ const startIndexRef = useMemo(() => {
+ return Math.max(finweckTreeRef.value.getBound(scrollTopRef.value - depx(props.paddingTop)) - 1, 0);
+ });
+ const viewportItemsRef = computed(() => {
+ const { value: listHeight } = listHeightRef;
+ if (listHeight === void 0)
+ return [];
+ const { items, itemSize } = props;
+ const startIndex = startIndexRef.value;
+ const endIndex = Math.min(startIndex + Math.ceil(listHeight / itemSize + 1), items.length - 1);
+ const viewportItems = [];
+ for (let i = startIndex; i <= endIndex; ++i) {
+ viewportItems.push(items[i]);
+ }
+ return viewportItems;
+ });
+ const scrollTo = (options, y) => {
+ if (typeof options === "number") {
+ scrollToPosition(options, y, "auto");
+ return;
+ }
+ const { left, top, index, key, position, behavior, debounce = true } = options;
+ if (left !== void 0 || top !== void 0) {
+ scrollToPosition(left, top, behavior);
+ } else if (index !== void 0) {
+ scrollToIndex(index, behavior, debounce);
+ } else if (key !== void 0) {
+ const toIndex = keyIndexMapRef.value.get(key);
+ if (toIndex !== void 0)
+ scrollToIndex(toIndex, behavior, debounce);
+ } else if (position === "bottom") {
+ scrollToPosition(0, Number.MAX_SAFE_INTEGER, behavior);
+ } else if (position === "top") {
+ scrollToPosition(0, 0, behavior);
+ }
+ };
+ let anchorIndex;
+ let anchorTimerId = null;
+ function scrollToIndex(index, behavior, debounce) {
+ const { value: ft } = finweckTreeRef;
+ const targetTop = ft.sum(index) + depx(props.paddingTop);
+ if (!debounce) {
+ listElRef.value.scrollTo({
+ left: 0,
+ top: targetTop,
+ behavior
+ });
+ } else {
+ anchorIndex = index;
+ if (anchorTimerId !== null) {
+ window.clearTimeout(anchorTimerId);
+ }
+ anchorTimerId = window.setTimeout(() => {
+ anchorIndex = void 0;
+ anchorTimerId = null;
+ }, 16);
+ const { scrollTop, offsetHeight } = listElRef.value;
+ if (targetTop > scrollTop) {
+ const itemSize = ft.get(index);
+ if (targetTop + itemSize <= scrollTop + offsetHeight) ;
+ else {
+ listElRef.value.scrollTo({
+ left: 0,
+ top: targetTop + itemSize - offsetHeight,
+ behavior
+ });
+ }
+ } else {
+ listElRef.value.scrollTo({
+ left: 0,
+ top: targetTop,
+ behavior
+ });
+ }
+ }
+ }
+ function scrollToPosition(left, top, behavior) {
+ listElRef.value.scrollTo({
+ left,
+ top,
+ behavior
+ });
+ }
+ function handleItemResize(key, entry) {
+ var _a, _b, _c;
+ if (isDeactivated)
+ return;
+ if (props.ignoreItemResize)
+ return;
+ if (isHideByVShow(entry.target))
+ return;
+ const { value: ft } = finweckTreeRef;
+ const index = keyIndexMapRef.value.get(key);
+ const previousHeight = ft.get(index);
+ const height = (_c = (_b = (_a = entry.borderBoxSize) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.blockSize) !== null && _c !== void 0 ? _c : entry.contentRect.height;
+ if (height === previousHeight)
+ return;
+ const offset = height - props.itemSize;
+ if (offset === 0) {
+ keyToHeightOffset.delete(key);
+ } else {
+ keyToHeightOffset.set(key, height - props.itemSize);
+ }
+ const delta = height - previousHeight;
+ if (delta === 0)
+ return;
+ ft.add(index, delta);
+ const listEl = listElRef.value;
+ if (listEl != null) {
+ if (anchorIndex === void 0) {
+ const previousHeightSum = ft.sum(index);
+ if (listEl.scrollTop > previousHeightSum) {
+ listEl.scrollBy(0, delta);
+ }
+ } else {
+ if (index < anchorIndex) {
+ listEl.scrollBy(0, delta);
+ } else if (index === anchorIndex) {
+ const previousHeightSum = ft.sum(index);
+ if (height + previousHeightSum > // Note, listEl shouldn't have border, nor offsetHeight won't be
+ // correct
+ listEl.scrollTop + listEl.offsetHeight) {
+ listEl.scrollBy(0, delta);
+ }
+ }
+ }
+ syncViewport();
+ }
+ finweckTreeUpdateTrigger.value++;
+ }
+ const mayUseWheel = !ensureMaybeTouch();
+ let wheelCatched = false;
+ function handleListScroll(e) {
+ var _a;
+ (_a = props.onScroll) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ if (!mayUseWheel || !wheelCatched) {
+ syncViewport();
+ }
+ }
+ function handleListWheel(e) {
+ var _a;
+ (_a = props.onWheel) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ if (mayUseWheel) {
+ const listEl = listElRef.value;
+ if (listEl != null) {
+ if (e.deltaX === 0) {
+ if (listEl.scrollTop === 0 && e.deltaY <= 0) {
+ return;
+ }
+ if (listEl.scrollTop + listEl.offsetHeight >= listEl.scrollHeight && e.deltaY >= 0) {
+ return;
+ }
+ }
+ e.preventDefault();
+ listEl.scrollTop += e.deltaY / ensureWheelScale();
+ listEl.scrollLeft += e.deltaX / ensureWheelScale();
+ syncViewport();
+ wheelCatched = true;
+ beforeNextFrameOnce(() => {
+ wheelCatched = false;
+ });
+ }
+ }
+ }
+ function handleListResize(entry) {
+ if (isDeactivated)
+ return;
+ if (isHideByVShow(entry.target))
+ return;
+ if (props.renderCol == null && props.renderItemWithCols == null) {
+ if (entry.contentRect.height === listHeightRef.value)
+ return;
+ } else {
+ if (entry.contentRect.height === listHeightRef.value && entry.contentRect.width === listWidthRef.value) {
+ return;
+ }
+ }
+ listHeightRef.value = entry.contentRect.height;
+ listWidthRef.value = entry.contentRect.width;
+ const { onResize } = props;
+ if (onResize !== void 0)
+ onResize(entry);
+ }
+ function syncViewport() {
+ const { value: listEl } = listElRef;
+ if (listEl == null)
+ return;
+ scrollTopRef.value = listEl.scrollTop;
+ scrollLeftRef.value = listEl.scrollLeft;
+ }
+ function isHideByVShow(el) {
+ let cursor = el;
+ while (cursor !== null) {
+ if (cursor.style.display === "none")
+ return true;
+ cursor = cursor.parentElement;
+ }
+ return false;
+ }
+ return {
+ listHeight: listHeightRef,
+ listStyle: {
+ overflow: "auto"
+ },
+ keyToIndex: keyIndexMapRef,
+ itemsStyle: computed(() => {
+ const { itemResizable } = props;
+ const height = pxfy(finweckTreeRef.value.sum());
+ finweckTreeUpdateTrigger.value;
+ return [
+ props.itemsStyle,
+ {
+ boxSizing: "content-box",
+ width: pxfy(totalWidthRef.value),
+ height: itemResizable ? "" : height,
+ minHeight: itemResizable ? height : "",
+ paddingTop: pxfy(props.paddingTop),
+ paddingBottom: pxfy(props.paddingBottom)
+ }
+ ];
+ }),
+ visibleItemsStyle: computed(() => {
+ finweckTreeUpdateTrigger.value;
+ return {
+ transform: `translateY(${pxfy(finweckTreeRef.value.sum(startIndexRef.value))})`
+ };
+ }),
+ viewportItems: viewportItemsRef,
+ listElRef,
+ itemsElRef: ref(null),
+ scrollTo,
+ handleListResize,
+ handleListScroll,
+ handleListWheel,
+ handleItemResize
+ };
+ },
+ render() {
+ const { itemResizable, keyField, keyToIndex, visibleItemsTag } = this;
+ return h(VResizeObserver, {
+ onResize: this.handleListResize
+ }, {
+ default: () => {
+ var _a, _b;
+ return h("div", mergeProps(this.$attrs, {
+ class: ["v-vl", this.showScrollbar && "v-vl--show-scrollbar"],
+ onScroll: this.handleListScroll,
+ onWheel: this.handleListWheel,
+ ref: "listElRef"
+ }), [
+ this.items.length !== 0 ? h("div", {
+ ref: "itemsElRef",
+ class: "v-vl-items",
+ style: this.itemsStyle
+ }, [
+ h(visibleItemsTag, Object.assign({
+ class: "v-vl-visible-items",
+ style: this.visibleItemsStyle
+ }, this.visibleItemsProps), {
+ default: () => {
+ const { renderCol, renderItemWithCols } = this;
+ return this.viewportItems.map((item) => {
+ const key = item[keyField];
+ const index = keyToIndex.get(key);
+ const renderedCols = renderCol != null ? h(VirtualListRow, {
+ index,
+ item
+ }) : void 0;
+ const renderedItemWithCols = renderItemWithCols != null ? h(VirtualListRow, {
+ index,
+ item
+ }) : void 0;
+ const itemVNode = this.$slots.default({
+ item,
+ renderedCols,
+ renderedItemWithCols,
+ index
+ })[0];
+ if (itemResizable) {
+ return h(VResizeObserver, {
+ key,
+ onResize: (entry) => this.handleItemResize(key, entry)
+ }, {
+ default: () => itemVNode
+ });
+ }
+ itemVNode.key = key;
+ return itemVNode;
+ });
+ }
+ })
+ ]) : (_b = (_a = this.$slots).empty) === null || _b === void 0 ? void 0 : _b.call(_a)
+ ]);
+ }
+ });
+ }
+});
+const virtualListProps = {
+ scrollbarProps: Object,
+ items: {
+ type: Array,
+ default: () => []
+ },
+ itemSize: {
+ type: Number,
+ required: true
+ },
+ itemResizable: Boolean,
+ itemsStyle: [String, Object],
+ visibleItemsTag: {
+ type: [String, Object],
+ default: "div"
+ },
+ visibleItemsProps: Object,
+ ignoreItemResize: Boolean,
+ onScroll: Function,
+ onWheel: Function,
+ onResize: Function,
+ defaultScrollKey: [Number, String],
+ defaultScrollIndex: Number,
+ keyField: {
+ type: String,
+ default: "key"
+ },
+ paddingTop: {
+ type: [Number, String],
+ default: 0
+ },
+ paddingBottom: {
+ type: [Number, String],
+ default: 0
+ }
+};
+const __unplugin_components_4 = defineComponent({
+ name: "VirtualList",
+ props: virtualListProps,
+ setup(props) {
+ const scrollbarInstRef = ref(null);
+ const virtualListInstRef = ref(null);
+ function syncScrollbar() {
+ const {
+ value: scrollbarInst
+ } = scrollbarInstRef;
+ if (scrollbarInst) scrollbarInst.sync();
+ }
+ function handleScroll(e) {
+ var _a;
+ syncScrollbar();
+ (_a = props.onScroll) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ }
+ function handleResize(e) {
+ var _a;
+ syncScrollbar();
+ (_a = props.onResize) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ }
+ function handleWheel(e) {
+ var _a;
+ (_a = props.onWheel) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ }
+ function scrollTo(options, y) {
+ var _a, _b;
+ if (typeof options === "number") {
+ (_a = virtualListInstRef.value) === null || _a === void 0 ? void 0 : _a.scrollTo(options, y !== null && y !== void 0 ? y : 0);
+ } else {
+ (_b = virtualListInstRef.value) === null || _b === void 0 ? void 0 : _b.scrollTo(options);
+ }
+ }
+ function getScrollContainer() {
+ var _a;
+ return (_a = virtualListInstRef.value) === null || _a === void 0 ? void 0 : _a.listElRef;
+ }
+ function getScrollContent() {
+ var _a;
+ return (_a = virtualListInstRef.value) === null || _a === void 0 ? void 0 : _a.itemsElRef;
+ }
+ return {
+ scrollTo,
+ scrollbarInstRef,
+ virtualListInstRef,
+ getScrollContainer,
+ getScrollContent,
+ handleScroll,
+ handleResize,
+ handleWheel
+ };
+ },
+ render() {
+ return h(XScrollbar, Object.assign({}, this.scrollbarProps, {
+ ref: "scrollbarInstRef",
+ container: this.getScrollContainer,
+ content: this.getScrollContent
+ }), {
+ default: () => {
+ return h(VVirtualList, {
+ ref: "virtualListInstRef",
+ showScrollbar: false,
+ items: this.items,
+ itemSize: this.itemSize,
+ itemResizable: this.itemResizable,
+ itemsStyle: this.itemsStyle,
+ visibleItemsTag: this.visibleItemsTag,
+ visibleItemsProps: this.visibleItemsProps,
+ ignoreItemResize: this.ignoreItemResize,
+ keyField: this.keyField,
+ defaultScrollKey: this.defaultScrollKey,
+ defaultScrollIndex: this.defaultScrollIndex,
+ paddingTop: this.paddingTop,
+ paddingBottom: this.paddingBottom,
+ onScroll: this.handleScroll,
+ onResize: this.handleResize,
+ onWheel: this.handleWheel
+ }, {
+ default: ({
+ item,
+ index
+ }) => {
+ var _a, _b;
+ return (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a, {
+ item,
+ index
+ });
+ }
+ });
+ }
+ });
+ }
+});
+const windowData = window;
+const lrcArray = ref([]);
+const lrcTimeArray = ref([]);
+const nowTime = ref(0);
+const allTime = ref(0);
+const nowIndex = ref(0);
+const correctionTime = ref(0.4);
+const currentLrcProgress = ref(0);
+const playMusic = computed(() => store.state.playMusic);
+const sound = ref(audioService.getCurrentSound());
+const isLyricWindowOpen = ref(false);
+const textColors = ref(getTextColors());
+document.onkeyup = (e) => {
+ const target = e.target;
+ if (target.tagName === "INPUT" || target.tagName === "TEXTAREA") {
+ return;
+ }
+ switch (e.code) {
+ case "Space":
+ if (store.state.play) {
+ store.commit("setPlayMusic", false);
+ audioService.getCurrentSound()?.pause();
+ } else {
+ store.commit("setPlayMusic", true);
+ audioService.getCurrentSound()?.play();
+ }
+ break;
+ }
+};
+watch(
+ () => store.state.playMusicUrl,
+ (newVal) => {
+ if (newVal) {
+ audioService.play(newVal);
+ sound.value = audioService.getCurrentSound();
+ audioServiceOn(audioService);
+ }
+ }
+);
+watch(
+ () => store.state.playMusic,
+ () => {
+ nextTick(async () => {
+ lrcArray.value = playMusic.value.lyric?.lrcArray || [];
+ lrcTimeArray.value = playMusic.value.lyric?.lrcTimeArray || [];
+ if (isElectron && isLyricWindowOpen.value && lrcArray.value.length > 0) {
+ sendLyricToWin();
+ }
+ });
+ },
+ {
+ deep: true,
+ immediate: true
+ }
+);
+const audioServiceOn = (audio) => {
+ let interval = null;
+ audio.onPlay(() => {
+ store.commit("setPlayMusic", true);
+ interval = setInterval(() => {
+ nowTime.value = sound.value?.seek();
+ allTime.value = sound.value?.duration();
+ const newIndex = getLrcIndex(nowTime.value);
+ if (newIndex !== nowIndex.value) {
+ nowIndex.value = newIndex;
+ currentLrcProgress.value = 0;
+ if (isElectron && isLyricWindowOpen.value) {
+ sendLyricToWin();
+ }
+ }
+ if (isElectron && isLyricWindowOpen.value) {
+ sendLyricToWin();
+ }
+ }, 50);
+ });
+ audio.onPause(() => {
+ store.commit("setPlayMusic", false);
+ clearInterval(interval);
+ if (isElectron && isLyricWindowOpen.value) {
+ sendLyricToWin();
+ }
+ });
+ audio.onEnd(() => {
+ if (store.state.playMode === 1) {
+ audio.getCurrentSound()?.play();
+ } else if (store.state.playMode === 2) {
+ const { playList } = store.state;
+ if (playList.length <= 1) {
+ audio.getCurrentSound()?.play();
+ } else {
+ let randomIndex;
+ do {
+ randomIndex = Math.floor(Math.random() * playList.length);
+ } while (randomIndex === store.state.playListIndex && playList.length > 1);
+ store.state.playListIndex = randomIndex;
+ store.commit("setPlay", playList[randomIndex]);
+ }
+ } else {
+ store.commit("nextPlay");
+ }
+ });
+};
+const isPlaying = computed(() => store.state.play);
+const isCurrentLrc = (index, time) => {
+ const currentTime = lrcTimeArray.value[index];
+ const nextTime = lrcTimeArray.value[index + 1];
+ const nowTime2 = time + correctionTime.value;
+ const isTrue = nowTime2 > currentTime && nowTime2 < nextTime;
+ return isTrue;
+};
+const getLrcIndex = (time) => {
+ for (let i = 0; i < lrcTimeArray.value.length; i++) {
+ if (isCurrentLrc(i, time)) {
+ nowIndex.value = i;
+ return i;
+ }
+ }
+ return nowIndex.value;
+};
+const currentLrcTiming = computed(() => {
+ const start = lrcTimeArray.value[nowIndex.value] || 0;
+ const end = lrcTimeArray.value[nowIndex.value + 1] || start + 1;
+ return { start, end };
+});
+const getLrcStyle = (index) => {
+ if (index === nowIndex.value) {
+ return {
+ backgroundImage: `linear-gradient(to right, #ffffff ${currentLrcProgress.value}%, #ffffff8a ${currentLrcProgress.value}%)`,
+ backgroundClip: "text",
+ WebkitBackgroundClip: "text",
+ color: "transparent",
+ transition: "background-image 0.1s linear"
+ };
+ }
+ return {};
+};
+const useLyricProgress = () => {
+ let animationFrameId = null;
+ const updateProgress = () => {
+ if (!isPlaying.value) return;
+ const currentSound = sound.value;
+ if (!currentSound) return;
+ const { start, end } = currentLrcTiming.value;
+ const duration = end - start;
+ const elapsed = currentSound.seek() - start;
+ currentLrcProgress.value = Math.min(Math.max(elapsed / duration * 100, 0), 100);
+ animationFrameId = requestAnimationFrame(updateProgress);
+ };
+ const startProgressAnimation = () => {
+ if (!animationFrameId && isPlaying.value) {
+ updateProgress();
+ }
+ };
+ const stopProgressAnimation = () => {
+ if (animationFrameId) {
+ cancelAnimationFrame(animationFrameId);
+ animationFrameId = null;
+ }
+ };
+ watch(isPlaying, (newIsPlaying) => {
+ if (newIsPlaying) {
+ startProgressAnimation();
+ } else {
+ stopProgressAnimation();
+ }
+ });
+ onMounted(() => {
+ if (isPlaying.value) {
+ startProgressAnimation();
+ }
+ });
+ onUnmounted(() => {
+ stopProgressAnimation();
+ });
+ return {
+ currentLrcProgress,
+ getLrcStyle
+ };
+};
+const setAudioTime = (index) => {
+ const currentSound = sound.value;
+ if (!currentSound) return;
+ currentSound.seek(lrcTimeArray.value[index]);
+ currentSound.play();
+};
+watch(
+ () => lrcArray.value,
+ (newLrcArray) => {
+ if (newLrcArray.length > 0 && isElectron && isLyricWindowOpen.value) {
+ sendLyricToWin();
+ }
+ }
+);
+const sendLyricToWin = () => {
+ if (!isElectron || !isLyricWindowOpen.value) {
+ console.log("Cannot send lyric: electron or lyric window not available");
+ return;
+ }
+ try {
+ if (lrcArray.value.length > 0) {
+ const nowIndex2 = getLrcIndex(nowTime.value);
+ const updateData = {
+ type: "full",
+ nowIndex: nowIndex2,
+ nowTime: nowTime.value,
+ startCurrentTime: lrcTimeArray.value[nowIndex2],
+ nextTime: lrcTimeArray.value[nowIndex2 + 1],
+ isPlay: isPlaying.value,
+ lrcArray: lrcArray.value,
+ lrcTimeArray: lrcTimeArray.value,
+ allTime: allTime.value,
+ playMusic: playMusic.value
+ };
+ window.api.sendLyric(JSON.stringify(updateData));
+ }
+ } catch (error) {
+ console.error("Error sending lyric update:", error);
+ }
+};
+const openLyric = () => {
+ if (!isElectron) return;
+ console.log("Opening lyric window with current song:", playMusic.value?.name);
+ isLyricWindowOpen.value = !isLyricWindowOpen.value;
+ if (isLyricWindowOpen.value) {
+ setTimeout(() => {
+ window.api.openLyric();
+ sendLyricToWin();
+ }, 500);
+ sendLyricToWin();
+ } else {
+ closeLyric();
+ }
+};
+const closeLyric = () => {
+ if (!isElectron) return;
+ windowData.electron.ipcRenderer.send("close-lyric");
+};
+if (isElectron) {
+ windowData.electron.ipcRenderer.on("lyric-control-back", (_, command) => {
+ switch (command) {
+ case "playpause":
+ if (store.state.play) {
+ store.commit("setPlayMusic", false);
+ audioService.getCurrentSound()?.pause();
+ } else {
+ store.commit("setPlayMusic", true);
+ audioService.getCurrentSound()?.play();
+ }
+ break;
+ case "prev":
+ store.commit("prevPlay");
+ break;
+ case "next":
+ store.commit("nextPlay");
+ break;
+ case "close":
+ closeLyric();
+ break;
+ default:
+ console.log("Unknown command:", command);
+ break;
+ }
+ });
+}
+const _hoisted_1$1 = { id: "drawer-target" };
+const _hoisted_2$1 = { class: "music-content-name" };
+const _hoisted_3$1 = { class: "music-content-singer" };
+const _hoisted_4$1 = { class: "music-content" };
+const _hoisted_5$1 = ["id", "onClick"];
+const _hoisted_6$1 = { class: "music-lrc-text-tr" };
+const _hoisted_7$1 = {
+ key: 0,
+ class: "music-lrc-text mt-40"
+};
+const _sfc_main$1 = /* @__PURE__ */ defineComponent({
+ __name: "MusicFull",
+ props: {
+ musicFull: {
+ type: Boolean,
+ default: false
+ },
+ background: {
+ type: String,
+ default: ""
+ }
+ },
+ setup(__props, { expose: __expose }) {
+ const lrcSider = ref(null);
+ const isMouse = ref(false);
+ const lrcContainer = ref(null);
+ const currentBackground = ref("");
+ const animationFrame = ref(null);
+ const isDark = ref(false);
+ const props = __props;
+ const lrcScroll = (behavior = "smooth") => {
+ const nowEl = document.querySelector(`#music-lrc-text-${nowIndex.value}`);
+ if (props.musicFull && !isMouse.value && nowEl && lrcContainer.value) {
+ const containerRect = lrcContainer.value.getBoundingClientRect();
+ const nowElRect = nowEl.getBoundingClientRect();
+ const relativeTop = nowElRect.top - containerRect.top;
+ const scrollTop = relativeTop - lrcSider.value.$el.getBoundingClientRect().height / 2;
+ lrcSider.value.scrollTo({ top: scrollTop, behavior });
+ }
+ };
+ const debouncedLrcScroll = useDebounceFn(lrcScroll, 200);
+ const mouseOverLayout = () => {
+ isMouse.value = true;
+ };
+ const mouseLeaveLayout = () => {
+ setTimeout(() => {
+ isMouse.value = false;
+ lrcScroll();
+ }, 2e3);
+ };
+ watch(nowIndex, () => {
+ debouncedLrcScroll();
+ });
+ watch(
+ () => props.musicFull,
+ () => {
+ if (props.musicFull) {
+ nextTick(() => {
+ lrcScroll("instant");
+ });
+ }
+ }
+ );
+ watch(
+ () => props.background,
+ (newBg) => {
+ if (!newBg) {
+ textColors.value = getTextColors();
+ document.documentElement.style.setProperty(
+ "--hover-bg-color",
+ getHoverBackgroundColor(false)
+ );
+ document.documentElement.style.setProperty("--text-color-primary", textColors.value.primary);
+ document.documentElement.style.setProperty("--text-color-active", textColors.value.active);
+ return;
+ }
+ if (currentBackground.value) {
+ if (animationFrame.value) {
+ cancelAnimationFrame(animationFrame.value);
+ }
+ animationFrame.value = animateGradient(currentBackground.value, newBg, (gradient) => {
+ currentBackground.value = gradient;
+ });
+ } else {
+ currentBackground.value = newBg;
+ }
+ textColors.value = getTextColors(newBg);
+ isDark.value = textColors.value.active === "#000000";
+ document.documentElement.style.setProperty(
+ "--hover-bg-color",
+ getHoverBackgroundColor(isDark.value)
+ );
+ document.documentElement.style.setProperty("--text-color-primary", textColors.value.primary);
+ document.documentElement.style.setProperty("--text-color-active", textColors.value.active);
+ },
+ { immediate: true }
+ );
+ const { getLrcStyle: originalLrcStyle } = useLyricProgress();
+ const getLrcStyle2 = (index) => {
+ const colors = textColors.value || getTextColors;
+ const originalStyle = originalLrcStyle(index);
+ if (index === nowIndex.value) {
+ return {
+ ...originalStyle,
+ backgroundImage: originalStyle.backgroundImage?.replace(/#ffffff/g, colors.active).replace(/#ffffff8a/g, `${colors.primary}`),
+ backgroundClip: "text",
+ WebkitBackgroundClip: "text",
+ color: "transparent"
+ };
+ }
+ return {
+ color: colors.primary
+ };
+ };
+ onBeforeUnmount(() => {
+ if (animationFrame.value) {
+ cancelAnimationFrame(animationFrame.value);
+ }
+ });
+ __expose({
+ lrcScroll
+ });
+ return (_ctx, _cache) => {
+ const _component_n_image = NImage;
+ const _component_n_layout = __unplugin_components_1;
+ const _component_n_drawer = __unplugin_components_2;
+ return openBlock(), createBlock(_component_n_drawer, {
+ show: __props.musicFull,
+ height: "100%",
+ placement: "bottom",
+ style: normalizeStyle({ background: currentBackground.value || __props.background }),
+ to: `#layout-main`
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1$1, [
+ _cache[1] || (_cache[1] = createBaseVNode("div", { class: "drawer-back" }, null, -1)),
+ createBaseVNode("div", {
+ class: "music-img",
+ style: normalizeStyle({ color: unref(textColors).theme === "dark" ? "#000000" : "#ffffff" })
+ }, [
+ createVNode(_component_n_image, {
+ ref: "PicImgRef",
+ src: unref(getImgUrl)(unref(playMusic)?.picUrl, "500y500"),
+ class: "img",
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", null, [
+ createBaseVNode("div", _hoisted_2$1, toDisplayString(unref(playMusic).name), 1),
+ createBaseVNode("div", _hoisted_3$1, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(playMusic).ar || unref(playMusic).song.artists, (item, index) => {
+ return openBlock(), createElementBlock("span", { key: index }, toDisplayString(item.name) + toDisplayString(index < (unref(playMusic).ar || unref(playMusic).song.artists).length - 1 ? " / " : ""), 1);
+ }), 128))
+ ])
+ ])
+ ], 4),
+ createBaseVNode("div", _hoisted_4$1, [
+ createVNode(_component_n_layout, {
+ ref_key: "lrcSider",
+ ref: lrcSider,
+ class: "music-lrc",
+ style: { "height": "60vh" },
+ "native-scrollbar": false,
+ onMouseover: mouseOverLayout,
+ onMouseleave: mouseLeaveLayout
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", {
+ ref_key: "lrcContainer",
+ ref: lrcContainer
+ }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(lrcArray), (item, index) => {
+ return openBlock(), createElementBlock("div", {
+ id: `music-lrc-text-${index}`,
+ key: index,
+ class: normalizeClass(["music-lrc-text", { "now-text": index === unref(nowIndex), "hover-text": item.text }]),
+ onClick: ($event) => unref(setAudioTime)(index)
+ }, [
+ createBaseVNode("span", {
+ style: normalizeStyle(getLrcStyle2(index))
+ }, toDisplayString(item.text), 5),
+ createBaseVNode("div", _hoisted_6$1, toDisplayString(item.trText), 1)
+ ], 10, _hoisted_5$1);
+ }), 128)),
+ !unref(lrcArray).length ? (openBlock(), createElementBlock("div", _hoisted_7$1, _cache[0] || (_cache[0] = [
+ createBaseVNode("span", null, "暂无歌词, 请欣赏", -1)
+ ]))) : createCommentVNode("", true)
+ ], 512)
+ ]),
+ _: 1
+ }, 512)
+ ])
+ ])
+ ]),
+ _: 1
+ }, 8, ["show", "style"]);
+ };
+ }
+});
+const MusicFull = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-03432cea"]]);
+const _hoisted_1 = { class: "music-time custom-slider" };
+const _hoisted_2 = { class: "hover-arrow" };
+const _hoisted_3 = { class: "hover-content" };
+const _hoisted_4 = { class: "hover-text" };
+const _hoisted_5 = { class: "music-content" };
+const _hoisted_6 = { class: "music-content-title" };
+const _hoisted_7 = { class: "music-content-name" };
+const _hoisted_8 = { class: "music-buttons" };
+const _hoisted_9 = { class: "audio-button" };
+const _hoisted_10 = { class: "audio-volume custom-slider" };
+const _hoisted_11 = { class: "volume-slider" };
+const _hoisted_12 = { class: "music-play-list" };
+const _hoisted_13 = { class: "music-play-list-content" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "PlayBar",
+ setup(__props) {
+ const store2 = useStore();
+ const playMusic2 = computed(() => store2.state.playMusic);
+ const play = computed(() => store2.state.play);
+ const playList = computed(() => store2.state.playList);
+ const background = ref("#000");
+ watch(
+ () => store2.state.playMusic,
+ async () => {
+ background.value = playMusic2.value.backgroundColor;
+ },
+ { immediate: true, deep: true }
+ );
+ const throttledSeek = useThrottleFn((value) => {
+ if (!sound.value) return;
+ sound.value.seek(value);
+ nowTime.value = value;
+ }, 50);
+ const timeSlider = computed({
+ get: () => nowTime.value,
+ set: throttledSeek
+ });
+ const formatTooltip = (value) => {
+ return `${secondToMinute(value)} / ${secondToMinute(allTime.value)}`;
+ };
+ const audioVolume = ref(
+ localStorage.getItem("volume") ? parseFloat(localStorage.getItem("volume")) : 1
+ );
+ const getVolumeIcon = computed(() => {
+ if (audioVolume.value === 0) {
+ return "ri-volume-mute-line";
+ }
+ if (audioVolume.value <= 0.5) {
+ return "ri-volume-down-line";
+ }
+ return "ri-volume-up-line";
+ });
+ const volumeSlider = computed({
+ get: () => audioVolume.value * 100,
+ set: (value) => {
+ if (!sound.value) return;
+ localStorage.setItem("volume", (value / 100).toString());
+ sound.value.volume(value / 100);
+ audioVolume.value = value / 100;
+ }
+ });
+ const mute = () => {
+ if (volumeSlider.value === 0) {
+ volumeSlider.value = 30;
+ } else {
+ volumeSlider.value = 0;
+ }
+ };
+ const playMode = computed(() => store2.state.playMode);
+ const playModeIcon = computed(() => {
+ switch (playMode.value) {
+ case 0:
+ return "ri-repeat-2-line";
+ case 1:
+ return "ri-repeat-one-line";
+ case 2:
+ return "ri-shuffle-line";
+ default:
+ return "ri-repeat-2-line";
+ }
+ });
+ const playModeText = computed(() => {
+ switch (playMode.value) {
+ case 0:
+ return "列表循环";
+ case 1:
+ return "单曲循环";
+ case 2:
+ return "随机播放";
+ default:
+ return "列表循环";
+ }
+ });
+ const togglePlayMode = () => {
+ store2.commit("togglePlayMode");
+ };
+ function handleNext() {
+ store2.commit("nextPlay");
+ }
+ function handlePrev() {
+ store2.commit("prevPlay");
+ }
+ const MusicFullRef = ref(null);
+ const playMusicEvent = async () => {
+ if (play.value) {
+ if (sound.value) {
+ sound.value.pause();
+ }
+ store2.commit("setPlayMusic", false);
+ } else {
+ if (sound.value) {
+ sound.value.play();
+ }
+ store2.commit("setPlayMusic", true);
+ }
+ };
+ const musicFullVisible = ref(false);
+ const setMusicFull = () => {
+ musicFullVisible.value = !musicFullVisible.value;
+ };
+ const palyListRef = useTemplateRef("palyListRef");
+ const scrollToPlayList = (val) => {
+ if (!val) return;
+ setTimeout(() => {
+ palyListRef.value?.scrollTo({ top: store2.state.playListIndex * 62 });
+ }, 50);
+ };
+ const isFavorite = computed(() => {
+ return store2.state.favoriteList.includes(playMusic2.value.id);
+ });
+ const toggleFavorite = async (e) => {
+ e.stopPropagation();
+ if (isFavorite.value) {
+ store2.commit("removeFromFavorite", playMusic2.value.id);
+ } else {
+ store2.commit("addToFavorite", playMusic2.value.id);
+ }
+ };
+ const openLyricWindow = () => {
+ openLyric();
+ };
+ return (_ctx, _cache) => {
+ const _component_n_slider = __unplugin_components_0;
+ const _component_n_image = NImage;
+ const _component_n_ellipsis = __unplugin_components_2$1;
+ const _component_n_tooltip = __unplugin_components_3;
+ const _component_n_virtual_list = __unplugin_components_4;
+ const _component_n_popover = __unplugin_components_5;
+ return openBlock(), createElementBlock(Fragment, null, [
+ createVNode(MusicFull, {
+ ref_key: "MusicFullRef",
+ ref: MusicFullRef,
+ "music-full": unref(musicFullVisible),
+ "onUpdate:musicFull": _cache[0] || (_cache[0] = ($event) => isRef(musicFullVisible) ? musicFullVisible.value = $event : null),
+ background: unref(background)
+ }, null, 8, ["music-full", "background"]),
+ createBaseVNode("div", {
+ class: normalizeClass([
+ "music-play-bar",
+ unref(setAnimationClass)("animate__bounceInUp") + " " + (unref(musicFullVisible) ? "play-bar-opcity" : "")
+ ]),
+ style: normalizeStyle({
+ color: unref(musicFullVisible) ? unref(textColors).theme === "dark" ? "#000000" : "#ffffff" : unref(store2).state.theme === "dark" ? "#ffffff" : "#000000"
+ })
+ }, [
+ createBaseVNode("div", _hoisted_1, [
+ createVNode(_component_n_slider, {
+ value: unref(timeSlider),
+ "onUpdate:value": _cache[1] || (_cache[1] = ($event) => isRef(timeSlider) ? timeSlider.value = $event : null),
+ step: 1,
+ max: unref(allTime),
+ min: 0,
+ "format-tooltip": formatTooltip
+ }, null, 8, ["value", "max"])
+ ]),
+ createBaseVNode("div", {
+ class: "play-bar-img-wrapper",
+ onClick: setMusicFull
+ }, [
+ createVNode(_component_n_image, {
+ src: unref(getImgUrl)(unref(playMusic2)?.picUrl, "500y500"),
+ class: "play-bar-img",
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_2, [
+ createBaseVNode("div", _hoisted_3, [
+ createBaseVNode("i", {
+ class: normalizeClass(["text-3xl", unref(musicFullVisible) ? "ri-arrow-down-s-line" : "ri-arrow-up-s-line"])
+ }, null, 2),
+ createBaseVNode("span", _hoisted_4, toDisplayString(unref(musicFullVisible) ? "收起" : "展开") + "歌词", 1)
+ ])
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("div", _hoisted_6, [
+ createVNode(_component_n_ellipsis, {
+ class: "text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ createTextVNode(toDisplayString(unref(playMusic2).name), 1)
+ ]),
+ _: 1
+ })
+ ]),
+ createBaseVNode("div", _hoisted_7, [
+ createVNode(_component_n_ellipsis, {
+ class: "text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(playMusic2).ar || unref(playMusic2).song.artists, (artists, artistsindex) => {
+ return openBlock(), createElementBlock("span", { key: artistsindex }, toDisplayString(artists.name) + toDisplayString(artistsindex < (unref(playMusic2).ar || unref(playMusic2).song.artists).length - 1 ? " / " : ""), 1);
+ }), 128))
+ ]),
+ _: 1
+ })
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_8, [
+ createBaseVNode("div", {
+ class: "music-buttons-prev",
+ onClick: handlePrev
+ }, _cache[3] || (_cache[3] = [
+ createBaseVNode("i", { class: "iconfont icon-prev" }, null, -1)
+ ])),
+ createBaseVNode("div", {
+ class: "music-buttons-play",
+ onClick: playMusicEvent
+ }, [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont icon", unref(play) ? "icon-stop" : "icon-play"])
+ }, null, 2)
+ ]),
+ createBaseVNode("div", {
+ class: "music-buttons-next",
+ onClick: handleNext
+ }, _cache[4] || (_cache[4] = [
+ createBaseVNode("i", { class: "iconfont icon-next" }, null, -1)
+ ]))
+ ]),
+ createBaseVNode("div", _hoisted_9, [
+ createBaseVNode("div", _hoisted_10, [
+ createBaseVNode("div", {
+ class: "volume-icon",
+ onClick: mute
+ }, [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont", unref(getVolumeIcon)])
+ }, null, 2)
+ ]),
+ createBaseVNode("div", _hoisted_11, [
+ createVNode(_component_n_slider, {
+ value: unref(volumeSlider),
+ "onUpdate:value": _cache[2] || (_cache[2] = ($event) => isRef(volumeSlider) ? volumeSlider.value = $event : null),
+ step: 0.01,
+ tooltip: false,
+ vertical: ""
+ }, null, 8, ["value"])
+ ])
+ ]),
+ !unref(isMobile) ? (openBlock(), createBlock(_component_n_tooltip, {
+ key: 0,
+ trigger: "hover",
+ "z-index": 9999999
+ }, {
+ trigger: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont", unref(playModeIcon)]),
+ onClick: togglePlayMode
+ }, null, 2)
+ ]),
+ default: withCtx(() => [
+ createTextVNode(" " + toDisplayString(unref(playModeText)), 1)
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ !unref(isMobile) ? (openBlock(), createBlock(_component_n_tooltip, {
+ key: 1,
+ trigger: "hover",
+ "z-index": 9999999
+ }, {
+ trigger: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont icon-likefill", { "like-active": unref(isFavorite) }]),
+ onClick: toggleFavorite
+ }, null, 2)
+ ]),
+ default: withCtx(() => [
+ _cache[5] || (_cache[5] = createTextVNode(" 喜欢 "))
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ unref(isElectron) ? (openBlock(), createBlock(_component_n_tooltip, {
+ key: 2,
+ class: "music-lyric",
+ trigger: "hover",
+ "z-index": 9999999
+ }, {
+ trigger: withCtx(() => [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont ri-netease-cloud-music-line", { "text-green-500": unref(isLyricWindowOpen) }]),
+ onClick: openLyricWindow
+ }, null, 2)
+ ]),
+ default: withCtx(() => [
+ _cache[6] || (_cache[6] = createTextVNode(" 歌词 "))
+ ]),
+ _: 1
+ })) : createCommentVNode("", true),
+ createVNode(_component_n_popover, {
+ trigger: "click",
+ "z-index": 99999999,
+ "content-class": "music-play",
+ raw: "",
+ "show-arrow": false,
+ delay: 200,
+ "arrow-wrapper-style": " border-radius:1.5rem",
+ onUpdateShow: scrollToPlayList
+ }, {
+ trigger: withCtx(() => [
+ createVNode(_component_n_tooltip, {
+ trigger: "manual",
+ "z-index": 9999999
+ }, {
+ trigger: withCtx(() => _cache[7] || (_cache[7] = [
+ createBaseVNode("i", { class: "iconfont icon-list" }, null, -1)
+ ])),
+ default: withCtx(() => [
+ _cache[8] || (_cache[8] = createTextVNode(" 播放列表 "))
+ ]),
+ _: 1
+ })
+ ]),
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_12, [
+ _cache[9] || (_cache[9] = createBaseVNode("div", { class: "music-play-list-back" }, null, -1)),
+ createVNode(_component_n_virtual_list, {
+ ref_key: "palyListRef",
+ ref: palyListRef,
+ "item-size": 62,
+ "item-resizable": "",
+ items: unref(playList)
+ }, {
+ default: withCtx(({ item }) => [
+ createBaseVNode("div", _hoisted_13, [
+ (openBlock(), createBlock(SongItem, {
+ key: item.id,
+ item,
+ mini: ""
+ }, null, 8, ["item"]))
+ ])
+ ]),
+ _: 1
+ }, 8, ["items"])
+ ])
+ ]),
+ _: 1
+ })
+ ])
+ ], 6)
+ ], 64);
+ };
+ }
+});
+const PlayBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-5d6cadda"]]);
+export {
+ PlayBar as default
+};
diff --git a/out/renderer/assets/PlayBar-BNzUvTGp.js.gz b/out/renderer/assets/PlayBar-BNzUvTGp.js.gz
new file mode 100644
index 0000000..a4773f8
Binary files /dev/null and b/out/renderer/assets/PlayBar-BNzUvTGp.js.gz differ
diff --git a/out/renderer/assets/PlayBar-Ct36doNR.css b/out/renderer/assets/PlayBar-Ct36doNR.css
new file mode 100644
index 0000000..59acd4d
--- /dev/null
+++ b/out/renderer/assets/PlayBar-Ct36doNR.css
@@ -0,0 +1,502 @@
+@keyframes round-03432cea {
+0% {
+ transform: rotate(0deg);
+}
+100% {
+ transform: rotate(360deg);
+}
+}
+.drawer-back[data-v-03432cea] {
+ position: absolute;
+ background-size: cover;
+ background-position: center;
+ z-index: -1;
+ width: 200%;
+ height: 200%;
+ top: -50%;
+ left: -50%;
+}
+.drawer-back.paused[data-v-03432cea] {
+ animation-play-state: paused;
+}
+#drawer-target[data-v-03432cea] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ display: flex;
+ height: 100%;
+ width: 100%;
+ align-items: center;
+ justify-content: center;
+ overflow: hidden;
+ border-radius: 0.25rem;
+ padding-left: 6rem;
+ padding-right: 6rem;
+ padding-bottom: 2rem;
+ animation-duration: 300ms;
+}
+#drawer-target .music-img[data-v-03432cea] {
+ margin-right: 4rem;
+ display: flex;
+ flex: 1 1 0%;
+ flex-direction: column;
+ justify-content: center;
+ max-width: 360px;
+ max-height: 360px;
+}
+#drawer-target .music-img .img[data-v-03432cea] {
+ height: 100%;
+ width: 100%;
+ border-radius: 0.75rem;
+ --tw-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
+ --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);
+ box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
+}
+#drawer-target .music-content[data-v-03432cea] {
+ position: relative;
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+}
+#drawer-target .music-content-name[data-v-03432cea] {
+ padding-bottom: 0.25rem;
+ padding-top: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+}
+#drawer-target .music-content-singer[data-v-03432cea] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+}
+#drawer-target .music-content-time[data-v-03432cea] {
+ display: none;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+#drawer-target .music-lrc[data-v-03432cea] {
+ background-color: inherit;
+ width: 500px;
+ height: 550px;
+ -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
+ mask-image: linear-gradient(to bottom, transparent 0%, black 10%, black 90%, transparent 100%);
+}
+#drawer-target .music-lrc-text[data-v-03432cea] {
+ cursor: pointer;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ font-size: 1.5rem;
+ line-height: 2rem;
+ font-weight: 700;
+ transition: all 0.3s ease;
+ background-color: transparent;
+}
+#drawer-target .music-lrc-text span[data-v-03432cea] {
+ background-clip: text !important;
+ -webkit-background-clip: text !important;
+ padding-right: 30px;
+}
+#drawer-target .music-lrc-text-tr[data-v-03432cea] {
+ font-weight: 400;
+ opacity: 0.7;
+ color: var(--text-color-primary);
+}
+#drawer-target .music-lrc .hover-text[data-v-03432cea]:hover {
+ border-radius: 0.75rem;
+ font-weight: 700;
+ opacity: 1;
+ background-color: var(--hover-bg-color);
+}
+#drawer-target .music-lrc .hover-text:hover span[data-v-03432cea] {
+ color: var(--text-color-active) !important;
+}
+.mobile #drawer-target[data-v-03432cea] {
+ flex-direction: column;
+ justify-content: flex-start;
+ padding: 1rem;
+ padding-top: 2rem;
+}
+.mobile #drawer-target .music-img[data-v-03432cea] {
+ display: none;
+}
+.mobile #drawer-target .music-lrc[data-v-03432cea] {
+ height: calc(100vh - 260px) !important;
+ width: 100vw;
+}
+.mobile #drawer-target .music-lrc span[data-v-03432cea] {
+ padding-right: 0px !important;
+}
+.mobile #drawer-target .music-lrc-text[data-v-03432cea] {
+ text-align: center;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+}
+.music-drawer[data-v-03432cea] {
+ transition: none;
+}.text-ellipsis[data-v-5d6cadda] {
+ width: 100%;
+}
+.music-play-bar[data-v-5d6cadda] {
+ position: absolute;
+ bottom: 0px;
+ left: 0px;
+ box-sizing: border-box;
+ display: flex;
+ height: 5rem;
+ width: 100%;
+ align-items: center;
+ padding-left: 1.5rem;
+ padding-right: 1.5rem;
+ padding-bottom: 0.5rem;
+ padding-top: 0.75rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
+ --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);
+ box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
+ --tw-shadow-color: #d1d5db;
+ --tw-shadow: var(--tw-shadow-colored);
+}
+.music-play-bar[data-v-5d6cadda]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.music-play-bar[data-v-5d6cadda] {
+ z-index: 9999;
+ animation-duration: 0.5s !important;
+}
+.music-play-bar .music-content[data-v-5d6cadda] {
+ width: 160px;
+ margin-left: 1rem;
+}
+.music-play-bar .music-content-title[data-v-5d6cadda] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+}
+.music-play-bar .music-content-name[data-v-5d6cadda] {
+ margin-top: 0.25rem;
+ font-size: 0.75rem;
+ line-height: 1rem;
+ opacity: 0.8;
+}
+.play-bar-opcity[data-v-5d6cadda] {
+ background-color: transparent !important;
+ box-shadow: 0 0 20px 5px rgba(0, 0, 0, 0.1137254902);
+}
+.play-bar-img[data-v-5d6cadda] {
+ height: 3.5rem;
+ width: 3.5rem;
+ border-radius: 1rem;
+}
+.music-buttons[data-v-5d6cadda] {
+ margin-left: 1.5rem;
+ margin-right: 1.5rem;
+ flex: 1 1 0%;
+ justify-content: center;
+ display: flex;
+ align-items: center;
+}
+.music-buttons .iconfont[data-v-5d6cadda] {
+ font-size: 1.5rem;
+ line-height: 2rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.music-buttons .iconfont[data-v-5d6cadda]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.music-buttons .icon[data-v-5d6cadda] {
+ font-size: 1.875rem;
+ line-height: 2.25rem;
+}
+.music-buttons .icon[data-v-5d6cadda]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.music-buttons > div[data-v-5d6cadda] {
+ cursor: pointer;
+}
+.music-buttons-play[data-v-5d6cadda] {
+ margin-left: 1rem;
+ margin-right: 1rem;
+ display: flex;
+ height: 3rem;
+ width: 5rem;
+ align-items: center;
+ justify-content: center;
+ border-radius: 9999px;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.6;
+}
+.music-buttons-play[data-v-5d6cadda]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(229 231 235 / var(--tw-bg-opacity, 1));
+}
+.audio-volume[data-v-5d6cadda] {
+ position: relative;
+ display: flex;
+ align-items: center;
+}
+.audio-volume:hover .volume-slider[data-v-5d6cadda] {
+ visibility: visible;
+ opacity: 1;
+}
+.audio-volume .volume-icon[data-v-5d6cadda] {
+ cursor: pointer;
+}
+.audio-volume .iconfont[data-v-5d6cadda] {
+ font-size: 1.5rem;
+ line-height: 2rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.audio-volume .iconfont[data-v-5d6cadda]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.audio-volume .volume-slider[data-v-5d6cadda] {
+ visibility: hidden;
+ position: absolute;
+ bottom: 30px;
+ left: 50%;
+ height: 180px;
+ --tw-translate-x: -50%;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+ border-radius: 0.75rem;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ opacity: 0;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.audio-volume .volume-slider[data-v-5d6cadda]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.audio-volume .volume-slider[data-v-5d6cadda] {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}
+.audio-volume .volume-slider[data-v-5d6cadda]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.audio-button[data-v-5d6cadda] {
+ margin-left: 1rem;
+ margin-right: 1rem;
+ display: flex;
+ align-items: center;
+}
+.audio-button .iconfont[data-v-5d6cadda] {
+ margin: 1rem;
+ cursor: pointer;
+ font-size: 1.5rem;
+ line-height: 2rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.audio-button .iconfont[data-v-5d6cadda]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.music-play-list[data-v-5d6cadda] {
+ height: 50vh;
+ width: 300px;
+ position: relative;
+ overflow: hidden;
+ border-radius: 1.5rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+}
+.music-play-list-back[data-v-5d6cadda] {
+ -webkit-backdrop-filter: blur(20px);
+ backdrop-filter: blur(20px);
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ height: 100%;
+ width: 100%;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.75;
+}
+.music-play-list-back[data-v-5d6cadda]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.music-play-list-content[data-v-5d6cadda] {
+ margin-left: 0.5rem;
+ margin-right: 0.5rem;
+}
+.mobile .music-play-bar[data-v-5d6cadda] {
+ padding-left: 1rem;
+ padding-right: 1rem;
+ bottom: 70px;
+}
+.mobile .music-time[data-v-5d6cadda] {
+ display: none;
+}
+.mobile .ri-netease-cloud-music-line[data-v-5d6cadda] {
+ display: none;
+}
+.mobile .audio-volume[data-v-5d6cadda] {
+ display: none;
+}
+.mobile .audio-button[data-v-5d6cadda] {
+ margin-left: 0px;
+ margin-right: 0px;
+}
+.mobile .music-buttons[data-v-5d6cadda] {
+ margin: 0px;
+}
+.mobile .music-buttons-prev[data-v-5d6cadda], .mobile .music-buttons-next[data-v-5d6cadda] {
+ display: none;
+}
+.mobile .music-buttons-play[data-v-5d6cadda] {
+ margin: 0px;
+}
+.mobile .music-content[data-v-5d6cadda] {
+ flex: 1;
+}
+.custom-slider[data-v-5d6cadda] .n-slider {
+ --n-rail-height: 4px;
+ --n-rail-color: #e5e7eb;
+ --n-rail-color-dark: #374151;
+ --n-fill-color: #22c55e;
+ --n-handle-size: 12px;
+ --n-handle-color: #22c55e;
+}
+.custom-slider[data-v-5d6cadda] .n-slider.n-slider--vertical {
+ height: 100%;
+}
+.custom-slider[data-v-5d6cadda] .n-slider.n-slider--vertical .n-slider-rail {
+ width: 4px;
+}
+.custom-slider[data-v-5d6cadda] .n-slider.n-slider--vertical:hover .n-slider-rail {
+ width: 6px;
+}
+.custom-slider[data-v-5d6cadda] .n-slider.n-slider--vertical:hover .n-slider-handle {
+ width: 14px;
+ height: 14px;
+}
+.custom-slider[data-v-5d6cadda] .n-slider .n-slider-rail {
+ overflow: hidden;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 200ms;
+ background-color: rgb(107 114 128 / var(--tw-bg-opacity, 1)) !important;
+ --tw-bg-opacity: 0.1 !important;
+}
+.custom-slider[data-v-5d6cadda] .n-slider .n-slider-rail:is(.dark *) {
+ --tw-bg-opacity: 1 !important;
+ background-color: rgb(61 61 61 / var(--tw-bg-opacity, 1)) !important;
+}
+.custom-slider[data-v-5d6cadda] .n-slider .n-slider-handle {
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 200ms;
+ opacity: 0;
+}
+.custom-slider[data-v-5d6cadda] .n-slider:hover .n-slider-handle {
+ opacity: 1;
+}
+.play-bar-img-wrapper[data-v-5d6cadda] {
+ position: relative;
+ height: 3.5rem;
+ width: 3.5rem;
+ cursor: pointer;
+}
+.play-bar-img-wrapper .hover-arrow[data-v-5d6cadda] {
+ position: absolute;
+ inset: 0px;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border-radius: 1rem;
+ opacity: 0;
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ background: rgba(0, 0, 0, 0.5);
+}
+.play-bar-img-wrapper .hover-arrow .hover-content[data-v-5d6cadda] {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+}
+.play-bar-img-wrapper .hover-arrow .hover-content i[data-v-5d6cadda] {
+ margin-bottom: 0.125rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-bar-img-wrapper .hover-arrow .hover-content .hover-text[data-v-5d6cadda] {
+ --tw-scale-x: .9;
+ --tw-scale-y: .9;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+ font-size: 0.75rem;
+ line-height: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-bar-img-wrapper:hover .hover-arrow[data-v-5d6cadda] {
+ opacity: 1;
+}
+.tooltip-content[data-v-5d6cadda] {
+ padding-top: 0.25rem;
+ padding-bottom: 0.25rem;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+}
+.play-bar-img[data-v-5d6cadda] {
+ height: 3.5rem;
+ width: 3.5rem;
+ border-radius: 1rem;
+}
+.like-active[data-v-5d6cadda] {
+ --tw-text-opacity: 1 !important;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1)) !important;
+}
+.like-active[data-v-5d6cadda]:hover {
+ --tw-text-opacity: 1 !important;
+ color: rgb(220 38 38 / var(--tw-text-opacity, 1)) !important;
+}
+.icon-loop[data-v-5d6cadda],
+.icon-single-loop[data-v-5d6cadda] {
+ font-size: 1.5rem;
+}
+.music-time .n-slider[data-v-5d6cadda] {
+ position: absolute;
+ top: 0;
+ left: 0;
+ padding: 0;
+ border-radius: 0;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/PlayBar-Ct36doNR.css.gz b/out/renderer/assets/PlayBar-Ct36doNR.css.gz
new file mode 100644
index 0000000..1c18e39
Binary files /dev/null and b/out/renderer/assets/PlayBar-Ct36doNR.css.gz differ
diff --git a/out/renderer/assets/SearchBar-CIYxJjXH.css b/out/renderer/assets/SearchBar-CIYxJjXH.css
new file mode 100644
index 0000000..e2a2a46
--- /dev/null
+++ b/out/renderer/assets/SearchBar-CIYxJjXH.css
@@ -0,0 +1,219 @@
+.user-box[data-v-064c45e9] {
+ margin-left: 1rem;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ border-radius: 9999px;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 200ms;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}.user-box[data-v-064c45e9]:hover {
+ --tw-border-opacity: 1;
+ border-color: rgb(156 163 175 / var(--tw-border-opacity, 1));
+}.user-box[data-v-064c45e9]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1));
+}.user-box[data-v-064c45e9]:hover:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(156 163 175 / var(--tw-border-opacity, 1));
+}.user-box[data-v-064c45e9] {
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}.user-box[data-v-064c45e9]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.search-box[data-v-064c45e9] {
+ padding-bottom: 1rem;
+ padding-right: 1rem;
+}
+.search-box-input[data-v-064c45e9] {
+ position: relative;
+}
+.search-box-input[data-v-064c45e9] .n-input {
+ --tw-bg-opacity: 1;
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1));
+}
+.search-box-input[data-v-064c45e9] .n-input:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.search-box-input[data-v-064c45e9] .n-input .n-input__input-el {
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.search-box-input[data-v-064c45e9] .n-input .n-input__input-el:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.search-box-input[data-v-064c45e9] .n-input .n-input__prefix {
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.search-box-input[data-v-064c45e9] .n-input .n-input__prefix:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.mobile .search-box[data-v-064c45e9] {
+ padding-left: 1rem;
+}
+.github[data-v-064c45e9] {
+ margin-left: 1rem;
+ display: flex;
+ height: 100%;
+ cursor: pointer;
+ align-items: center;
+ justify-content: center;
+ border-radius: 9999px;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.github[data-v-064c45e9]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+.github[data-v-064c45e9]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+.github[data-v-064c45e9]:hover:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.github[data-v-064c45e9] {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.github[data-v-064c45e9]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.user-popover[data-v-064c45e9] {
+ min-width: 280px;
+ overflow: hidden;
+ border-radius: 0.75rem;
+ padding: 0px;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.user-popover[data-v-064c45e9]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.user-popover[data-v-064c45e9] {
+ box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
+}
+.user-popover .user-header[data-v-064c45e9] {
+ display: flex;
+ cursor: pointer;
+ align-items: center;
+ gap: 0.5rem;
+ padding: 0.75rem;
+ border-bottom-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(243 244 246 / var(--tw-border-opacity, 1));
+}
+.user-popover .user-header[data-v-064c45e9]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+.user-popover .user-header[data-v-064c45e9]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.user-popover .user-header[data-v-064c45e9]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
+}
+.user-popover .user-header .username[data-v-064c45e9] {
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ font-weight: 500;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.user-popover .user-header .username[data-v-064c45e9]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(229 231 235 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items[data-v-064c45e9] {
+ padding-top: 0.25rem;
+ padding-bottom: 0.25rem;
+}
+.user-popover .menu-items .menu-item[data-v-064c45e9] {
+ display: flex;
+ cursor: pointer;
+ align-items: center;
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(55 65 81 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items .menu-item[data-v-064c45e9]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items .menu-item[data-v-064c45e9] {
+ transition: background-color 0.2s;
+}
+.user-popover .menu-items .menu-item[data-v-064c45e9]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+.user-popover .menu-items .menu-item[data-v-064c45e9]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
+}
+.user-popover .menu-items .menu-item i[data-v-064c45e9] {
+ margin-right: 0.25rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items .menu-item i[data-v-064c45e9]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items .menu-item .version-info[data-v-064c45e9] {
+ margin-left: auto;
+ display: flex;
+ align-items: center;
+}
+.user-popover .menu-items .menu-item .version-info .version-number[data-v-064c45e9] {
+ border-radius: 0.25rem;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ padding-top: 0.125rem;
+ padding-bottom: 0.125rem;
+ font-size: 0.75rem;
+ line-height: 1rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+.user-popover .menu-items .menu-item .version-info .version-number[data-v-064c45e9]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1));
+}
\ No newline at end of file
diff --git a/out/renderer/assets/SearchBar-CIYxJjXH.css.gz b/out/renderer/assets/SearchBar-CIYxJjXH.css.gz
new file mode 100644
index 0000000..4992291
Binary files /dev/null and b/out/renderer/assets/SearchBar-CIYxJjXH.css.gz differ
diff --git a/out/renderer/assets/SearchBar-Cx7zzS9t.js b/out/renderer/assets/SearchBar-Cx7zzS9t.js
new file mode 100644
index 0000000..840cbd7
--- /dev/null
+++ b/out/renderer/assets/SearchBar-Cx7zzS9t.js
@@ -0,0 +1,2263 @@
+import { b8 as reactive, b9 as hasInstance, ba as onBeforeMount, a as onBeforeUnmount, aS as off, bb as readonly, J as on, E as watch, r as ref, d as defineComponent, l as h, aL as createInjectionKey, as as inject, bc as render, aY as popoverBodyInjectionKey, G as computed, $ as provide, D as useMemo, ak as Transition, ax as mergeProps, bd as warn, a3 as Fragment, aZ as modalBodyInjectionKey, aX as drawerBodyInjectionKey, az as XScrollbar, p as cB, aM as fadeInScaleUpTransition, m as c, V as cNotM, W as cM, Y as cE, C as useMergedState, A as toRef, x as useConfig, q as useTheme, be as dropdownLight, L as call, ao as createKey, ap as useThemeClass, bf as keep, j as openBlock, c as createElementBlock, e as createVNode, f as withCtx, bg as renderSlot, u as unref, B as Button, k as createTextVNode, b as createBaseVNode, h as useRouter, g as useStore, a8 as watchEffect, o as onMounted, Q as config, P as checkUpdate, t as toDisplayString, bh as withKeys, O as createBlock, a7 as getImgUrl, T as createCommentVNode, n as normalizeClass, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { f as getSearchKeyword } from "./home-BXGE9AqN.js";
+import { u as useMessage, b as getUserDetail, d as logout } from "./login-BsPxQYi6.js";
+import { r as renderArrow, a as __unplugin_components_5, p as popoverBaseProps, N as NImage } from "./Image-DXClIklC.js";
+import { B as Binder, V as VTarget, e as VFollower } from "./use-locale-DLWAOXez.js";
+import { N as NIcon } from "./Icon-DucaliTK.js";
+import { _ as __unplugin_components_1, a as __unplugin_components_3 } from "./Switch-D3Z_Vg3u.js";
+import { _ as __unplugin_components_2 } from "./Avatar-rQ2og-6c.js";
+import { _ as __unplugin_components_4 } from "./Tag-C0oC92WF.js";
+function happensIn(e, dataSetPropName) {
+ let { target } = e;
+ while (target) {
+ if (target.dataset) {
+ if (target.dataset[dataSetPropName] !== void 0)
+ return true;
+ }
+ target = target.parentElement;
+ }
+ return false;
+}
+function useKeyboard(options = {}, enabledRef) {
+ const state = reactive({
+ ctrl: false,
+ command: false,
+ win: false,
+ shift: false,
+ tab: false
+ });
+ const { keydown, keyup } = options;
+ const keydownHandler = (e) => {
+ switch (e.key) {
+ case "Control":
+ state.ctrl = true;
+ break;
+ case "Meta":
+ state.command = true;
+ state.win = true;
+ break;
+ case "Shift":
+ state.shift = true;
+ break;
+ case "Tab":
+ state.tab = true;
+ break;
+ }
+ if (keydown !== void 0) {
+ Object.keys(keydown).forEach((key) => {
+ if (key !== e.key)
+ return;
+ const handler = keydown[key];
+ if (typeof handler === "function") {
+ handler(e);
+ } else {
+ const { stop = false, prevent = false } = handler;
+ if (stop)
+ e.stopPropagation();
+ if (prevent)
+ e.preventDefault();
+ handler.handler(e);
+ }
+ });
+ }
+ };
+ const keyupHandler = (e) => {
+ switch (e.key) {
+ case "Control":
+ state.ctrl = false;
+ break;
+ case "Meta":
+ state.command = false;
+ state.win = false;
+ break;
+ case "Shift":
+ state.shift = false;
+ break;
+ case "Tab":
+ state.tab = false;
+ break;
+ }
+ if (keyup !== void 0) {
+ Object.keys(keyup).forEach((key) => {
+ if (key !== e.key)
+ return;
+ const handler = keyup[key];
+ if (typeof handler === "function") {
+ handler(e);
+ } else {
+ const { stop = false, prevent = false } = handler;
+ if (stop)
+ e.stopPropagation();
+ if (prevent)
+ e.preventDefault();
+ handler.handler(e);
+ }
+ });
+ }
+ };
+ const setup = () => {
+ if (enabledRef === void 0 || enabledRef.value) {
+ on("keydown", document, keydownHandler);
+ on("keyup", document, keyupHandler);
+ }
+ if (enabledRef !== void 0) {
+ watch(enabledRef, (value) => {
+ if (value) {
+ on("keydown", document, keydownHandler);
+ on("keyup", document, keyupHandler);
+ } else {
+ off("keydown", document, keydownHandler);
+ off("keyup", document, keyupHandler);
+ }
+ });
+ }
+ };
+ if (hasInstance()) {
+ onBeforeMount(setup);
+ onBeforeUnmount(() => {
+ if (enabledRef === void 0 || enabledRef.value) {
+ off("keydown", document, keydownHandler);
+ off("keyup", document, keyupHandler);
+ }
+ });
+ } else {
+ setup();
+ }
+ return readonly(state);
+}
+function useDeferredTrue(valueRef, delay, shouldDelayRef) {
+ const delayedRef = ref(valueRef.value);
+ let timerId = null;
+ watch(valueRef, (value) => {
+ if (timerId !== null) window.clearTimeout(timerId);
+ if (value === true) {
+ if (shouldDelayRef && !shouldDelayRef.value) {
+ delayedRef.value = true;
+ } else {
+ timerId = window.setTimeout(() => {
+ delayedRef.value = true;
+ }, delay);
+ }
+ } else {
+ delayedRef.value = false;
+ }
+ });
+ return delayedRef;
+}
+function createRefSetter(ref2) {
+ return (inst) => {
+ if (inst) {
+ ref2.value = inst.$el;
+ } else {
+ ref2.value = null;
+ }
+ };
+}
+const ChevronRightIcon = defineComponent({
+ name: "ChevronRight",
+ render() {
+ return h("svg", {
+ viewBox: "0 0 16 16",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M5.64645 3.14645C5.45118 3.34171 5.45118 3.65829 5.64645 3.85355L9.79289 8L5.64645 12.1464C5.45118 12.3417 5.45118 12.6583 5.64645 12.8536C5.84171 13.0488 6.15829 13.0488 6.35355 12.8536L10.8536 8.35355C11.0488 8.15829 11.0488 7.84171 10.8536 7.64645L6.35355 3.14645C6.15829 2.95118 5.84171 2.95118 5.64645 3.14645Z",
+ fill: "currentColor"
+ }));
+ }
+});
+function toArray(arg) {
+ if (Array.isArray(arg))
+ return arg;
+ return [arg];
+}
+const TRAVERSE_COMMAND = {
+ STOP: "STOP"
+};
+function traverseWithCb(treeNode, callback) {
+ const command = callback(treeNode);
+ if (treeNode.children !== void 0 && command !== TRAVERSE_COMMAND.STOP) {
+ treeNode.children.forEach((childNode) => traverseWithCb(childNode, callback));
+ }
+}
+function getNonLeafKeys(treeNodes, options = {}) {
+ const { preserveGroup = false } = options;
+ const keys = [];
+ const cb = preserveGroup ? (node) => {
+ if (!node.isLeaf) {
+ keys.push(node.key);
+ traverse(node.children);
+ }
+ } : (node) => {
+ if (!node.isLeaf) {
+ if (!node.isGroup)
+ keys.push(node.key);
+ traverse(node.children);
+ }
+ };
+ function traverse(nodes) {
+ nodes.forEach(cb);
+ }
+ traverse(treeNodes);
+ return keys;
+}
+function isLeaf(rawNode, getChildren) {
+ const { isLeaf: isLeaf2 } = rawNode;
+ if (isLeaf2 !== void 0)
+ return isLeaf2;
+ else if (!getChildren(rawNode))
+ return true;
+ return false;
+}
+function defaultGetChildren(node) {
+ return node.children;
+}
+function defaultGetKey(node) {
+ return node.key;
+}
+function isIgnored() {
+ return false;
+}
+function isShallowLoaded(rawNode, getChildren) {
+ const { isLeaf: isLeaf2 } = rawNode;
+ if (isLeaf2 === false && !Array.isArray(getChildren(rawNode)))
+ return false;
+ return true;
+}
+function isDisabled(rawNode) {
+ return rawNode.disabled === true;
+}
+function isExpilicitlyNotLoaded(rawNode, getChildren) {
+ return rawNode.isLeaf === false && !Array.isArray(getChildren(rawNode));
+}
+function unwrapCheckedKeys(result) {
+ var _a;
+ if (result === void 0 || result === null)
+ return [];
+ if (Array.isArray(result))
+ return result;
+ return (_a = result.checkedKeys) !== null && _a !== void 0 ? _a : [];
+}
+function unwrapIndeterminateKeys(result) {
+ var _a;
+ if (result === void 0 || result === null || Array.isArray(result)) {
+ return [];
+ }
+ return (_a = result.indeterminateKeys) !== null && _a !== void 0 ? _a : [];
+}
+function merge(originalKeys, keysToAdd) {
+ const set = new Set(originalKeys);
+ keysToAdd.forEach((key) => {
+ if (!set.has(key)) {
+ set.add(key);
+ }
+ });
+ return Array.from(set);
+}
+function minus(originalKeys, keysToRemove) {
+ const set = new Set(originalKeys);
+ keysToRemove.forEach((key) => {
+ if (set.has(key)) {
+ set.delete(key);
+ }
+ });
+ return Array.from(set);
+}
+function isGroup(rawNode) {
+ return (rawNode === null || rawNode === void 0 ? void 0 : rawNode.type) === "group";
+}
+class SubtreeNotLoadedError extends Error {
+ constructor() {
+ super();
+ this.message = "SubtreeNotLoadedError: checking a subtree whose required nodes are not fully loaded.";
+ }
+}
+function getExtendedCheckedKeySetAfterCheck(checkKeys, currentCheckedKeys, treeMate, allowNotLoaded) {
+ return getExtendedCheckedKeySet(currentCheckedKeys.concat(checkKeys), treeMate, allowNotLoaded, false);
+}
+function getAvailableAscendantNodeSet(uncheckedKeys, treeMate) {
+ const visitedKeys = /* @__PURE__ */ new Set();
+ uncheckedKeys.forEach((uncheckedKey) => {
+ const uncheckedTreeNode = treeMate.treeNodeMap.get(uncheckedKey);
+ if (uncheckedTreeNode !== void 0) {
+ let nodeCursor = uncheckedTreeNode.parent;
+ while (nodeCursor !== null) {
+ if (nodeCursor.disabled)
+ break;
+ if (visitedKeys.has(nodeCursor.key))
+ break;
+ else {
+ visitedKeys.add(nodeCursor.key);
+ }
+ nodeCursor = nodeCursor.parent;
+ }
+ }
+ });
+ return visitedKeys;
+}
+function getExtendedCheckedKeySetAfterUncheck(uncheckedKeys, currentCheckedKeys, treeMate, allowNotLoaded) {
+ const extendedCheckedKeySet = getExtendedCheckedKeySet(currentCheckedKeys, treeMate, allowNotLoaded, false);
+ const extendedKeySetToUncheck = getExtendedCheckedKeySet(uncheckedKeys, treeMate, allowNotLoaded, true);
+ const ascendantKeySet = getAvailableAscendantNodeSet(uncheckedKeys, treeMate);
+ const keysToRemove = [];
+ extendedCheckedKeySet.forEach((key) => {
+ if (extendedKeySetToUncheck.has(key) || ascendantKeySet.has(key)) {
+ keysToRemove.push(key);
+ }
+ });
+ keysToRemove.forEach((key) => extendedCheckedKeySet.delete(key));
+ return extendedCheckedKeySet;
+}
+function getCheckedKeys(options, treeMate) {
+ const { checkedKeys, keysToCheck, keysToUncheck, indeterminateKeys, cascade, leafOnly, checkStrategy, allowNotLoaded } = options;
+ if (!cascade) {
+ if (keysToCheck !== void 0) {
+ return {
+ checkedKeys: merge(checkedKeys, keysToCheck),
+ indeterminateKeys: Array.from(indeterminateKeys)
+ };
+ } else if (keysToUncheck !== void 0) {
+ return {
+ checkedKeys: minus(checkedKeys, keysToUncheck),
+ indeterminateKeys: Array.from(indeterminateKeys)
+ };
+ } else {
+ return {
+ checkedKeys: Array.from(checkedKeys),
+ indeterminateKeys: Array.from(indeterminateKeys)
+ };
+ }
+ }
+ const { levelTreeNodeMap } = treeMate;
+ let extendedCheckedKeySet;
+ if (keysToUncheck !== void 0) {
+ extendedCheckedKeySet = getExtendedCheckedKeySetAfterUncheck(keysToUncheck, checkedKeys, treeMate, allowNotLoaded);
+ } else if (keysToCheck !== void 0) {
+ extendedCheckedKeySet = getExtendedCheckedKeySetAfterCheck(keysToCheck, checkedKeys, treeMate, allowNotLoaded);
+ } else {
+ extendedCheckedKeySet = getExtendedCheckedKeySet(checkedKeys, treeMate, allowNotLoaded, false);
+ }
+ const checkStrategyIsParent = checkStrategy === "parent";
+ const checkStrategyIsChild = checkStrategy === "child" || leafOnly;
+ const syntheticCheckedKeySet = extendedCheckedKeySet;
+ const syntheticIndeterminateKeySet = /* @__PURE__ */ new Set();
+ const maxLevel = Math.max.apply(null, Array.from(levelTreeNodeMap.keys()));
+ for (let level = maxLevel; level >= 0; level -= 1) {
+ const levelIsZero = level === 0;
+ const levelTreeNodes = levelTreeNodeMap.get(level);
+ for (const levelTreeNode of levelTreeNodes) {
+ if (levelTreeNode.isLeaf)
+ continue;
+ const { key: levelTreeNodeKey, shallowLoaded } = levelTreeNode;
+ if (checkStrategyIsChild && shallowLoaded) {
+ levelTreeNode.children.forEach((v) => {
+ if (!v.disabled && !v.isLeaf && v.shallowLoaded && syntheticCheckedKeySet.has(v.key)) {
+ syntheticCheckedKeySet.delete(v.key);
+ }
+ });
+ }
+ if (levelTreeNode.disabled || !shallowLoaded) {
+ continue;
+ }
+ let fullyChecked = true;
+ let partialChecked = false;
+ let allDisabled = true;
+ for (const childNode of levelTreeNode.children) {
+ const childKey = childNode.key;
+ if (childNode.disabled)
+ continue;
+ if (allDisabled)
+ allDisabled = false;
+ if (syntheticCheckedKeySet.has(childKey)) {
+ partialChecked = true;
+ } else if (syntheticIndeterminateKeySet.has(childKey)) {
+ partialChecked = true;
+ fullyChecked = false;
+ break;
+ } else {
+ fullyChecked = false;
+ if (partialChecked) {
+ break;
+ }
+ }
+ }
+ if (fullyChecked && !allDisabled) {
+ if (checkStrategyIsParent) {
+ levelTreeNode.children.forEach((v) => {
+ if (!v.disabled && syntheticCheckedKeySet.has(v.key)) {
+ syntheticCheckedKeySet.delete(v.key);
+ }
+ });
+ }
+ syntheticCheckedKeySet.add(levelTreeNodeKey);
+ } else if (partialChecked) {
+ syntheticIndeterminateKeySet.add(levelTreeNodeKey);
+ }
+ if (levelIsZero && checkStrategyIsChild && syntheticCheckedKeySet.has(levelTreeNodeKey)) {
+ syntheticCheckedKeySet.delete(levelTreeNodeKey);
+ }
+ }
+ }
+ return {
+ checkedKeys: Array.from(syntheticCheckedKeySet),
+ indeterminateKeys: Array.from(syntheticIndeterminateKeySet)
+ };
+}
+function getExtendedCheckedKeySet(checkedKeys, treeMate, allowNotLoaded, isUnchecking) {
+ const { treeNodeMap, getChildren } = treeMate;
+ const visitedKeySet = /* @__PURE__ */ new Set();
+ const extendedKeySet = new Set(checkedKeys);
+ checkedKeys.forEach((checkedKey) => {
+ const checkedTreeNode = treeNodeMap.get(checkedKey);
+ if (checkedTreeNode !== void 0) {
+ traverseWithCb(checkedTreeNode, (treeNode) => {
+ if (treeNode.disabled) {
+ return TRAVERSE_COMMAND.STOP;
+ }
+ const { key } = treeNode;
+ if (visitedKeySet.has(key))
+ return;
+ visitedKeySet.add(key);
+ extendedKeySet.add(key);
+ if (isExpilicitlyNotLoaded(treeNode.rawNode, getChildren)) {
+ if (isUnchecking) {
+ return TRAVERSE_COMMAND.STOP;
+ } else if (!allowNotLoaded) {
+ throw new SubtreeNotLoadedError();
+ }
+ }
+ });
+ }
+ });
+ return extendedKeySet;
+}
+function getPath(key, { includeGroup = false, includeSelf = true }, treeMate) {
+ var _a;
+ const treeNodeMap = treeMate.treeNodeMap;
+ let treeNode = key === null || key === void 0 ? null : (_a = treeNodeMap.get(key)) !== null && _a !== void 0 ? _a : null;
+ const mergedPath = {
+ keyPath: [],
+ treeNodePath: [],
+ treeNode
+ };
+ if (treeNode === null || treeNode === void 0 ? void 0 : treeNode.ignored) {
+ mergedPath.treeNode = null;
+ return mergedPath;
+ }
+ while (treeNode) {
+ if (!treeNode.ignored && (includeGroup || !treeNode.isGroup)) {
+ mergedPath.treeNodePath.push(treeNode);
+ }
+ treeNode = treeNode.parent;
+ }
+ mergedPath.treeNodePath.reverse();
+ if (!includeSelf)
+ mergedPath.treeNodePath.pop();
+ mergedPath.keyPath = mergedPath.treeNodePath.map((treeNode2) => treeNode2.key);
+ return mergedPath;
+}
+function getFirstAvailableNode(nodes) {
+ if (nodes.length === 0)
+ return null;
+ const node = nodes[0];
+ if (node.isGroup || node.ignored || node.disabled) {
+ return node.getNext();
+ }
+ return node;
+}
+function rawGetNext(node, loop) {
+ const sibs = node.siblings;
+ const l = sibs.length;
+ const { index } = node;
+ if (loop) {
+ return sibs[(index + 1) % l];
+ } else {
+ if (index === sibs.length - 1)
+ return null;
+ return sibs[index + 1];
+ }
+}
+function move(fromNode, dir, { loop = false, includeDisabled = false } = {}) {
+ const iterate = dir === "prev" ? rawGetPrev : rawGetNext;
+ const getChildOptions = {
+ reverse: dir === "prev"
+ };
+ let meet = false;
+ let endNode = null;
+ function traverse(node) {
+ if (node === null)
+ return;
+ if (node === fromNode) {
+ if (!meet) {
+ meet = true;
+ } else if (!fromNode.disabled && !fromNode.isGroup) {
+ endNode = fromNode;
+ return;
+ }
+ } else {
+ if ((!node.disabled || includeDisabled) && !node.ignored && !node.isGroup) {
+ endNode = node;
+ return;
+ }
+ }
+ if (node.isGroup) {
+ const child = getChild(node, getChildOptions);
+ if (child !== null) {
+ endNode = child;
+ } else {
+ traverse(iterate(node, loop));
+ }
+ } else {
+ const nextNode = iterate(node, false);
+ if (nextNode !== null) {
+ traverse(nextNode);
+ } else {
+ const parent = rawGetParent(node);
+ if (parent === null || parent === void 0 ? void 0 : parent.isGroup) {
+ traverse(iterate(parent, loop));
+ } else if (loop) {
+ traverse(iterate(node, true));
+ }
+ }
+ }
+ }
+ traverse(fromNode);
+ return endNode;
+}
+function rawGetPrev(node, loop) {
+ const sibs = node.siblings;
+ const l = sibs.length;
+ const { index } = node;
+ if (loop) {
+ return sibs[(index - 1 + l) % l];
+ } else {
+ if (index === 0)
+ return null;
+ return sibs[index - 1];
+ }
+}
+function rawGetParent(node) {
+ return node.parent;
+}
+function getChild(node, options = {}) {
+ const { reverse = false } = options;
+ const { children } = node;
+ if (children) {
+ const { length } = children;
+ const start = reverse ? length - 1 : 0;
+ const end = reverse ? -1 : length;
+ const delta = reverse ? -1 : 1;
+ for (let i = start; i !== end; i += delta) {
+ const child = children[i];
+ if (!child.disabled && !child.ignored) {
+ if (child.isGroup) {
+ const childInGroup = getChild(child, options);
+ if (childInGroup !== null)
+ return childInGroup;
+ } else {
+ return child;
+ }
+ }
+ }
+ }
+ return null;
+}
+const moveMethods = {
+ getChild() {
+ if (this.ignored)
+ return null;
+ return getChild(this);
+ },
+ getParent() {
+ const { parent } = this;
+ if (parent === null || parent === void 0 ? void 0 : parent.isGroup) {
+ return parent.getParent();
+ }
+ return parent;
+ },
+ getNext(options = {}) {
+ return move(this, "next", options);
+ },
+ getPrev(options = {}) {
+ return move(this, "prev", options);
+ }
+};
+function flatten(treeNodes, expandedKeys) {
+ const expandedKeySet = expandedKeys ? new Set(expandedKeys) : void 0;
+ const flattenedNodes = [];
+ function traverse(treeNodes2) {
+ treeNodes2.forEach((treeNode) => {
+ flattenedNodes.push(treeNode);
+ if (treeNode.isLeaf || !treeNode.children || treeNode.ignored)
+ return;
+ if (treeNode.isGroup) {
+ traverse(treeNode.children);
+ } else if (
+ // normal non-leaf node
+ expandedKeySet === void 0 || expandedKeySet.has(treeNode.key)
+ ) {
+ traverse(treeNode.children);
+ }
+ });
+ }
+ traverse(treeNodes);
+ return flattenedNodes;
+}
+function contains(parent, child) {
+ const parentKey = parent.key;
+ while (child) {
+ if (child.key === parentKey)
+ return true;
+ child = child.parent;
+ }
+ return false;
+}
+function createTreeNodes(rawNodes, treeNodeMap, levelTreeNodeMap, nodeProto, getChildren, parent = null, level = 0) {
+ const treeNodes = [];
+ rawNodes.forEach((rawNode, index) => {
+ var _a;
+ const treeNode = Object.create(nodeProto);
+ treeNode.rawNode = rawNode;
+ treeNode.siblings = treeNodes;
+ treeNode.level = level;
+ treeNode.index = index;
+ treeNode.isFirstChild = index === 0;
+ treeNode.isLastChild = index + 1 === rawNodes.length;
+ treeNode.parent = parent;
+ if (!treeNode.ignored) {
+ const rawChildren = getChildren(rawNode);
+ if (Array.isArray(rawChildren)) {
+ treeNode.children = createTreeNodes(rawChildren, treeNodeMap, levelTreeNodeMap, nodeProto, getChildren, treeNode, level + 1);
+ }
+ }
+ treeNodes.push(treeNode);
+ treeNodeMap.set(treeNode.key, treeNode);
+ if (!levelTreeNodeMap.has(level))
+ levelTreeNodeMap.set(level, []);
+ (_a = levelTreeNodeMap.get(level)) === null || _a === void 0 ? void 0 : _a.push(treeNode);
+ });
+ return treeNodes;
+}
+function createTreeMate(rawNodes, options = {}) {
+ var _a;
+ const treeNodeMap = /* @__PURE__ */ new Map();
+ const levelTreeNodeMap = /* @__PURE__ */ new Map();
+ const { getDisabled = isDisabled, getIgnored = isIgnored, getIsGroup = isGroup, getKey = defaultGetKey } = options;
+ const _getChildren = (_a = options.getChildren) !== null && _a !== void 0 ? _a : defaultGetChildren;
+ const getChildren = options.ignoreEmptyChildren ? (node) => {
+ const children = _getChildren(node);
+ if (Array.isArray(children)) {
+ if (!children.length)
+ return null;
+ return children;
+ }
+ return children;
+ } : _getChildren;
+ const nodeProto = Object.assign({
+ get key() {
+ return getKey(this.rawNode);
+ },
+ get disabled() {
+ return getDisabled(this.rawNode);
+ },
+ get isGroup() {
+ return getIsGroup(this.rawNode);
+ },
+ get isLeaf() {
+ return isLeaf(this.rawNode, getChildren);
+ },
+ get shallowLoaded() {
+ return isShallowLoaded(this.rawNode, getChildren);
+ },
+ get ignored() {
+ return getIgnored(this.rawNode);
+ },
+ contains(node) {
+ return contains(this, node);
+ }
+ }, moveMethods);
+ const treeNodes = createTreeNodes(rawNodes, treeNodeMap, levelTreeNodeMap, nodeProto, getChildren);
+ function getNode(key) {
+ if (key === null || key === void 0)
+ return null;
+ const tmNode = treeNodeMap.get(key);
+ if (tmNode && !tmNode.isGroup && !tmNode.ignored) {
+ return tmNode;
+ }
+ return null;
+ }
+ function _getNode(key) {
+ if (key === null || key === void 0)
+ return null;
+ const tmNode = treeNodeMap.get(key);
+ if (tmNode && !tmNode.ignored) {
+ return tmNode;
+ }
+ return null;
+ }
+ function getPrev(key, options2) {
+ const node = _getNode(key);
+ if (!node)
+ return null;
+ return node.getPrev(options2);
+ }
+ function getNext(key, options2) {
+ const node = _getNode(key);
+ if (!node)
+ return null;
+ return node.getNext(options2);
+ }
+ function getParent(key) {
+ const node = _getNode(key);
+ if (!node)
+ return null;
+ return node.getParent();
+ }
+ function getChild2(key) {
+ const node = _getNode(key);
+ if (!node)
+ return null;
+ return node.getChild();
+ }
+ const treemate = {
+ treeNodes,
+ treeNodeMap,
+ levelTreeNodeMap,
+ maxLevel: Math.max(...levelTreeNodeMap.keys()),
+ getChildren,
+ getFlattenedNodes(expandedKeys) {
+ return flatten(treeNodes, expandedKeys);
+ },
+ getNode,
+ getPrev,
+ getNext,
+ getParent,
+ getChild: getChild2,
+ getFirstAvailableNode() {
+ return getFirstAvailableNode(treeNodes);
+ },
+ getPath(key, options2 = {}) {
+ return getPath(key, options2, treemate);
+ },
+ getCheckedKeys(checkedKeys, options2 = {}) {
+ const { cascade = true, leafOnly = false, checkStrategy = "all", allowNotLoaded = false } = options2;
+ return getCheckedKeys({
+ checkedKeys: unwrapCheckedKeys(checkedKeys),
+ indeterminateKeys: unwrapIndeterminateKeys(checkedKeys),
+ cascade,
+ leafOnly,
+ checkStrategy,
+ allowNotLoaded
+ }, treemate);
+ },
+ check(keysToCheck, checkedKeys, options2 = {}) {
+ const { cascade = true, leafOnly = false, checkStrategy = "all", allowNotLoaded = false } = options2;
+ return getCheckedKeys({
+ checkedKeys: unwrapCheckedKeys(checkedKeys),
+ indeterminateKeys: unwrapIndeterminateKeys(checkedKeys),
+ keysToCheck: keysToCheck === void 0 || keysToCheck === null ? [] : toArray(keysToCheck),
+ cascade,
+ leafOnly,
+ checkStrategy,
+ allowNotLoaded
+ }, treemate);
+ },
+ uncheck(keysToUncheck, checkedKeys, options2 = {}) {
+ const { cascade = true, leafOnly = false, checkStrategy = "all", allowNotLoaded = false } = options2;
+ return getCheckedKeys({
+ checkedKeys: unwrapCheckedKeys(checkedKeys),
+ indeterminateKeys: unwrapIndeterminateKeys(checkedKeys),
+ keysToUncheck: keysToUncheck === null || keysToUncheck === void 0 ? [] : toArray(keysToUncheck),
+ cascade,
+ leafOnly,
+ checkStrategy,
+ allowNotLoaded
+ }, treemate);
+ },
+ getNonLeafKeys(options2 = {}) {
+ return getNonLeafKeys(treeNodes, options2);
+ }
+ };
+ return treemate;
+}
+const dropdownMenuInjectionKey = createInjectionKey("n-dropdown-menu");
+const dropdownInjectionKey = createInjectionKey("n-dropdown");
+const dropdownOptionInjectionKey = createInjectionKey("n-dropdown-option");
+const NDropdownDivider = defineComponent({
+ name: "DropdownDivider",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ }
+ },
+ render() {
+ return h("div", {
+ class: `${this.clsPrefix}-dropdown-divider`
+ });
+ }
+});
+const NDropdownGroupHeader = defineComponent({
+ name: "DropdownGroupHeader",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ tmNode: {
+ type: Object,
+ required: true
+ }
+ },
+ setup() {
+ const {
+ showIconRef,
+ hasSubmenuRef
+ } = inject(dropdownMenuInjectionKey);
+ const {
+ renderLabelRef,
+ labelFieldRef,
+ nodePropsRef,
+ renderOptionRef
+ } = inject(dropdownInjectionKey);
+ return {
+ labelField: labelFieldRef,
+ showIcon: showIconRef,
+ hasSubmenu: hasSubmenuRef,
+ renderLabel: renderLabelRef,
+ nodeProps: nodePropsRef,
+ renderOption: renderOptionRef
+ };
+ },
+ render() {
+ var _a;
+ const {
+ clsPrefix,
+ hasSubmenu,
+ showIcon,
+ nodeProps,
+ renderLabel,
+ renderOption
+ } = this;
+ const {
+ rawNode
+ } = this.tmNode;
+ const node = h("div", Object.assign({
+ class: `${clsPrefix}-dropdown-option`
+ }, nodeProps === null || nodeProps === void 0 ? void 0 : nodeProps(rawNode)), h("div", {
+ class: `${clsPrefix}-dropdown-option-body ${clsPrefix}-dropdown-option-body--group`
+ }, h("div", {
+ "data-dropdown-option": true,
+ class: [`${clsPrefix}-dropdown-option-body__prefix`, showIcon && `${clsPrefix}-dropdown-option-body__prefix--show-icon`]
+ }, render(rawNode.icon)), h("div", {
+ class: `${clsPrefix}-dropdown-option-body__label`,
+ "data-dropdown-option": true
+ }, renderLabel ? renderLabel(rawNode) : render((_a = rawNode.title) !== null && _a !== void 0 ? _a : rawNode[this.labelField])), h("div", {
+ class: [`${clsPrefix}-dropdown-option-body__suffix`, hasSubmenu && `${clsPrefix}-dropdown-option-body__suffix--has-submenu`],
+ "data-dropdown-option": true
+ })));
+ if (renderOption) {
+ return renderOption({
+ node,
+ option: rawNode
+ });
+ }
+ return node;
+ }
+});
+function isSubmenuNode(rawNode, childrenField) {
+ return rawNode.type === "submenu" || rawNode.type === void 0 && rawNode[childrenField] !== void 0;
+}
+function isGroupNode(rawNode) {
+ return rawNode.type === "group";
+}
+function isDividerNode(rawNode) {
+ return rawNode.type === "divider";
+}
+function isRenderNode(rawNode) {
+ return rawNode.type === "render";
+}
+const NDropdownOption = defineComponent({
+ name: "DropdownOption",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ tmNode: {
+ type: Object,
+ required: true
+ },
+ parentKey: {
+ type: [String, Number],
+ default: null
+ },
+ placement: {
+ type: String,
+ default: "right-start"
+ },
+ props: Object,
+ scrollable: Boolean
+ },
+ setup(props) {
+ const NDropdown = inject(dropdownInjectionKey);
+ const {
+ hoverKeyRef,
+ keyboardKeyRef,
+ lastToggledSubmenuKeyRef,
+ pendingKeyPathRef,
+ activeKeyPathRef,
+ animatedRef,
+ mergedShowRef,
+ renderLabelRef,
+ renderIconRef,
+ labelFieldRef,
+ childrenFieldRef,
+ renderOptionRef,
+ nodePropsRef,
+ menuPropsRef
+ } = NDropdown;
+ const NDropdownOption2 = inject(dropdownOptionInjectionKey, null);
+ const NDropdownMenu2 = inject(dropdownMenuInjectionKey);
+ const NPopoverBody = inject(popoverBodyInjectionKey);
+ const rawNodeRef = computed(() => props.tmNode.rawNode);
+ const hasSubmenuRef = computed(() => {
+ const {
+ value: childrenField
+ } = childrenFieldRef;
+ return isSubmenuNode(props.tmNode.rawNode, childrenField);
+ });
+ const mergedDisabledRef = computed(() => {
+ const {
+ disabled
+ } = props.tmNode;
+ return disabled;
+ });
+ const showSubmenuRef = computed(() => {
+ if (!hasSubmenuRef.value) return false;
+ const {
+ key,
+ disabled
+ } = props.tmNode;
+ if (disabled) return false;
+ const {
+ value: hoverKey
+ } = hoverKeyRef;
+ const {
+ value: keyboardKey
+ } = keyboardKeyRef;
+ const {
+ value: lastToggledSubmenuKey
+ } = lastToggledSubmenuKeyRef;
+ const {
+ value: pendingKeyPath
+ } = pendingKeyPathRef;
+ if (hoverKey !== null) return pendingKeyPath.includes(key);
+ if (keyboardKey !== null) {
+ return pendingKeyPath.includes(key) && pendingKeyPath[pendingKeyPath.length - 1] !== key;
+ }
+ if (lastToggledSubmenuKey !== null) return pendingKeyPath.includes(key);
+ return false;
+ });
+ const shouldDelayRef = computed(() => {
+ return keyboardKeyRef.value === null && !animatedRef.value;
+ });
+ const deferredShowSubmenuRef = useDeferredTrue(showSubmenuRef, 300, shouldDelayRef);
+ const parentEnteringSubmenuRef = computed(() => {
+ return !!(NDropdownOption2 === null || NDropdownOption2 === void 0 ? void 0 : NDropdownOption2.enteringSubmenuRef.value);
+ });
+ const enteringSubmenuRef = ref(false);
+ provide(dropdownOptionInjectionKey, {
+ enteringSubmenuRef
+ });
+ function handleSubmenuBeforeEnter() {
+ enteringSubmenuRef.value = true;
+ }
+ function handleSubmenuAfterEnter() {
+ enteringSubmenuRef.value = false;
+ }
+ function handleMouseEnter() {
+ const {
+ parentKey,
+ tmNode
+ } = props;
+ if (tmNode.disabled) return;
+ if (!mergedShowRef.value) return;
+ lastToggledSubmenuKeyRef.value = parentKey;
+ keyboardKeyRef.value = null;
+ hoverKeyRef.value = tmNode.key;
+ }
+ function handleMouseMove() {
+ const {
+ tmNode
+ } = props;
+ if (tmNode.disabled) return;
+ if (!mergedShowRef.value) return;
+ if (hoverKeyRef.value === tmNode.key) return;
+ handleMouseEnter();
+ }
+ function handleMouseLeave(e) {
+ if (props.tmNode.disabled) return;
+ if (!mergedShowRef.value) return;
+ const {
+ relatedTarget
+ } = e;
+ if (relatedTarget && !happensIn({
+ target: relatedTarget
+ }, "dropdownOption") && !happensIn({
+ target: relatedTarget
+ }, "scrollbarRail")) {
+ hoverKeyRef.value = null;
+ }
+ }
+ function handleClick() {
+ const {
+ value: hasSubmenu
+ } = hasSubmenuRef;
+ const {
+ tmNode
+ } = props;
+ if (!mergedShowRef.value) return;
+ if (!hasSubmenu && !tmNode.disabled) {
+ NDropdown.doSelect(tmNode.key, tmNode.rawNode);
+ NDropdown.doUpdateShow(false);
+ }
+ }
+ return {
+ labelField: labelFieldRef,
+ renderLabel: renderLabelRef,
+ renderIcon: renderIconRef,
+ siblingHasIcon: NDropdownMenu2.showIconRef,
+ siblingHasSubmenu: NDropdownMenu2.hasSubmenuRef,
+ menuProps: menuPropsRef,
+ popoverBody: NPopoverBody,
+ animated: animatedRef,
+ mergedShowSubmenu: computed(() => {
+ return deferredShowSubmenuRef.value && !parentEnteringSubmenuRef.value;
+ }),
+ rawNode: rawNodeRef,
+ hasSubmenu: hasSubmenuRef,
+ pending: useMemo(() => {
+ const {
+ value: pendingKeyPath
+ } = pendingKeyPathRef;
+ const {
+ key
+ } = props.tmNode;
+ return pendingKeyPath.includes(key);
+ }),
+ childActive: useMemo(() => {
+ const {
+ value: activeKeyPath
+ } = activeKeyPathRef;
+ const {
+ key
+ } = props.tmNode;
+ const index = activeKeyPath.findIndex((k) => key === k);
+ if (index === -1) return false;
+ return index < activeKeyPath.length - 1;
+ }),
+ active: useMemo(() => {
+ const {
+ value: activeKeyPath
+ } = activeKeyPathRef;
+ const {
+ key
+ } = props.tmNode;
+ const index = activeKeyPath.findIndex((k) => key === k);
+ if (index === -1) return false;
+ return index === activeKeyPath.length - 1;
+ }),
+ mergedDisabled: mergedDisabledRef,
+ renderOption: renderOptionRef,
+ nodeProps: nodePropsRef,
+ handleClick,
+ handleMouseMove,
+ handleMouseEnter,
+ handleMouseLeave,
+ handleSubmenuBeforeEnter,
+ handleSubmenuAfterEnter
+ };
+ },
+ render() {
+ var _a, _b;
+ const {
+ animated,
+ rawNode,
+ mergedShowSubmenu,
+ clsPrefix,
+ siblingHasIcon,
+ siblingHasSubmenu,
+ renderLabel,
+ renderIcon,
+ renderOption,
+ nodeProps,
+ props,
+ scrollable
+ } = this;
+ let submenuVNode = null;
+ if (mergedShowSubmenu) {
+ const submenuNodeProps = (_a = this.menuProps) === null || _a === void 0 ? void 0 : _a.call(this, rawNode, rawNode.children);
+ submenuVNode = h(NDropdownMenu, Object.assign({}, submenuNodeProps, {
+ clsPrefix,
+ scrollable: this.scrollable,
+ tmNodes: this.tmNode.children,
+ parentKey: this.tmNode.key
+ }));
+ }
+ const builtinProps = {
+ class: [`${clsPrefix}-dropdown-option-body`, this.pending && `${clsPrefix}-dropdown-option-body--pending`, this.active && `${clsPrefix}-dropdown-option-body--active`, this.childActive && `${clsPrefix}-dropdown-option-body--child-active`, this.mergedDisabled && `${clsPrefix}-dropdown-option-body--disabled`],
+ onMousemove: this.handleMouseMove,
+ onMouseenter: this.handleMouseEnter,
+ onMouseleave: this.handleMouseLeave,
+ onClick: this.handleClick
+ };
+ const optionNodeProps = nodeProps === null || nodeProps === void 0 ? void 0 : nodeProps(rawNode);
+ const node = h("div", Object.assign({
+ class: [`${clsPrefix}-dropdown-option`, optionNodeProps === null || optionNodeProps === void 0 ? void 0 : optionNodeProps.class],
+ "data-dropdown-option": true
+ }, optionNodeProps), h("div", mergeProps(builtinProps, props), [h("div", {
+ class: [`${clsPrefix}-dropdown-option-body__prefix`, siblingHasIcon && `${clsPrefix}-dropdown-option-body__prefix--show-icon`]
+ }, [renderIcon ? renderIcon(rawNode) : render(rawNode.icon)]), h("div", {
+ "data-dropdown-option": true,
+ class: `${clsPrefix}-dropdown-option-body__label`
+ }, renderLabel ? renderLabel(rawNode) : render((_b = rawNode[this.labelField]) !== null && _b !== void 0 ? _b : rawNode.title)), h("div", {
+ "data-dropdown-option": true,
+ class: [`${clsPrefix}-dropdown-option-body__suffix`, siblingHasSubmenu && `${clsPrefix}-dropdown-option-body__suffix--has-submenu`]
+ }, this.hasSubmenu ? h(NIcon, null, {
+ default: () => h(ChevronRightIcon, null)
+ }) : null)]), this.hasSubmenu ? h(Binder, null, {
+ default: () => [h(VTarget, null, {
+ default: () => h("div", {
+ class: `${clsPrefix}-dropdown-offset-container`
+ }, h(VFollower, {
+ show: this.mergedShowSubmenu,
+ placement: this.placement,
+ to: scrollable ? this.popoverBody || void 0 : void 0,
+ teleportDisabled: !scrollable
+ }, {
+ default: () => {
+ return h("div", {
+ class: `${clsPrefix}-dropdown-menu-wrapper`
+ }, animated ? h(Transition, {
+ onBeforeEnter: this.handleSubmenuBeforeEnter,
+ onAfterEnter: this.handleSubmenuAfterEnter,
+ name: "fade-in-scale-up-transition",
+ appear: true
+ }, {
+ default: () => submenuVNode
+ }) : submenuVNode);
+ }
+ }))
+ })]
+ }) : null);
+ if (renderOption) {
+ return renderOption({
+ node,
+ option: rawNode
+ });
+ }
+ return node;
+ }
+});
+const NDropdownGroup = defineComponent({
+ name: "NDropdownGroup",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ tmNode: {
+ type: Object,
+ required: true
+ },
+ parentKey: {
+ type: [String, Number],
+ default: null
+ }
+ },
+ render() {
+ const {
+ tmNode,
+ parentKey,
+ clsPrefix
+ } = this;
+ const {
+ children
+ } = tmNode;
+ return h(Fragment, null, h(NDropdownGroupHeader, {
+ clsPrefix,
+ tmNode,
+ key: tmNode.key
+ }), children === null || children === void 0 ? void 0 : children.map((child) => {
+ const {
+ rawNode
+ } = child;
+ if (rawNode.show === false) return null;
+ if (isDividerNode(rawNode)) {
+ return h(NDropdownDivider, {
+ clsPrefix,
+ key: child.key
+ });
+ }
+ if (child.isGroup) {
+ warn("dropdown", "`group` node is not allowed to be put in `group` node.");
+ return null;
+ }
+ return h(NDropdownOption, {
+ clsPrefix,
+ tmNode: child,
+ parentKey,
+ key: child.key
+ });
+ }));
+ }
+});
+const NDropdownRenderOption = defineComponent({
+ name: "DropdownRenderOption",
+ props: {
+ tmNode: {
+ type: Object,
+ required: true
+ }
+ },
+ render() {
+ const {
+ rawNode: {
+ render: render2,
+ props
+ }
+ } = this.tmNode;
+ return h("div", props, [render2 === null || render2 === void 0 ? void 0 : render2()]);
+ }
+});
+const NDropdownMenu = defineComponent({
+ name: "DropdownMenu",
+ props: {
+ scrollable: Boolean,
+ showArrow: Boolean,
+ arrowStyle: [String, Object],
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ tmNodes: {
+ type: Array,
+ default: () => []
+ },
+ parentKey: {
+ type: [String, Number],
+ default: null
+ }
+ },
+ setup(props) {
+ const {
+ renderIconRef,
+ childrenFieldRef
+ } = inject(dropdownInjectionKey);
+ provide(dropdownMenuInjectionKey, {
+ showIconRef: computed(() => {
+ const renderIcon = renderIconRef.value;
+ return props.tmNodes.some((tmNode) => {
+ var _a;
+ if (tmNode.isGroup) {
+ return (_a = tmNode.children) === null || _a === void 0 ? void 0 : _a.some(({
+ rawNode: rawChild
+ }) => renderIcon ? renderIcon(rawChild) : rawChild.icon);
+ }
+ const {
+ rawNode
+ } = tmNode;
+ return renderIcon ? renderIcon(rawNode) : rawNode.icon;
+ });
+ }),
+ hasSubmenuRef: computed(() => {
+ const {
+ value: childrenField
+ } = childrenFieldRef;
+ return props.tmNodes.some((tmNode) => {
+ var _a;
+ if (tmNode.isGroup) {
+ return (_a = tmNode.children) === null || _a === void 0 ? void 0 : _a.some(({
+ rawNode: rawChild
+ }) => isSubmenuNode(rawChild, childrenField));
+ }
+ const {
+ rawNode
+ } = tmNode;
+ return isSubmenuNode(rawNode, childrenField);
+ });
+ })
+ });
+ const bodyRef = ref(null);
+ provide(modalBodyInjectionKey, null);
+ provide(drawerBodyInjectionKey, null);
+ provide(popoverBodyInjectionKey, bodyRef);
+ return {
+ bodyRef
+ };
+ },
+ render() {
+ const {
+ parentKey,
+ clsPrefix,
+ scrollable
+ } = this;
+ const menuOptionsNode = this.tmNodes.map((tmNode) => {
+ const {
+ rawNode
+ } = tmNode;
+ if (rawNode.show === false) return null;
+ if (isRenderNode(rawNode)) {
+ return h(NDropdownRenderOption, {
+ tmNode,
+ key: tmNode.key
+ });
+ }
+ if (isDividerNode(rawNode)) {
+ return h(NDropdownDivider, {
+ clsPrefix,
+ key: tmNode.key
+ });
+ }
+ if (isGroupNode(rawNode)) {
+ return h(NDropdownGroup, {
+ clsPrefix,
+ tmNode,
+ parentKey,
+ key: tmNode.key
+ });
+ }
+ return h(NDropdownOption, {
+ clsPrefix,
+ tmNode,
+ parentKey,
+ key: tmNode.key,
+ props: rawNode.props,
+ scrollable
+ });
+ });
+ return h("div", {
+ class: [`${clsPrefix}-dropdown-menu`, scrollable && `${clsPrefix}-dropdown-menu--scrollable`],
+ ref: "bodyRef"
+ }, scrollable ? h(XScrollbar, {
+ contentClass: `${clsPrefix}-dropdown-menu__content`
+ }, {
+ default: () => menuOptionsNode
+ }) : menuOptionsNode, this.showArrow ? renderArrow({
+ clsPrefix,
+ arrowStyle: this.arrowStyle,
+ arrowClass: void 0,
+ arrowWrapperClass: void 0,
+ arrowWrapperStyle: void 0
+ }) : null);
+ }
+});
+const style = cB("dropdown-menu", `
+ transform-origin: var(--v-transform-origin);
+ background-color: var(--n-color);
+ border-radius: var(--n-border-radius);
+ box-shadow: var(--n-box-shadow);
+ position: relative;
+ transition:
+ background-color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier);
+`, [fadeInScaleUpTransition(), cB("dropdown-option", `
+ position: relative;
+ `, [c("a", `
+ text-decoration: none;
+ color: inherit;
+ outline: none;
+ `, [c("&::before", `
+ content: "";
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ `)]), cB("dropdown-option-body", `
+ display: flex;
+ cursor: pointer;
+ position: relative;
+ height: var(--n-option-height);
+ line-height: var(--n-option-height);
+ font-size: var(--n-font-size);
+ color: var(--n-option-text-color);
+ transition: color .3s var(--n-bezier);
+ `, [c("&::before", `
+ content: "";
+ position: absolute;
+ top: 0;
+ bottom: 0;
+ left: 4px;
+ right: 4px;
+ transition: background-color .3s var(--n-bezier);
+ border-radius: var(--n-border-radius);
+ `), cNotM("disabled", [cM("pending", `
+ color: var(--n-option-text-color-hover);
+ `, [cE("prefix, suffix", `
+ color: var(--n-option-text-color-hover);
+ `), c("&::before", "background-color: var(--n-option-color-hover);")]), cM("active", `
+ color: var(--n-option-text-color-active);
+ `, [cE("prefix, suffix", `
+ color: var(--n-option-text-color-active);
+ `), c("&::before", "background-color: var(--n-option-color-active);")]), cM("child-active", `
+ color: var(--n-option-text-color-child-active);
+ `, [cE("prefix, suffix", `
+ color: var(--n-option-text-color-child-active);
+ `)])]), cM("disabled", `
+ cursor: not-allowed;
+ opacity: var(--n-option-opacity-disabled);
+ `), cM("group", `
+ font-size: calc(var(--n-font-size) - 1px);
+ color: var(--n-group-header-text-color);
+ `, [cE("prefix", `
+ width: calc(var(--n-option-prefix-width) / 2);
+ `, [cM("show-icon", `
+ width: calc(var(--n-option-icon-prefix-width) / 2);
+ `)])]), cE("prefix", `
+ width: var(--n-option-prefix-width);
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ color: var(--n-prefix-color);
+ transition: color .3s var(--n-bezier);
+ z-index: 1;
+ `, [cM("show-icon", `
+ width: var(--n-option-icon-prefix-width);
+ `), cB("icon", `
+ font-size: var(--n-option-icon-size);
+ `)]), cE("label", `
+ white-space: nowrap;
+ flex: 1;
+ z-index: 1;
+ `), cE("suffix", `
+ box-sizing: border-box;
+ flex-grow: 0;
+ flex-shrink: 0;
+ display: flex;
+ justify-content: flex-end;
+ align-items: center;
+ min-width: var(--n-option-suffix-width);
+ padding: 0 8px;
+ transition: color .3s var(--n-bezier);
+ color: var(--n-suffix-color);
+ z-index: 1;
+ `, [cM("has-submenu", `
+ width: var(--n-option-icon-suffix-width);
+ `), cB("icon", `
+ font-size: var(--n-option-icon-size);
+ `)]), cB("dropdown-menu", "pointer-events: all;")]), cB("dropdown-offset-container", `
+ pointer-events: none;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: -4px;
+ bottom: -4px;
+ `)]), cB("dropdown-divider", `
+ transition: background-color .3s var(--n-bezier);
+ background-color: var(--n-divider-color);
+ height: 1px;
+ margin: 4px 0;
+ `), cB("dropdown-menu-wrapper", `
+ transform-origin: var(--v-transform-origin);
+ width: fit-content;
+ `), c(">", [cB("scrollbar", `
+ height: inherit;
+ max-height: inherit;
+ `)]), cNotM("scrollable", `
+ padding: var(--n-padding);
+ `), cM("scrollable", [cE("content", `
+ padding: var(--n-padding);
+ `)])]);
+const dropdownBaseProps = {
+ animated: {
+ type: Boolean,
+ default: true
+ },
+ keyboard: {
+ type: Boolean,
+ default: true
+ },
+ size: {
+ type: String,
+ default: "medium"
+ },
+ inverted: Boolean,
+ placement: {
+ type: String,
+ default: "bottom"
+ },
+ onSelect: [Function, Array],
+ options: {
+ type: Array,
+ default: () => []
+ },
+ menuProps: Function,
+ showArrow: Boolean,
+ renderLabel: Function,
+ renderIcon: Function,
+ renderOption: Function,
+ nodeProps: Function,
+ labelField: {
+ type: String,
+ default: "label"
+ },
+ keyField: {
+ type: String,
+ default: "key"
+ },
+ childrenField: {
+ type: String,
+ default: "children"
+ },
+ // for menu, not documented
+ value: [String, Number]
+};
+const popoverPropKeys = Object.keys(popoverBaseProps);
+const dropdownProps = Object.assign(Object.assign(Object.assign({}, popoverBaseProps), dropdownBaseProps), useTheme.props);
+const __unplugin_components_0 = defineComponent({
+ name: "Dropdown",
+ inheritAttrs: false,
+ props: dropdownProps,
+ setup(props) {
+ const uncontrolledShowRef = ref(false);
+ const mergedShowRef = useMergedState(toRef(props, "show"), uncontrolledShowRef);
+ const treemateRef = computed(() => {
+ const {
+ keyField,
+ childrenField
+ } = props;
+ return createTreeMate(props.options, {
+ getKey(node) {
+ return node[keyField];
+ },
+ getDisabled(node) {
+ return node.disabled === true;
+ },
+ getIgnored(node) {
+ return node.type === "divider" || node.type === "render";
+ },
+ getChildren(node) {
+ return node[childrenField];
+ }
+ });
+ });
+ const tmNodesRef = computed(() => {
+ return treemateRef.value.treeNodes;
+ });
+ const hoverKeyRef = ref(null);
+ const keyboardKeyRef = ref(null);
+ const lastToggledSubmenuKeyRef = ref(null);
+ const pendingKeyRef = computed(() => {
+ var _a, _b, _c;
+ return (_c = (_b = (_a = hoverKeyRef.value) !== null && _a !== void 0 ? _a : keyboardKeyRef.value) !== null && _b !== void 0 ? _b : lastToggledSubmenuKeyRef.value) !== null && _c !== void 0 ? _c : null;
+ });
+ const pendingKeyPathRef = computed(() => treemateRef.value.getPath(pendingKeyRef.value).keyPath);
+ const activeKeyPathRef = computed(() => treemateRef.value.getPath(props.value).keyPath);
+ const keyboardEnabledRef = useMemo(() => {
+ return props.keyboard && mergedShowRef.value;
+ });
+ useKeyboard({
+ keydown: {
+ ArrowUp: {
+ prevent: true,
+ handler: handleKeydownUp
+ },
+ ArrowRight: {
+ prevent: true,
+ handler: handleKeydownRight
+ },
+ ArrowDown: {
+ prevent: true,
+ handler: handleKeydownDown
+ },
+ ArrowLeft: {
+ prevent: true,
+ handler: handleKeydownLeft
+ },
+ Enter: {
+ prevent: true,
+ handler: handleKeydownEnter
+ },
+ Escape: handleKeydownEsc
+ }
+ }, keyboardEnabledRef);
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Dropdown", "-dropdown", style, dropdownLight, props, mergedClsPrefixRef);
+ provide(dropdownInjectionKey, {
+ labelFieldRef: toRef(props, "labelField"),
+ childrenFieldRef: toRef(props, "childrenField"),
+ renderLabelRef: toRef(props, "renderLabel"),
+ renderIconRef: toRef(props, "renderIcon"),
+ hoverKeyRef,
+ keyboardKeyRef,
+ lastToggledSubmenuKeyRef,
+ pendingKeyPathRef,
+ activeKeyPathRef,
+ animatedRef: toRef(props, "animated"),
+ mergedShowRef,
+ nodePropsRef: toRef(props, "nodeProps"),
+ renderOptionRef: toRef(props, "renderOption"),
+ menuPropsRef: toRef(props, "menuProps"),
+ doSelect,
+ doUpdateShow
+ });
+ watch(mergedShowRef, (value) => {
+ if (!props.animated && !value) {
+ clearPendingState();
+ }
+ });
+ function doSelect(key, node) {
+ const {
+ onSelect
+ } = props;
+ if (onSelect) call(onSelect, key, node);
+ }
+ function doUpdateShow(value) {
+ const {
+ "onUpdate:show": _onUpdateShow,
+ onUpdateShow
+ } = props;
+ if (_onUpdateShow) call(_onUpdateShow, value);
+ if (onUpdateShow) call(onUpdateShow, value);
+ uncontrolledShowRef.value = value;
+ }
+ function clearPendingState() {
+ hoverKeyRef.value = null;
+ keyboardKeyRef.value = null;
+ lastToggledSubmenuKeyRef.value = null;
+ }
+ function handleKeydownEsc() {
+ doUpdateShow(false);
+ }
+ function handleKeydownLeft() {
+ handleKeydown("left");
+ }
+ function handleKeydownRight() {
+ handleKeydown("right");
+ }
+ function handleKeydownUp() {
+ handleKeydown("up");
+ }
+ function handleKeydownDown() {
+ handleKeydown("down");
+ }
+ function handleKeydownEnter() {
+ const pendingNode = getPendingNode();
+ if ((pendingNode === null || pendingNode === void 0 ? void 0 : pendingNode.isLeaf) && mergedShowRef.value) {
+ doSelect(pendingNode.key, pendingNode.rawNode);
+ doUpdateShow(false);
+ }
+ }
+ function getPendingNode() {
+ var _a;
+ const {
+ value: treeMate
+ } = treemateRef;
+ const {
+ value: pendingKey
+ } = pendingKeyRef;
+ if (!treeMate || pendingKey === null) return null;
+ return (_a = treeMate.getNode(pendingKey)) !== null && _a !== void 0 ? _a : null;
+ }
+ function handleKeydown(direction) {
+ const {
+ value: pendingKey
+ } = pendingKeyRef;
+ const {
+ value: {
+ getFirstAvailableNode: getFirstAvailableNode2
+ }
+ } = treemateRef;
+ let nextKeyboardKey = null;
+ if (pendingKey === null) {
+ const firstNode = getFirstAvailableNode2();
+ if (firstNode !== null) {
+ nextKeyboardKey = firstNode.key;
+ }
+ } else {
+ const currentNode = getPendingNode();
+ if (currentNode) {
+ let nextNode;
+ switch (direction) {
+ case "down":
+ nextNode = currentNode.getNext();
+ break;
+ case "up":
+ nextNode = currentNode.getPrev();
+ break;
+ case "right":
+ nextNode = currentNode.getChild();
+ break;
+ case "left":
+ nextNode = currentNode.getParent();
+ break;
+ }
+ if (nextNode) nextKeyboardKey = nextNode.key;
+ }
+ }
+ if (nextKeyboardKey !== null) {
+ hoverKeyRef.value = null;
+ keyboardKeyRef.value = nextKeyboardKey;
+ }
+ }
+ const cssVarsRef = computed(() => {
+ const {
+ size,
+ inverted
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self
+ } = themeRef.value;
+ const {
+ padding,
+ dividerColor,
+ borderRadius,
+ optionOpacityDisabled,
+ [createKey("optionIconSuffixWidth", size)]: optionIconSuffixWidth,
+ [createKey("optionSuffixWidth", size)]: optionSuffixWidth,
+ [createKey("optionIconPrefixWidth", size)]: optionIconPrefixWidth,
+ [createKey("optionPrefixWidth", size)]: optionPrefixWidth,
+ [createKey("fontSize", size)]: fontSize,
+ [createKey("optionHeight", size)]: optionHeight,
+ [createKey("optionIconSize", size)]: optionIconSize
+ } = self;
+ const vars = {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-font-size": fontSize,
+ "--n-padding": padding,
+ "--n-border-radius": borderRadius,
+ "--n-option-height": optionHeight,
+ "--n-option-prefix-width": optionPrefixWidth,
+ "--n-option-icon-prefix-width": optionIconPrefixWidth,
+ "--n-option-suffix-width": optionSuffixWidth,
+ "--n-option-icon-suffix-width": optionIconSuffixWidth,
+ "--n-option-icon-size": optionIconSize,
+ "--n-divider-color": dividerColor,
+ "--n-option-opacity-disabled": optionOpacityDisabled
+ };
+ if (inverted) {
+ vars["--n-color"] = self.colorInverted;
+ vars["--n-option-color-hover"] = self.optionColorHoverInverted;
+ vars["--n-option-color-active"] = self.optionColorActiveInverted;
+ vars["--n-option-text-color"] = self.optionTextColorInverted;
+ vars["--n-option-text-color-hover"] = self.optionTextColorHoverInverted;
+ vars["--n-option-text-color-active"] = self.optionTextColorActiveInverted;
+ vars["--n-option-text-color-child-active"] = self.optionTextColorChildActiveInverted;
+ vars["--n-prefix-color"] = self.prefixColorInverted;
+ vars["--n-suffix-color"] = self.suffixColorInverted;
+ vars["--n-group-header-text-color"] = self.groupHeaderTextColorInverted;
+ } else {
+ vars["--n-color"] = self.color;
+ vars["--n-option-color-hover"] = self.optionColorHover;
+ vars["--n-option-color-active"] = self.optionColorActive;
+ vars["--n-option-text-color"] = self.optionTextColor;
+ vars["--n-option-text-color-hover"] = self.optionTextColorHover;
+ vars["--n-option-text-color-active"] = self.optionTextColorActive;
+ vars["--n-option-text-color-child-active"] = self.optionTextColorChildActive;
+ vars["--n-prefix-color"] = self.prefixColor;
+ vars["--n-suffix-color"] = self.suffixColor;
+ vars["--n-group-header-text-color"] = self.groupHeaderTextColor;
+ }
+ return vars;
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("dropdown", computed(() => `${props.size[0]}${props.inverted ? "i" : ""}`), cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedTheme: themeRef,
+ // data
+ tmNodes: tmNodesRef,
+ // show
+ mergedShow: mergedShowRef,
+ // methods
+ handleAfterLeave: () => {
+ if (!props.animated) return;
+ clearPendingState();
+ },
+ doUpdateShow,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const renderPopoverBody = (className, ref2, style2, onMouseenter, onMouseleave) => {
+ var _a;
+ const {
+ mergedClsPrefix,
+ menuProps
+ } = this;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ const menuNodeProps = (menuProps === null || menuProps === void 0 ? void 0 : menuProps(void 0, this.tmNodes.map((v) => v.rawNode))) || {};
+ const dropdownProps2 = {
+ ref: createRefSetter(ref2),
+ class: [className, `${mergedClsPrefix}-dropdown`, this.themeClass],
+ clsPrefix: mergedClsPrefix,
+ tmNodes: this.tmNodes,
+ style: [...style2, this.cssVars],
+ showArrow: this.showArrow,
+ arrowStyle: this.arrowStyle,
+ scrollable: this.scrollable,
+ onMouseenter,
+ onMouseleave
+ };
+ return h(NDropdownMenu, mergeProps(this.$attrs, dropdownProps2, menuNodeProps));
+ };
+ const {
+ mergedTheme
+ } = this;
+ const popoverProps = {
+ show: this.mergedShow,
+ theme: mergedTheme.peers.Popover,
+ themeOverrides: mergedTheme.peerOverrides.Popover,
+ internalOnAfterLeave: this.handleAfterLeave,
+ internalRenderBody: renderPopoverBody,
+ onUpdateShow: this.doUpdateShow,
+ "onUpdate:show": void 0
+ };
+ return h(__unplugin_components_5, Object.assign({}, keep(this.$props, popoverPropKeys), popoverProps), {
+ trigger: () => {
+ var _a, _b;
+ return (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a);
+ }
+ });
+ }
+});
+const alipay = "" + new URL("alipay-CcfmUela.png", import.meta.url).href;
+const wechat = "" + new URL("wechat-DjfpYhZS.png", import.meta.url).href;
+const _hoisted_1$1 = { class: "relative inline-block" };
+const _hoisted_2$1 = { class: "p-6 rounded-lg shadow-lg bg-light dark:bg-gray-800" };
+const _hoisted_3$1 = { class: "flex gap-10" };
+const _hoisted_4$1 = { class: "flex flex-col items-center gap-2" };
+const _hoisted_5$1 = { class: "flex flex-col items-center gap-2" };
+const _sfc_main$1 = {
+ __name: "Coffee",
+ props: {
+ alipayQR: {
+ type: String,
+ required: true
+ },
+ wechatQR: {
+ type: String,
+ required: true
+ }
+ },
+ setup(__props) {
+ const message = useMessage();
+ const copyQQ = () => {
+ navigator.clipboard.writeText("789288579");
+ message.success("已复制到剪贴板");
+ };
+ return (_ctx, _cache) => {
+ return openBlock(), createElementBlock("div", _hoisted_1$1, [
+ createVNode(unref(__unplugin_components_5), {
+ trigger: "hover",
+ placement: "top",
+ "show-arrow": true,
+ raw: true,
+ delay: 100
+ }, {
+ trigger: withCtx(() => [
+ renderSlot(_ctx.$slots, "default", {}, () => [
+ createVNode(unref(Button), {
+ quaternary: "",
+ class: "inline-flex items-center gap-2 px-4 py-2 transition-all duration-300 hover:-translate-y-0.5"
+ }, {
+ default: withCtx(() => _cache[0] || (_cache[0] = [
+ createTextVNode(" 请我喝咖啡 ")
+ ])),
+ _: 1
+ })
+ ])
+ ]),
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_2$1, [
+ createBaseVNode("div", _hoisted_3$1, [
+ createBaseVNode("div", _hoisted_4$1, [
+ createVNode(unref(NImage), {
+ src: __props.alipayQR,
+ alt: "支付宝收款码",
+ class: "w-32 h-32 rounded-lg cursor-none",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ _cache[1] || (_cache[1] = createBaseVNode("span", { class: "text-sm text-gray-700 dark:text-gray-200" }, "支付宝", -1))
+ ]),
+ createBaseVNode("div", _hoisted_5$1, [
+ createVNode(unref(NImage), {
+ src: __props.wechatQR,
+ alt: "微信收款码",
+ class: "w-32 h-32 rounded-lg cursor-none",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ _cache[2] || (_cache[2] = createBaseVNode("span", { class: "text-sm text-gray-700 dark:text-gray-200" }, "微信支付", -1))
+ ])
+ ]),
+ createBaseVNode("div", { class: "mt-4" }, [
+ createBaseVNode("p", {
+ class: "text-sm text-gray-700 dark:text-gray-200 text-center cursor-pointer hover:text-green-500",
+ onClick: copyQQ
+ }, " QQ群:789288579 ")
+ ])
+ ])
+ ]),
+ _: 3
+ })
+ ]);
+ };
+ }
+};
+const USER_SET_OPTIONS = [
+ // {
+ // label: '打卡',
+ // key: 'card',
+ // },
+ // {
+ // label: '听歌升级',
+ // key: 'card_music',
+ // },
+ // {
+ // label: '歌曲次数',
+ // key: 'listen',
+ // },
+ {
+ label: "退出登录",
+ key: "logout"
+ },
+ {
+ label: "设置",
+ key: "set"
+ }
+];
+const SEARCH_TYPES = [
+ {
+ label: "单曲",
+ key: 1
+ },
+ {
+ label: "专辑",
+ key: 10
+ },
+ // {
+ // label: '歌手',
+ // key: 100,
+ // },
+ {
+ label: "歌单",
+ key: 1e3
+ },
+ // {
+ // label: '用户',
+ // key: 1002,
+ // },
+ {
+ label: "MV",
+ key: 1004
+ }
+ // {
+ // label: '歌词',
+ // key: 1006,
+ // },
+ // {
+ // label: '电台',
+ // key: 1009,
+ // },
+ // {
+ // label: '视频',
+ // key: 1014,
+ // },
+ // {
+ // label: '综合',
+ // key: 1018,
+ // },
+];
+const _hoisted_1 = { class: "search-box flex" };
+const _hoisted_2 = { class: "search-box-input flex-1" };
+const _hoisted_3 = { class: "w-20 px-3 flex justify-between items-center" };
+const _hoisted_4 = { class: "user-box" };
+const _hoisted_5 = { class: "user-popover" };
+const _hoisted_6 = { class: "username" };
+const _hoisted_7 = { class: "menu-items" };
+const _hoisted_8 = { class: "menu-item" };
+const _hoisted_9 = { class: "version-info" };
+const _hoisted_10 = { class: "version-number" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "SearchBar",
+ setup(__props) {
+ const router = useRouter();
+ const store = useStore();
+ const userSetOptions = ref(USER_SET_OPTIONS);
+ const hotSearchKeyword = ref("搜索点什么吧...");
+ const hotSearchValue = ref("");
+ const loadHotSearchKeyword = async () => {
+ const { data } = await getSearchKeyword();
+ hotSearchKeyword.value = data.data.showKeyword;
+ hotSearchValue.value = data.data.realkeyword;
+ };
+ const loadPage = async () => {
+ const token = localStorage.getItem("token");
+ if (!token) return;
+ const { data } = await getUserDetail();
+ store.state.user = data.profile;
+ localStorage.setItem("user", JSON.stringify(data.profile));
+ };
+ loadPage();
+ watchEffect(() => {
+ if (store.state.user) {
+ userSetOptions.value = USER_SET_OPTIONS;
+ } else {
+ userSetOptions.value = USER_SET_OPTIONS.filter((item) => item.key !== "logout");
+ }
+ });
+ const restartApp = () => {
+ window.electron.ipcRenderer.send("restart");
+ };
+ const toLogin = () => {
+ router.push("/login");
+ };
+ onMounted(() => {
+ loadHotSearchKeyword();
+ loadPage();
+ checkForUpdates();
+ });
+ const isDarkTheme = computed({
+ get: () => store.state.theme === "dark",
+ set: () => store.commit("toggleTheme")
+ });
+ const searchValue = ref("");
+ const search = () => {
+ const { value } = searchValue;
+ if (value === "") {
+ searchValue.value = hotSearchValue.value;
+ return;
+ }
+ if (router.currentRoute.value.path === "/search") {
+ store.state.searchValue = value;
+ return;
+ }
+ router.push({
+ path: "/search",
+ query: {
+ keyword: value
+ }
+ });
+ };
+ const selectSearchType = (key) => {
+ store.state.searchType = key;
+ };
+ const searchTypeOptions = ref(SEARCH_TYPES);
+ const selectItem = async (key) => {
+ switch (key) {
+ case "logout":
+ logout().then(() => {
+ store.state.user = null;
+ localStorage.clear();
+ router.push("/login");
+ });
+ break;
+ case "login":
+ router.push("/login");
+ break;
+ case "set":
+ router.push("/set");
+ break;
+ case "user":
+ router.push("/user");
+ break;
+ }
+ };
+ const toGithub = () => {
+ window.open("https://github.com/algerkong/AlgerMusicPlayer", "_blank");
+ };
+ const updateInfo = ref({
+ hasUpdate: false,
+ latestVersion: "",
+ currentVersion: config.version,
+ releaseInfo: null
+ });
+ const checkForUpdates = async () => {
+ try {
+ const result = await checkUpdate();
+ updateInfo.value = result;
+ } catch (error) {
+ console.error("检查更新失败:", error);
+ }
+ };
+ const toGithubRelease = () => {
+ if (updateInfo.value.hasUpdate) {
+ window.open("https://github.com/algerkong/AlgerMusicPlayer/releases/latest", "_blank");
+ } else {
+ window.open("https://github.com/algerkong/AlgerMusicPlayer/releases", "_blank");
+ }
+ };
+ return (_ctx, _cache) => {
+ const _component_n_dropdown = __unplugin_components_0;
+ const _component_n_input = __unplugin_components_1;
+ const _component_n_avatar = __unplugin_components_2;
+ const _component_n_switch = __unplugin_components_3;
+ const _component_n_tag = __unplugin_components_4;
+ const _component_n_popover = __unplugin_components_5;
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ createVNode(_component_n_input, {
+ value: searchValue.value,
+ "onUpdate:value": _cache[0] || (_cache[0] = ($event) => searchValue.value = $event),
+ size: "medium",
+ round: "",
+ placeholder: hotSearchKeyword.value,
+ class: "border dark:border-gray-600 border-gray-200",
+ onKeydown: withKeys(search, ["enter"])
+ }, {
+ prefix: withCtx(() => _cache[5] || (_cache[5] = [
+ createBaseVNode("i", { class: "iconfont icon-search" }, null, -1)
+ ])),
+ suffix: withCtx(() => [
+ createVNode(_component_n_dropdown, {
+ trigger: "hover",
+ options: searchTypeOptions.value,
+ onSelect: selectSearchType
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_3, [
+ createBaseVNode("div", null, toDisplayString(searchTypeOptions.value.find((item) => item.key === unref(store).state.searchType)?.label), 1),
+ _cache[6] || (_cache[6] = createBaseVNode("i", { class: "iconfont icon-xiasanjiaoxing" }, null, -1))
+ ])
+ ]),
+ _: 1
+ }, 8, ["options"])
+ ]),
+ _: 1
+ }, 8, ["value", "placeholder"])
+ ]),
+ createVNode(_component_n_popover, {
+ trigger: "hover",
+ placement: "bottom",
+ "show-arrow": false,
+ raw: ""
+ }, {
+ trigger: withCtx(() => [
+ createBaseVNode("div", _hoisted_4, [
+ unref(store).state.user ? (openBlock(), createBlock(_component_n_avatar, {
+ key: 0,
+ class: "cursor-pointer",
+ circle: "",
+ size: "medium",
+ src: unref(getImgUrl)(unref(store).state.user.avatarUrl),
+ onClick: _cache[1] || (_cache[1] = ($event) => selectItem("user"))
+ }, null, 8, ["src"])) : (openBlock(), createElementBlock("div", {
+ key: 1,
+ class: "mx-2 rounded-full cursor-pointer text-sm",
+ onClick: toLogin
+ }, "登录"))
+ ])
+ ]),
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_5, [
+ unref(store).state.user ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: "user-header",
+ onClick: _cache[2] || (_cache[2] = ($event) => selectItem("user"))
+ }, [
+ createVNode(_component_n_avatar, {
+ circle: "",
+ size: "small",
+ src: unref(getImgUrl)(unref(store).state.user?.avatarUrl)
+ }, null, 8, ["src"]),
+ createBaseVNode("span", _hoisted_6, toDisplayString(unref(store).state.user?.nickname || "Theodore"), 1)
+ ])) : createCommentVNode("", true),
+ createBaseVNode("div", _hoisted_7, [
+ !unref(store).state.user ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: "menu-item",
+ onClick: toLogin
+ }, _cache[7] || (_cache[7] = [
+ createBaseVNode("i", { class: "iconfont ri-login-box-line" }, null, -1),
+ createBaseVNode("span", null, "去登录", -1)
+ ]))) : createCommentVNode("", true),
+ createBaseVNode("div", {
+ class: "menu-item",
+ onClick: _cache[3] || (_cache[3] = ($event) => selectItem("set"))
+ }, _cache[8] || (_cache[8] = [
+ createBaseVNode("i", { class: "iconfont ri-settings-3-line" }, null, -1),
+ createBaseVNode("span", null, "设置", -1)
+ ])),
+ createBaseVNode("div", _hoisted_8, [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont", isDarkTheme.value ? "ri-moon-line" : "ri-sun-line"])
+ }, null, 2),
+ _cache[11] || (_cache[11] = createBaseVNode("span", null, "主题", -1)),
+ createVNode(_component_n_switch, {
+ value: isDarkTheme.value,
+ "onUpdate:value": _cache[4] || (_cache[4] = ($event) => isDarkTheme.value = $event),
+ class: "ml-auto"
+ }, {
+ checked: withCtx(() => _cache[9] || (_cache[9] = [
+ createBaseVNode("i", { class: "ri-moon-line" }, null, -1)
+ ])),
+ unchecked: withCtx(() => _cache[10] || (_cache[10] = [
+ createBaseVNode("i", { class: "ri-sun-line" }, null, -1)
+ ])),
+ _: 1
+ }, 8, ["value"])
+ ]),
+ createBaseVNode("div", {
+ class: "menu-item",
+ onClick: restartApp
+ }, _cache[12] || (_cache[12] = [
+ createBaseVNode("i", { class: "iconfont ri-restart-line" }, null, -1),
+ createBaseVNode("span", null, "重启", -1)
+ ])),
+ createBaseVNode("div", {
+ class: "menu-item",
+ onClick: toGithubRelease
+ }, [
+ _cache[13] || (_cache[13] = createBaseVNode("i", { class: "iconfont ri-refresh-line" }, null, -1)),
+ _cache[14] || (_cache[14] = createBaseVNode("span", null, "当前版本", -1)),
+ createBaseVNode("div", _hoisted_9, [
+ createBaseVNode("span", _hoisted_10, toDisplayString(updateInfo.value.currentVersion), 1),
+ updateInfo.value.hasUpdate ? (openBlock(), createBlock(_component_n_tag, {
+ key: 0,
+ type: "success",
+ size: "small",
+ class: "ml-1"
+ }, {
+ default: withCtx(() => [
+ createTextVNode(" New " + toDisplayString(updateInfo.value.latestVersion), 1)
+ ]),
+ _: 1
+ })) : createCommentVNode("", true)
+ ])
+ ])
+ ])
+ ])
+ ]),
+ _: 1
+ }),
+ createVNode(_sfc_main$1, {
+ "alipay-q-r": unref(alipay),
+ "wechat-q-r": unref(wechat)
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", {
+ class: "github",
+ onClick: toGithub
+ }, _cache[15] || (_cache[15] = [
+ createBaseVNode("i", { class: "ri-github-fill" }, null, -1)
+ ]))
+ ]),
+ _: 1
+ }, 8, ["alipay-q-r", "wechat-q-r"])
+ ]);
+ };
+ }
+});
+const SearchBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-064c45e9"]]);
+export {
+ SearchBar as default
+};
diff --git a/out/renderer/assets/SearchBar-Cx7zzS9t.js.gz b/out/renderer/assets/SearchBar-Cx7zzS9t.js.gz
new file mode 100644
index 0000000..2d44eb4
Binary files /dev/null and b/out/renderer/assets/SearchBar-Cx7zzS9t.js.gz differ
diff --git a/out/renderer/assets/Slider-BA6NituQ.js b/out/renderer/assets/Slider-BA6NituQ.js
new file mode 100644
index 0000000..487e189
--- /dev/null
+++ b/out/renderer/assets/Slider-BA6NituQ.js
@@ -0,0 +1,864 @@
+import { m as c, p as cB, W as cM, Y as cE, aM as fadeInScaleUpTransition, aN as insideModal, aO as insidePopover, aP as onBeforeUpdate, q as useTheme, d as defineComponent, x as useConfig, aQ as sliderLight, r as ref, z as useFormItem, G as computed, A as toRef, C as useMergedState, E as watch, a as onBeforeUnmount, ap as useThemeClass, aR as isMounted, l as h, K as resolveSlot, ak as Transition, L as call, J as on, aS as off, M as nextTick } from "./index-DKaFsuse.js";
+import { d as useAdjustedTo, B as Binder, V as VTarget, e as VFollower } from "./use-locale-DLWAOXez.js";
+const style = c([cB("slider", `
+ display: block;
+ padding: calc((var(--n-handle-size) - var(--n-rail-height)) / 2) 0;
+ position: relative;
+ z-index: 0;
+ width: 100%;
+ cursor: pointer;
+ user-select: none;
+ -webkit-user-select: none;
+ `, [cM("reverse", [cB("slider-handles", [cB("slider-handle-wrapper", `
+ transform: translate(50%, -50%);
+ `)]), cB("slider-dots", [cB("slider-dot", `
+ transform: translateX(50%, -50%);
+ `)]), cM("vertical", [cB("slider-handles", [cB("slider-handle-wrapper", `
+ transform: translate(-50%, -50%);
+ `)]), cB("slider-marks", [cB("slider-mark", `
+ transform: translateY(calc(-50% + var(--n-dot-height) / 2));
+ `)]), cB("slider-dots", [cB("slider-dot", `
+ transform: translateX(-50%) translateY(0);
+ `)])])]), cM("vertical", `
+ box-sizing: content-box;
+ padding: 0 calc((var(--n-handle-size) - var(--n-rail-height)) / 2);
+ width: var(--n-rail-width-vertical);
+ height: 100%;
+ `, [cB("slider-handles", `
+ top: calc(var(--n-handle-size) / 2);
+ right: 0;
+ bottom: calc(var(--n-handle-size) / 2);
+ left: 0;
+ `, [cB("slider-handle-wrapper", `
+ top: unset;
+ left: 50%;
+ transform: translate(-50%, 50%);
+ `)]), cB("slider-rail", `
+ height: 100%;
+ `, [cE("fill", `
+ top: unset;
+ right: 0;
+ bottom: unset;
+ left: 0;
+ `)]), cM("with-mark", `
+ width: var(--n-rail-width-vertical);
+ margin: 0 32px 0 8px;
+ `), cB("slider-marks", `
+ top: calc(var(--n-handle-size) / 2);
+ right: unset;
+ bottom: calc(var(--n-handle-size) / 2);
+ left: 22px;
+ font-size: var(--n-mark-font-size);
+ `, [cB("slider-mark", `
+ transform: translateY(50%);
+ white-space: nowrap;
+ `)]), cB("slider-dots", `
+ top: calc(var(--n-handle-size) / 2);
+ right: unset;
+ bottom: calc(var(--n-handle-size) / 2);
+ left: 50%;
+ `, [cB("slider-dot", `
+ transform: translateX(-50%) translateY(50%);
+ `)])]), cM("disabled", `
+ cursor: not-allowed;
+ opacity: var(--n-opacity-disabled);
+ `, [cB("slider-handle", `
+ cursor: not-allowed;
+ `)]), cM("with-mark", `
+ width: 100%;
+ margin: 8px 0 32px 0;
+ `), c("&:hover", [cB("slider-rail", {
+ backgroundColor: "var(--n-rail-color-hover)"
+}, [cE("fill", {
+ backgroundColor: "var(--n-fill-color-hover)"
+})]), cB("slider-handle", {
+ boxShadow: "var(--n-handle-box-shadow-hover)"
+})]), cM("active", [cB("slider-rail", {
+ backgroundColor: "var(--n-rail-color-hover)"
+}, [cE("fill", {
+ backgroundColor: "var(--n-fill-color-hover)"
+})]), cB("slider-handle", {
+ boxShadow: "var(--n-handle-box-shadow-hover)"
+})]), cB("slider-marks", `
+ position: absolute;
+ top: 18px;
+ left: calc(var(--n-handle-size) / 2);
+ right: calc(var(--n-handle-size) / 2);
+ `, [cB("slider-mark", `
+ position: absolute;
+ transform: translateX(-50%);
+ white-space: nowrap;
+ `)]), cB("slider-rail", `
+ width: 100%;
+ position: relative;
+ height: var(--n-rail-height);
+ background-color: var(--n-rail-color);
+ transition: background-color .3s var(--n-bezier);
+ border-radius: calc(var(--n-rail-height) / 2);
+ `, [cE("fill", `
+ position: absolute;
+ top: 0;
+ bottom: 0;
+ border-radius: calc(var(--n-rail-height) / 2);
+ transition: background-color .3s var(--n-bezier);
+ background-color: var(--n-fill-color);
+ `)]), cB("slider-handles", `
+ position: absolute;
+ top: 0;
+ right: calc(var(--n-handle-size) / 2);
+ bottom: 0;
+ left: calc(var(--n-handle-size) / 2);
+ `, [cB("slider-handle-wrapper", `
+ outline: none;
+ position: absolute;
+ top: 50%;
+ transform: translate(-50%, -50%);
+ cursor: pointer;
+ display: flex;
+ `, [cB("slider-handle", `
+ height: var(--n-handle-size);
+ width: var(--n-handle-size);
+ border-radius: 50%;
+ overflow: hidden;
+ transition: box-shadow .2s var(--n-bezier), background-color .3s var(--n-bezier);
+ background-color: var(--n-handle-color);
+ box-shadow: var(--n-handle-box-shadow);
+ `, [c("&:hover", `
+ box-shadow: var(--n-handle-box-shadow-hover);
+ `)]), c("&:focus", [cB("slider-handle", `
+ box-shadow: var(--n-handle-box-shadow-focus);
+ `, [c("&:hover", `
+ box-shadow: var(--n-handle-box-shadow-active);
+ `)])])])]), cB("slider-dots", `
+ position: absolute;
+ top: 50%;
+ left: calc(var(--n-handle-size) / 2);
+ right: calc(var(--n-handle-size) / 2);
+ `, [cM("transition-disabled", [cB("slider-dot", "transition: none;")]), cB("slider-dot", `
+ transition:
+ border-color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier);
+ position: absolute;
+ transform: translate(-50%, -50%);
+ height: var(--n-dot-height);
+ width: var(--n-dot-width);
+ border-radius: var(--n-dot-border-radius);
+ overflow: hidden;
+ box-sizing: border-box;
+ border: var(--n-dot-border);
+ background-color: var(--n-dot-color);
+ `, [cM("active", "border: var(--n-dot-border-active);")])])]), cB("slider-handle-indicator", `
+ font-size: var(--n-font-size);
+ padding: 6px 10px;
+ border-radius: var(--n-indicator-border-radius);
+ color: var(--n-indicator-text-color);
+ background-color: var(--n-indicator-color);
+ box-shadow: var(--n-indicator-box-shadow);
+ `, [fadeInScaleUpTransition()]), cB("slider-handle-indicator", `
+ font-size: var(--n-font-size);
+ padding: 6px 10px;
+ border-radius: var(--n-indicator-border-radius);
+ color: var(--n-indicator-text-color);
+ background-color: var(--n-indicator-color);
+ box-shadow: var(--n-indicator-box-shadow);
+ `, [cM("top", `
+ margin-bottom: 12px;
+ `), cM("right", `
+ margin-left: 12px;
+ `), cM("bottom", `
+ margin-top: 12px;
+ `), cM("left", `
+ margin-right: 12px;
+ `), fadeInScaleUpTransition()]), insideModal(cB("slider", [cB("slider-dot", "background-color: var(--n-dot-color-modal);")])), insidePopover(cB("slider", [cB("slider-dot", "background-color: var(--n-dot-color-popover);")]))]);
+function isTouchEvent(e) {
+ return window.TouchEvent && e instanceof window.TouchEvent;
+}
+function useRefs() {
+ const refs = /* @__PURE__ */ new Map();
+ const setRefs = (index) => (el) => {
+ refs.set(index, el);
+ };
+ onBeforeUpdate(() => {
+ refs.clear();
+ });
+ return [refs, setRefs];
+}
+const eventButtonLeft = 0;
+const sliderProps = Object.assign(Object.assign({}, useTheme.props), {
+ to: useAdjustedTo.propTo,
+ defaultValue: {
+ type: [Number, Array],
+ default: 0
+ },
+ marks: Object,
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ formatTooltip: Function,
+ keyboard: {
+ type: Boolean,
+ default: true
+ },
+ min: {
+ type: Number,
+ default: 0
+ },
+ max: {
+ type: Number,
+ default: 100
+ },
+ step: {
+ type: [Number, String],
+ default: 1
+ },
+ range: Boolean,
+ value: [Number, Array],
+ placement: String,
+ showTooltip: {
+ type: Boolean,
+ default: void 0
+ },
+ tooltip: {
+ type: Boolean,
+ default: true
+ },
+ vertical: Boolean,
+ reverse: Boolean,
+ "onUpdate:value": [Function, Array],
+ onUpdateValue: [Function, Array],
+ onDragstart: [Function],
+ onDragend: [Function]
+});
+const __unplugin_components_0 = defineComponent({
+ name: "Slider",
+ props: sliderProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ namespaceRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Slider", "-slider", style, sliderLight, props, mergedClsPrefixRef);
+ const handleRailRef = ref(null);
+ const [handleRefs, setHandleRefs] = useRefs();
+ const [followerRefs, setFollowerRefs] = useRefs();
+ const followerEnabledIndexSetRef = ref(/* @__PURE__ */ new Set());
+ const formItem = useFormItem(props);
+ const {
+ mergedDisabledRef
+ } = formItem;
+ const precisionRef = computed(() => {
+ const {
+ step
+ } = props;
+ if (Number(step) <= 0 || step === "mark") return 0;
+ const stepString = step.toString();
+ let precision = 0;
+ if (stepString.includes(".")) {
+ precision = stepString.length - stepString.indexOf(".") - 1;
+ }
+ return precision;
+ });
+ const uncontrolledValueRef = ref(props.defaultValue);
+ const controlledValueRef = toRef(props, "value");
+ const mergedValueRef = useMergedState(controlledValueRef, uncontrolledValueRef);
+ const arrifiedValueRef = computed(() => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ return (props.range ? mergedValue : [mergedValue]).map(clampValue);
+ });
+ const handleCountExceeds2Ref = computed(() => arrifiedValueRef.value.length > 2);
+ const mergedPlacementRef = computed(() => {
+ return props.placement === void 0 ? props.vertical ? "right" : "top" : props.placement;
+ });
+ const markValuesRef = computed(() => {
+ const {
+ marks
+ } = props;
+ return marks ? Object.keys(marks).map(Number.parseFloat) : null;
+ });
+ const activeIndexRef = ref(-1);
+ const previousIndexRef = ref(-1);
+ const hoverIndexRef = ref(-1);
+ const draggingRef = ref(false);
+ const dotTransitionDisabledRef = ref(false);
+ const styleDirectionRef = computed(() => {
+ const {
+ vertical,
+ reverse
+ } = props;
+ const left = reverse ? "right" : "left";
+ const bottom = reverse ? "top" : "bottom";
+ return vertical ? bottom : left;
+ });
+ const fillStyleRef = computed(() => {
+ if (handleCountExceeds2Ref.value) return;
+ const values = arrifiedValueRef.value;
+ const start = valueToPercentage(props.range ? Math.min(...values) : props.min);
+ const end = valueToPercentage(props.range ? Math.max(...values) : values[0]);
+ const {
+ value: styleDirection
+ } = styleDirectionRef;
+ return props.vertical ? {
+ [styleDirection]: `${start}%`,
+ height: `${end - start}%`
+ } : {
+ [styleDirection]: `${start}%`,
+ width: `${end - start}%`
+ };
+ });
+ const markInfosRef = computed(() => {
+ const mergedMarks = [];
+ const {
+ marks
+ } = props;
+ if (marks) {
+ const orderValues = arrifiedValueRef.value.slice();
+ orderValues.sort((a, b) => a - b);
+ const {
+ value: styleDirection
+ } = styleDirectionRef;
+ const {
+ value: handleCountExceeds2
+ } = handleCountExceeds2Ref;
+ const {
+ range
+ } = props;
+ const isActive = handleCountExceeds2 ? () => false : (num) => range ? num >= orderValues[0] && num <= orderValues[orderValues.length - 1] : num <= orderValues[0];
+ for (const key of Object.keys(marks)) {
+ const num = Number(key);
+ mergedMarks.push({
+ active: isActive(num),
+ key: num,
+ label: marks[key],
+ style: {
+ [styleDirection]: `${valueToPercentage(num)}%`
+ }
+ });
+ }
+ }
+ return mergedMarks;
+ });
+ function getHandleStyle(value, index) {
+ const percentage = valueToPercentage(value);
+ const {
+ value: styleDirection
+ } = styleDirectionRef;
+ return {
+ [styleDirection]: `${percentage}%`,
+ zIndex: index === activeIndexRef.value ? 1 : 0
+ };
+ }
+ function isShowTooltip(index) {
+ return props.showTooltip || hoverIndexRef.value === index || activeIndexRef.value === index && draggingRef.value;
+ }
+ function shouldKeepTooltipTransition(index) {
+ if (!draggingRef.value) return true;
+ return !(activeIndexRef.value === index && previousIndexRef.value === index);
+ }
+ function focusActiveHandle(index) {
+ var _a;
+ if (~index) {
+ activeIndexRef.value = index;
+ (_a = handleRefs.get(index)) === null || _a === void 0 ? void 0 : _a.focus();
+ }
+ }
+ function syncPosition() {
+ followerRefs.forEach((inst, index) => {
+ if (isShowTooltip(index)) inst.syncPosition();
+ });
+ }
+ function doUpdateValue(value) {
+ const {
+ "onUpdate:value": _onUpdateValue,
+ onUpdateValue
+ } = props;
+ const {
+ nTriggerFormInput,
+ nTriggerFormChange
+ } = formItem;
+ if (onUpdateValue) call(onUpdateValue, value);
+ if (_onUpdateValue) call(_onUpdateValue, value);
+ uncontrolledValueRef.value = value;
+ nTriggerFormInput();
+ nTriggerFormChange();
+ }
+ function dispatchValueUpdate(value) {
+ const {
+ range
+ } = props;
+ if (range) {
+ if (Array.isArray(value)) {
+ const {
+ value: oldValues
+ } = arrifiedValueRef;
+ if (value.join() !== oldValues.join()) {
+ doUpdateValue(value);
+ }
+ }
+ } else if (!Array.isArray(value)) {
+ const oldValue = arrifiedValueRef.value[0];
+ if (oldValue !== value) {
+ doUpdateValue(value);
+ }
+ }
+ }
+ function doDispatchValue(value, index) {
+ if (props.range) {
+ const values = arrifiedValueRef.value.slice();
+ values.splice(index, 1, value);
+ dispatchValueUpdate(values);
+ } else {
+ dispatchValueUpdate(value);
+ }
+ }
+ function sanitizeValue(value, currentValue, stepBuffer) {
+ const stepping = stepBuffer !== void 0;
+ if (!stepBuffer) {
+ stepBuffer = value - currentValue > 0 ? 1 : -1;
+ }
+ const markValues = markValuesRef.value || [];
+ const {
+ step
+ } = props;
+ if (step === "mark") {
+ const closestMark2 = getClosestMark(value, markValues.concat(currentValue), stepping ? stepBuffer : void 0);
+ return closestMark2 ? closestMark2.value : currentValue;
+ }
+ if (step <= 0) return currentValue;
+ const {
+ value: precision
+ } = precisionRef;
+ let closestMark;
+ if (stepping) {
+ const currentStep = Number((currentValue / step).toFixed(precision));
+ const actualStep = Math.floor(currentStep);
+ const leftStep = currentStep > actualStep ? actualStep : actualStep - 1;
+ const rightStep = currentStep < actualStep ? actualStep : actualStep + 1;
+ closestMark = getClosestMark(currentValue, [Number((leftStep * step).toFixed(precision)), Number((rightStep * step).toFixed(precision)), ...markValues], stepBuffer);
+ } else {
+ const roundValue = getRoundValue(value);
+ closestMark = getClosestMark(value, [...markValues, roundValue]);
+ }
+ return closestMark ? clampValue(closestMark.value) : currentValue;
+ }
+ function clampValue(value) {
+ return Math.min(props.max, Math.max(props.min, value));
+ }
+ function valueToPercentage(value) {
+ const {
+ max,
+ min
+ } = props;
+ return (value - min) / (max - min) * 100;
+ }
+ function percentageToValue(percentage) {
+ const {
+ max,
+ min
+ } = props;
+ return min + (max - min) * percentage;
+ }
+ function getRoundValue(value) {
+ const {
+ step,
+ min
+ } = props;
+ if (Number(step) <= 0 || step === "mark") return value;
+ const newValue = Math.round((value - min) / step) * step + min;
+ return Number(newValue.toFixed(precisionRef.value));
+ }
+ function getClosestMark(currentValue, markValues = markValuesRef.value, buffer) {
+ if (!(markValues === null || markValues === void 0 ? void 0 : markValues.length)) return null;
+ let closestMark = null;
+ let index = -1;
+ while (++index < markValues.length) {
+ const diff = markValues[index] - currentValue;
+ const distance = Math.abs(diff);
+ if (
+ // find marks in the same direction
+ (buffer === void 0 || diff * buffer > 0) && (closestMark === null || distance < closestMark.distance)
+ ) {
+ closestMark = {
+ index,
+ distance,
+ value: markValues[index]
+ };
+ }
+ }
+ return closestMark;
+ }
+ function getPointValue(event) {
+ const railEl = handleRailRef.value;
+ if (!railEl) return;
+ const touchEvent = isTouchEvent(event) ? event.touches[0] : event;
+ const railRect = railEl.getBoundingClientRect();
+ let percentage;
+ if (props.vertical) {
+ percentage = (railRect.bottom - touchEvent.clientY) / railRect.height;
+ } else {
+ percentage = (touchEvent.clientX - railRect.left) / railRect.width;
+ }
+ if (props.reverse) {
+ percentage = 1 - percentage;
+ }
+ return percentageToValue(percentage);
+ }
+ function handleRailKeyDown(e) {
+ if (mergedDisabledRef.value || !props.keyboard) return;
+ const {
+ vertical,
+ reverse
+ } = props;
+ switch (e.key) {
+ case "ArrowUp":
+ e.preventDefault();
+ handleStepValue(vertical && reverse ? -1 : 1);
+ break;
+ case "ArrowRight":
+ e.preventDefault();
+ handleStepValue(!vertical && reverse ? -1 : 1);
+ break;
+ case "ArrowDown":
+ e.preventDefault();
+ handleStepValue(vertical && reverse ? 1 : -1);
+ break;
+ case "ArrowLeft":
+ e.preventDefault();
+ handleStepValue(!vertical && reverse ? 1 : -1);
+ break;
+ }
+ }
+ function handleStepValue(ratio) {
+ const activeIndex = activeIndexRef.value;
+ if (activeIndex === -1) return;
+ const {
+ step
+ } = props;
+ const currentValue = arrifiedValueRef.value[activeIndex];
+ const nextValue = Number(step) <= 0 || step === "mark" ? currentValue : currentValue + step * ratio;
+ doDispatchValue(
+ // Avoid the number of value does not change when `step` is null
+ sanitizeValue(nextValue, currentValue, ratio > 0 ? 1 : -1),
+ activeIndex
+ );
+ }
+ function handleRailMouseDown(event) {
+ var _a, _b;
+ if (mergedDisabledRef.value) return;
+ if (!isTouchEvent(event) && event.button !== eventButtonLeft) {
+ return;
+ }
+ const pointValue = getPointValue(event);
+ if (pointValue === void 0) return;
+ const values = arrifiedValueRef.value.slice();
+ const activeIndex = props.range ? (_b = (_a = getClosestMark(pointValue, values)) === null || _a === void 0 ? void 0 : _a.index) !== null && _b !== void 0 ? _b : -1 : 0;
+ if (activeIndex !== -1) {
+ event.preventDefault();
+ focusActiveHandle(activeIndex);
+ startDragging();
+ doDispatchValue(sanitizeValue(pointValue, arrifiedValueRef.value[activeIndex]), activeIndex);
+ }
+ }
+ function startDragging() {
+ if (!draggingRef.value) {
+ draggingRef.value = true;
+ if (props.onDragstart) call(props.onDragstart);
+ on("touchend", document, handleMouseUp);
+ on("mouseup", document, handleMouseUp);
+ on("touchmove", document, handleMouseMove);
+ on("mousemove", document, handleMouseMove);
+ }
+ }
+ function stopDragging() {
+ if (draggingRef.value) {
+ draggingRef.value = false;
+ if (props.onDragend) call(props.onDragend);
+ off("touchend", document, handleMouseUp);
+ off("mouseup", document, handleMouseUp);
+ off("touchmove", document, handleMouseMove);
+ off("mousemove", document, handleMouseMove);
+ }
+ }
+ function handleMouseMove(event) {
+ const {
+ value: activeIndex
+ } = activeIndexRef;
+ if (!draggingRef.value || activeIndex === -1) {
+ stopDragging();
+ return;
+ }
+ const pointValue = getPointValue(event);
+ if (pointValue === void 0) return;
+ doDispatchValue(sanitizeValue(pointValue, arrifiedValueRef.value[activeIndex]), activeIndex);
+ }
+ function handleMouseUp() {
+ stopDragging();
+ }
+ function handleHandleFocus(index) {
+ activeIndexRef.value = index;
+ if (!mergedDisabledRef.value) {
+ hoverIndexRef.value = index;
+ }
+ }
+ function handleHandleBlur(index) {
+ if (activeIndexRef.value === index) {
+ activeIndexRef.value = -1;
+ stopDragging();
+ }
+ if (hoverIndexRef.value === index) {
+ hoverIndexRef.value = -1;
+ }
+ }
+ function handleHandleMouseEnter(index) {
+ hoverIndexRef.value = index;
+ }
+ function handleHandleMouseLeave(index) {
+ if (hoverIndexRef.value === index) {
+ hoverIndexRef.value = -1;
+ }
+ }
+ watch(activeIndexRef, (_, previous) => void nextTick(() => previousIndexRef.value = previous));
+ watch(mergedValueRef, () => {
+ if (props.marks) {
+ if (dotTransitionDisabledRef.value) return;
+ dotTransitionDisabledRef.value = true;
+ void nextTick(() => {
+ dotTransitionDisabledRef.value = false;
+ });
+ }
+ void nextTick(syncPosition);
+ });
+ onBeforeUnmount(() => {
+ stopDragging();
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ self: {
+ markFontSize,
+ railColor,
+ railColorHover,
+ fillColor,
+ fillColorHover,
+ handleColor,
+ opacityDisabled,
+ dotColor,
+ dotColorModal,
+ handleBoxShadow,
+ handleBoxShadowHover,
+ handleBoxShadowActive,
+ handleBoxShadowFocus,
+ dotBorder,
+ dotBoxShadow,
+ railHeight,
+ railWidthVertical,
+ handleSize,
+ dotHeight,
+ dotWidth,
+ dotBorderRadius,
+ fontSize,
+ dotBorderActive,
+ dotColorPopover
+ },
+ common: {
+ cubicBezierEaseInOut
+ }
+ } = themeRef.value;
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-dot-border": dotBorder,
+ "--n-dot-border-active": dotBorderActive,
+ "--n-dot-border-radius": dotBorderRadius,
+ "--n-dot-box-shadow": dotBoxShadow,
+ "--n-dot-color": dotColor,
+ "--n-dot-color-modal": dotColorModal,
+ "--n-dot-color-popover": dotColorPopover,
+ "--n-dot-height": dotHeight,
+ "--n-dot-width": dotWidth,
+ "--n-fill-color": fillColor,
+ "--n-fill-color-hover": fillColorHover,
+ "--n-font-size": fontSize,
+ "--n-handle-box-shadow": handleBoxShadow,
+ "--n-handle-box-shadow-active": handleBoxShadowActive,
+ "--n-handle-box-shadow-focus": handleBoxShadowFocus,
+ "--n-handle-box-shadow-hover": handleBoxShadowHover,
+ "--n-handle-color": handleColor,
+ "--n-handle-size": handleSize,
+ "--n-opacity-disabled": opacityDisabled,
+ "--n-rail-color": railColor,
+ "--n-rail-color-hover": railColorHover,
+ "--n-rail-height": railHeight,
+ "--n-rail-width-vertical": railWidthVertical,
+ "--n-mark-font-size": markFontSize
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("slider", void 0, cssVarsRef, props) : void 0;
+ const indicatorCssVarsRef = computed(() => {
+ const {
+ self: {
+ fontSize,
+ indicatorColor,
+ indicatorBoxShadow,
+ indicatorTextColor,
+ indicatorBorderRadius
+ }
+ } = themeRef.value;
+ return {
+ "--n-font-size": fontSize,
+ "--n-indicator-border-radius": indicatorBorderRadius,
+ "--n-indicator-box-shadow": indicatorBoxShadow,
+ "--n-indicator-color": indicatorColor,
+ "--n-indicator-text-color": indicatorTextColor
+ };
+ });
+ const indicatorThemeClassHandle = inlineThemeDisabled ? useThemeClass("slider-indicator", void 0, indicatorCssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ namespace: namespaceRef,
+ uncontrolledValue: uncontrolledValueRef,
+ mergedValue: mergedValueRef,
+ mergedDisabled: mergedDisabledRef,
+ mergedPlacement: mergedPlacementRef,
+ isMounted: isMounted(),
+ adjustedTo: useAdjustedTo(props),
+ dotTransitionDisabled: dotTransitionDisabledRef,
+ markInfos: markInfosRef,
+ isShowTooltip,
+ shouldKeepTooltipTransition,
+ handleRailRef,
+ setHandleRefs,
+ setFollowerRefs,
+ fillStyle: fillStyleRef,
+ getHandleStyle,
+ activeIndex: activeIndexRef,
+ arrifiedValues: arrifiedValueRef,
+ followerEnabledIndexSet: followerEnabledIndexSetRef,
+ handleRailMouseDown,
+ handleHandleFocus,
+ handleHandleBlur,
+ handleHandleMouseEnter,
+ handleHandleMouseLeave,
+ handleRailKeyDown,
+ indicatorCssVars: inlineThemeDisabled ? void 0 : indicatorCssVarsRef,
+ indicatorThemeClass: indicatorThemeClassHandle === null || indicatorThemeClassHandle === void 0 ? void 0 : indicatorThemeClassHandle.themeClass,
+ indicatorOnRender: indicatorThemeClassHandle === null || indicatorThemeClassHandle === void 0 ? void 0 : indicatorThemeClassHandle.onRender,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ var _a;
+ const {
+ mergedClsPrefix,
+ themeClass,
+ formatTooltip
+ } = this;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ return h("div", {
+ class: [`${mergedClsPrefix}-slider`, themeClass, {
+ [`${mergedClsPrefix}-slider--disabled`]: this.mergedDisabled,
+ [`${mergedClsPrefix}-slider--active`]: this.activeIndex !== -1,
+ [`${mergedClsPrefix}-slider--with-mark`]: this.marks,
+ [`${mergedClsPrefix}-slider--vertical`]: this.vertical,
+ [`${mergedClsPrefix}-slider--reverse`]: this.reverse
+ }],
+ style: this.cssVars,
+ onKeydown: this.handleRailKeyDown,
+ onMousedown: this.handleRailMouseDown,
+ onTouchstart: this.handleRailMouseDown
+ }, h("div", {
+ class: `${mergedClsPrefix}-slider-rail`
+ }, h("div", {
+ class: `${mergedClsPrefix}-slider-rail__fill`,
+ style: this.fillStyle
+ }), this.marks ? h("div", {
+ class: [`${mergedClsPrefix}-slider-dots`, this.dotTransitionDisabled && `${mergedClsPrefix}-slider-dots--transition-disabled`]
+ }, this.markInfos.map((mark) => h("div", {
+ key: mark.key,
+ class: [`${mergedClsPrefix}-slider-dot`, {
+ [`${mergedClsPrefix}-slider-dot--active`]: mark.active
+ }],
+ style: mark.style
+ }))) : null, h("div", {
+ ref: "handleRailRef",
+ class: `${mergedClsPrefix}-slider-handles`
+ }, this.arrifiedValues.map((value, index) => {
+ const showTooltip = this.isShowTooltip(index);
+ return h(Binder, null, {
+ default: () => [h(VTarget, null, {
+ default: () => h("div", {
+ ref: this.setHandleRefs(index),
+ class: `${mergedClsPrefix}-slider-handle-wrapper`,
+ tabindex: this.mergedDisabled ? -1 : 0,
+ role: "slider",
+ "aria-valuenow": value,
+ "aria-valuemin": this.min,
+ "aria-valuemax": this.max,
+ "aria-orientation": this.vertical ? "vertical" : "horizontal",
+ "aria-disabled": this.disabled,
+ style: this.getHandleStyle(value, index),
+ onFocus: () => {
+ this.handleHandleFocus(index);
+ },
+ onBlur: () => {
+ this.handleHandleBlur(index);
+ },
+ onMouseenter: () => {
+ this.handleHandleMouseEnter(index);
+ },
+ onMouseleave: () => {
+ this.handleHandleMouseLeave(index);
+ }
+ }, resolveSlot(this.$slots.thumb, () => [h("div", {
+ class: `${mergedClsPrefix}-slider-handle`
+ })]))
+ }), this.tooltip && h(VFollower, {
+ ref: this.setFollowerRefs(index),
+ show: showTooltip,
+ to: this.adjustedTo,
+ enabled: this.showTooltip && !this.range || this.followerEnabledIndexSet.has(index),
+ teleportDisabled: this.adjustedTo === useAdjustedTo.tdkey,
+ placement: this.mergedPlacement,
+ containerClass: this.namespace
+ }, {
+ default: () => h(Transition, {
+ name: "fade-in-scale-up-transition",
+ appear: this.isMounted,
+ css: this.shouldKeepTooltipTransition(index),
+ onEnter: () => {
+ this.followerEnabledIndexSet.add(index);
+ },
+ onAfterLeave: () => {
+ this.followerEnabledIndexSet.delete(index);
+ }
+ }, {
+ default: () => {
+ var _a2;
+ if (showTooltip) {
+ (_a2 = this.indicatorOnRender) === null || _a2 === void 0 ? void 0 : _a2.call(this);
+ return h("div", {
+ class: [`${mergedClsPrefix}-slider-handle-indicator`, this.indicatorThemeClass, `${mergedClsPrefix}-slider-handle-indicator--${this.mergedPlacement}`],
+ style: this.indicatorCssVars
+ }, typeof formatTooltip === "function" ? formatTooltip(value) : value);
+ }
+ return null;
+ }
+ })
+ })]
+ });
+ })), this.marks ? h("div", {
+ class: `${mergedClsPrefix}-slider-marks`
+ }, this.markInfos.map((mark) => h("div", {
+ key: mark.key,
+ class: `${mergedClsPrefix}-slider-mark`,
+ style: mark.style
+ }, typeof mark.label === "function" ? mark.label() : mark.label))) : null));
+ }
+});
+export {
+ __unplugin_components_0 as _
+};
diff --git a/out/renderer/assets/Slider-BA6NituQ.js.gz b/out/renderer/assets/Slider-BA6NituQ.js.gz
new file mode 100644
index 0000000..56da44e
Binary files /dev/null and b/out/renderer/assets/Slider-BA6NituQ.js.gz differ
diff --git a/out/renderer/assets/SongItem-Bw5Qa7XV.css b/out/renderer/assets/SongItem-Bw5Qa7XV.css
new file mode 100644
index 0000000..8895831
--- /dev/null
+++ b/out/renderer/assets/SongItem-Bw5Qa7XV.css
@@ -0,0 +1,296 @@
+.text-ellipsis[data-v-aae6c67f] {
+ width: 100%;
+}
+.song-item[data-v-aae6c67f] {
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+ display: flex;
+ align-items: center;
+ border-radius: 1.5rem;
+ background-color: transparent;
+ padding: 0.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.song-item[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.song-item[data-v-aae6c67f]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+.song-item[data-v-aae6c67f]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.song-item-img[data-v-aae6c67f] {
+ margin-right: 1rem;
+ height: 3rem;
+ width: 3rem;
+ border-radius: 1rem;
+}
+.song-item-content[data-v-aae6c67f] {
+ flex: 1 1 0%;
+}
+.song-item-content-title[data-v-aae6c67f] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.song-item-content-title[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.song-item-content-name[data-v-aae6c67f] {
+ font-size: 0.75rem;
+ line-height: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.song-item-content-name[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.song-item-operating[data-v-aae6c67f] {
+ margin-left: 1rem;
+ display: flex;
+ align-items: center;
+ border-radius: 9999px;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.song-item-operating[data-v-aae6c67f]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.song-item-operating .iconfont[data-v-aae6c67f] {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+}
+.song-item-operating .icon-likefill[data-v-aae6c67f] {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.song-item-operating .icon-likefill[data-v-aae6c67f]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1));
+}
+.song-item-operating .icon-likefill[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.song-item-operating-like[data-v-aae6c67f] {
+ margin-right: 0.5rem;
+ margin-left: 1rem;
+ cursor: pointer;
+}
+.song-item-operating .like-active[data-v-aae6c67f] {
+ --tw-text-opacity: 1;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1));
+}
+.song-item-operating-play[data-v-aae6c67f] {
+ display: flex;
+ height: 2.5rem;
+ width: 2.5rem;
+ cursor: pointer;
+ align-items: center;
+ justify-content: center;
+ border-radius: 9999px;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.song-item-operating-play[data-v-aae6c67f]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.song-item-operating-play[data-v-aae6c67f]:hover, .song-item-operating-play.bg-green-600[data-v-aae6c67f] {
+ --tw-border-opacity: 1;
+ border-color: rgb(34 197 94 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.song-mini[data-v-aae6c67f] {
+ border-radius: 1rem;
+ padding: 0.5rem;
+}
+.song-mini .song-item[data-v-aae6c67f] {
+ padding: 0px;
+}
+.song-mini .song-item-img[data-v-aae6c67f] {
+ margin-right: 0.5rem;
+ height: 2.5rem;
+ width: 2.5rem;
+}
+.song-mini .song-item-content[data-v-aae6c67f] {
+ flex: 1 1 0%;
+}
+.song-mini .song-item-content-title[data-v-aae6c67f] {
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+}
+.song-mini .song-item-content-name[data-v-aae6c67f] {
+ font-size: 0.75rem;
+ line-height: 1rem;
+}
+.song-mini .song-item-operating[data-v-aae6c67f] {
+ padding-left: 0.5rem;
+}
+.song-mini .song-item-operating .iconfont[data-v-aae6c67f] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+}
+.song-mini .song-item-operating-like[data-v-aae6c67f] {
+ margin-right: 0.25rem;
+ margin-left: 0.25rem;
+}
+.song-mini .song-item-operating-play[data-v-aae6c67f] {
+ height: 2rem;
+ width: 2rem;
+}
+.song-list[data-v-aae6c67f] {
+ margin-bottom: 0.5rem;
+ border-radius: 0.5rem;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ padding: 0.5rem;
+}
+.song-list[data-v-aae6c67f]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(31 41 55 / var(--tw-border-opacity, 1));
+}
+.song-list[data-v-aae6c67f]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1));
+}
+.song-list[data-v-aae6c67f]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.song-list .song-item-img[data-v-aae6c67f] {
+ margin-right: 0.75rem;
+ height: 2.5rem;
+ width: 2.5rem;
+ border-radius: 0.5rem;
+}
+.song-list .song-item-content[data-v-aae6c67f] {
+ display: flex;
+ flex: 1 1 0%;
+ align-items: center;
+}
+.song-list .song-item-content-wrapper[data-v-aae6c67f] {
+ display: flex;
+ flex: 1 1 0%;
+ align-items: center;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+}
+.song-list .song-item-content-title[data-v-aae6c67f] {
+ max-width: 45%;
+ flex-shrink: 0;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-content-title[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-content-divider[data-v-aae6c67f] {
+ margin-left: 0.5rem;
+ margin-right: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-content-divider[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-content-name[data-v-aae6c67f] {
+ min-width: 0px;
+ flex: 1 1 0%;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-content-name[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-operating[data-v-aae6c67f] {
+ display: flex;
+ align-items: center;
+ gap: 0.5rem;
+}
+.song-list .song-item-operating-like[data-v-aae6c67f] {
+ cursor: pointer;
+ transition-property: transform;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.song-list .song-item-operating-like[data-v-aae6c67f]:hover {
+ --tw-scale-x: 1.1;
+ --tw-scale-y: 1.1;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+.song-list .song-item-operating-like .iconfont[data-v-aae6c67f] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-operating-like .iconfont[data-v-aae6c67f]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-operating-like .iconfont[data-v-aae6c67f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.song-list .song-item-operating-play[data-v-aae6c67f] {
+ height: 1.75rem;
+ width: 1.75rem;
+ cursor: pointer;
+ transition-property: transform;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.song-list .song-item-operating-play[data-v-aae6c67f]:hover {
+ --tw-scale-x: 1.1;
+ --tw-scale-y: 1.1;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+.song-list .song-item-operating-play .iconfont[data-v-aae6c67f] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/SongItem-Bw5Qa7XV.css.gz b/out/renderer/assets/SongItem-Bw5Qa7XV.css.gz
new file mode 100644
index 0000000..5304efb
Binary files /dev/null and b/out/renderer/assets/SongItem-Bw5Qa7XV.css.gz differ
diff --git a/out/renderer/assets/SongItem-CoswpGn6.js b/out/renderer/assets/SongItem-CoswpGn6.js
new file mode 100644
index 0000000..2e6953d
--- /dev/null
+++ b/out/renderer/assets/SongItem-CoswpGn6.js
@@ -0,0 +1,170 @@
+import { d as defineComponent, g as useStore, G as computed, aG as useTemplateRef, j as openBlock, c as createElementBlock, O as createBlock, u as unref, a7 as getImgUrl, T as createCommentVNode, b as createBaseVNode, e as createVNode, f as withCtx, k as createTextVNode, t as toDisplayString, a3 as Fragment, a4 as renderList, n as normalizeClass, ah as withModifiers, b5 as getImageBackground, ae as audioService, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import { _ as __unplugin_components_2 } from "./Ellipsis-D4R5dIX2.js";
+const _hoisted_1 = { class: "song-item-content" };
+const _hoisted_2 = {
+ key: 0,
+ class: "song-item-content-wrapper"
+};
+const _hoisted_3 = { class: "song-item-content-title" };
+const _hoisted_4 = { class: "song-item-content-name" };
+const _hoisted_5 = {
+ key: 0,
+ class: "song-item-operating-like"
+};
+const _hoisted_6 = {
+ key: 0,
+ class: "iconfont icon-stop"
+};
+const _hoisted_7 = {
+ key: 1,
+ class: "iconfont icon-playfill"
+};
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "SongItem",
+ props: {
+ item: {},
+ mini: { type: Boolean, default: false },
+ list: { type: Boolean, default: false },
+ favorite: { type: Boolean, default: true }
+ },
+ emits: ["play"],
+ setup(__props, { emit: __emit }) {
+ const props = __props;
+ const store = useStore();
+ const play = computed(() => store.state.play);
+ const playMusic = computed(() => store.state.playMusic);
+ const playLoading = computed(
+ () => playMusic.value.id === props.item.id && playMusic.value.playLoading
+ );
+ const isPlaying = computed(() => {
+ return playMusic.value.id === props.item.id;
+ });
+ const emits = __emit;
+ const songImageRef = useTemplateRef("songImg");
+ const imageLoad = async () => {
+ if (!songImageRef.value) {
+ return;
+ }
+ const { backgroundColor } = await getImageBackground(
+ songImageRef.value.imageRef
+ );
+ props.item.backgroundColor = backgroundColor;
+ };
+ const playMusicEvent = async (item) => {
+ if (playMusic.value.id === item.id) {
+ if (play.value) {
+ store.commit("setPlayMusic", false);
+ audioService.getCurrentSound()?.pause();
+ } else {
+ store.commit("setPlayMusic", true);
+ audioService.getCurrentSound()?.play();
+ }
+ return;
+ }
+ await store.commit("setPlay", item);
+ store.commit("setIsPlay", true);
+ emits("play", item);
+ };
+ const isFavorite = computed(() => {
+ return store.state.favoriteList.includes(props.item.id);
+ });
+ const toggleFavorite = async (e) => {
+ e.stopPropagation();
+ if (isFavorite.value) {
+ store.commit("removeFromFavorite", props.item.id);
+ } else {
+ store.commit("addToFavorite", props.item.id);
+ }
+ };
+ return (_ctx, _cache) => {
+ const _component_n_image = NImage;
+ const _component_n_ellipsis = __unplugin_components_2;
+ return openBlock(), createElementBlock("div", {
+ class: normalizeClass(["song-item", { "song-mini": _ctx.mini, "song-list": _ctx.list }])
+ }, [
+ _ctx.item.picUrl ? (openBlock(), createBlock(_component_n_image, {
+ key: 0,
+ ref: "songImg",
+ src: unref(getImgUrl)(_ctx.item.picUrl, "100y100"),
+ class: "song-item-img",
+ "preview-disabled": "",
+ "img-props": {
+ crossorigin: "anonymous"
+ },
+ onLoad: imageLoad
+ }, null, 8, ["src"])) : createCommentVNode("", true),
+ createBaseVNode("div", _hoisted_1, [
+ _ctx.list ? (openBlock(), createElementBlock("div", _hoisted_2, [
+ createVNode(_component_n_ellipsis, {
+ class: "song-item-content-title text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ createTextVNode(toDisplayString(_ctx.item.name), 1)
+ ]),
+ _: 1
+ }),
+ _cache[1] || (_cache[1] = createBaseVNode("div", { class: "song-item-content-divider" }, "-", -1)),
+ createVNode(_component_n_ellipsis, {
+ class: "song-item-content-name text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.item.ar || _ctx.item.song.artists, (artists, artistsindex) => {
+ return openBlock(), createElementBlock("span", { key: artistsindex }, toDisplayString(artists.name) + toDisplayString(artistsindex < (_ctx.item.ar || _ctx.item.song.artists).length - 1 ? " / " : ""), 1);
+ }), 128))
+ ]),
+ _: 1
+ })
+ ])) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
+ createBaseVNode("div", _hoisted_3, [
+ createVNode(_component_n_ellipsis, {
+ class: "text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ createTextVNode(toDisplayString(_ctx.item.name), 1)
+ ]),
+ _: 1
+ })
+ ]),
+ createBaseVNode("div", _hoisted_4, [
+ createVNode(_component_n_ellipsis, {
+ class: "text-ellipsis",
+ "line-clamp": "1"
+ }, {
+ default: withCtx(() => [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.item.ar || _ctx.item.song.artists, (artists, artistsindex) => {
+ return openBlock(), createElementBlock("span", { key: artistsindex }, toDisplayString(artists.name) + toDisplayString(artistsindex < (_ctx.item.ar || _ctx.item.song.artists).length - 1 ? " / " : ""), 1);
+ }), 128))
+ ]),
+ _: 1
+ })
+ ])
+ ], 64))
+ ]),
+ createBaseVNode("div", {
+ class: normalizeClass(["song-item-operating", { "song-item-operating-list": _ctx.list }])
+ }, [
+ _ctx.favorite ? (openBlock(), createElementBlock("div", _hoisted_5, [
+ createBaseVNode("i", {
+ class: normalizeClass(["iconfont icon-likefill", { "like-active": isFavorite.value }]),
+ onClick: withModifiers(toggleFavorite, ["stop"])
+ }, null, 2)
+ ])) : createCommentVNode("", true),
+ createBaseVNode("div", {
+ class: normalizeClass(["song-item-operating-play bg-gray-300 dark:bg-gray-800 animate__animated", { "bg-green-600": isPlaying.value, animate__flipInY: playLoading.value }]),
+ onClick: _cache[0] || (_cache[0] = ($event) => playMusicEvent(_ctx.item))
+ }, [
+ isPlaying.value && play.value ? (openBlock(), createElementBlock("i", _hoisted_6)) : (openBlock(), createElementBlock("i", _hoisted_7))
+ ], 2)
+ ], 2)
+ ], 2);
+ };
+ }
+});
+const SongItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-aae6c67f"]]);
+export {
+ SongItem as S
+};
diff --git a/out/renderer/assets/SongItem-CoswpGn6.js.gz b/out/renderer/assets/SongItem-CoswpGn6.js.gz
new file mode 100644
index 0000000..877070a
Binary files /dev/null and b/out/renderer/assets/SongItem-CoswpGn6.js.gz differ
diff --git a/out/renderer/assets/Switch-D3Z_Vg3u.js b/out/renderer/assets/Switch-D3Z_Vg3u.js
new file mode 100644
index 0000000..176fd48
--- /dev/null
+++ b/out/renderer/assets/Switch-D3Z_Vg3u.js
@@ -0,0 +1,2185 @@
+import { d as defineComponent, l as h, bk as replaceable, p as cB, m as c, Y as cE, bl as iconSwitchTransition, Z as useStyle, A as toRef, bm as NIconSwitchTransition, K as resolveSlot, N as NBaseIcon, bn as NBaseLoading, aL as createInjectionKey, W as cM, V as cNotM, r as ref, E as watch, as as inject, G as computed, bo as resolveSlotWithProps, x as useConfig, q as useTheme, bp as inputLight, bq as isSafari, C as useMergedState, z as useFormItem, D as useMemo, o as onMounted, br as getCurrentInstance, a8 as watchEffect, $ as provide, F as useRtl, ao as createKey, bs as getMargin, ap as useThemeClass, I as resolveWrappedSlot, aK as Scrollbar, a3 as Fragment, ay as VResizeObserver, M as nextTick, J as on, L as call, aS as off, bt as switchLight, aw as pxfy, av as depx, bu as isSlotEmpty } from "./index-DKaFsuse.js";
+import { u as useLocale } from "./use-locale-DLWAOXez.js";
+const ChevronDownIcon = defineComponent({
+ name: "ChevronDown",
+ render() {
+ return h("svg", {
+ viewBox: "0 0 16 16",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M3.14645 5.64645C3.34171 5.45118 3.65829 5.45118 3.85355 5.64645L8 9.79289L12.1464 5.64645C12.3417 5.45118 12.6583 5.45118 12.8536 5.64645C13.0488 5.84171 13.0488 6.15829 12.8536 6.35355L8.35355 10.8536C8.15829 11.0488 7.84171 11.0488 7.64645 10.8536L3.14645 6.35355C2.95118 6.15829 2.95118 5.84171 3.14645 5.64645Z",
+ fill: "currentColor"
+ }));
+ }
+});
+const ClearIcon = replaceable("clear", () => h("svg", {
+ viewBox: "0 0 16 16",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ fill: "none",
+ "fill-rule": "evenodd"
+}, h("g", {
+ fill: "currentColor",
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M8,2 C11.3137085,2 14,4.6862915 14,8 C14,11.3137085 11.3137085,14 8,14 C4.6862915,14 2,11.3137085 2,8 C2,4.6862915 4.6862915,2 8,2 Z M6.5343055,5.83859116 C6.33943736,5.70359511 6.07001296,5.72288026 5.89644661,5.89644661 L5.89644661,5.89644661 L5.83859116,5.9656945 C5.70359511,6.16056264 5.72288026,6.42998704 5.89644661,6.60355339 L5.89644661,6.60355339 L7.293,8 L5.89644661,9.39644661 L5.83859116,9.4656945 C5.70359511,9.66056264 5.72288026,9.92998704 5.89644661,10.1035534 L5.89644661,10.1035534 L5.9656945,10.1614088 C6.16056264,10.2964049 6.42998704,10.2771197 6.60355339,10.1035534 L6.60355339,10.1035534 L8,8.707 L9.39644661,10.1035534 L9.4656945,10.1614088 C9.66056264,10.2964049 9.92998704,10.2771197 10.1035534,10.1035534 L10.1035534,10.1035534 L10.1614088,10.0343055 C10.2964049,9.83943736 10.2771197,9.57001296 10.1035534,9.39644661 L10.1035534,9.39644661 L8.707,8 L10.1035534,6.60355339 L10.1614088,6.5343055 C10.2964049,6.33943736 10.2771197,6.07001296 10.1035534,5.89644661 L10.1035534,5.89644661 L10.0343055,5.83859116 C9.83943736,5.70359511 9.57001296,5.72288026 9.39644661,5.89644661 L9.39644661,5.89644661 L8,7.293 L6.60355339,5.89644661 Z"
+})))));
+const EyeIcon = defineComponent({
+ name: "Eye",
+ render() {
+ return h("svg", {
+ xmlns: "http://www.w3.org/2000/svg",
+ viewBox: "0 0 512 512"
+ }, h("path", {
+ d: "M255.66 112c-77.94 0-157.89 45.11-220.83 135.33a16 16 0 0 0-.27 17.77C82.92 340.8 161.8 400 255.66 400c92.84 0 173.34-59.38 221.79-135.25a16.14 16.14 0 0 0 0-17.47C428.89 172.28 347.8 112 255.66 112z",
+ fill: "none",
+ stroke: "currentColor",
+ "stroke-linecap": "round",
+ "stroke-linejoin": "round",
+ "stroke-width": "32"
+ }), h("circle", {
+ cx: "256",
+ cy: "256",
+ r: "80",
+ fill: "none",
+ stroke: "currentColor",
+ "stroke-miterlimit": "10",
+ "stroke-width": "32"
+ }));
+ }
+});
+const EyeOffIcon = defineComponent({
+ name: "EyeOff",
+ render() {
+ return h("svg", {
+ xmlns: "http://www.w3.org/2000/svg",
+ viewBox: "0 0 512 512"
+ }, h("path", {
+ d: "M432 448a15.92 15.92 0 0 1-11.31-4.69l-352-352a16 16 0 0 1 22.62-22.62l352 352A16 16 0 0 1 432 448z",
+ fill: "currentColor"
+ }), h("path", {
+ d: "M255.66 384c-41.49 0-81.5-12.28-118.92-36.5c-34.07-22-64.74-53.51-88.7-91v-.08c19.94-28.57 41.78-52.73 65.24-72.21a2 2 0 0 0 .14-2.94L93.5 161.38a2 2 0 0 0-2.71-.12c-24.92 21-48.05 46.76-69.08 76.92a31.92 31.92 0 0 0-.64 35.54c26.41 41.33 60.4 76.14 98.28 100.65C162 402 207.9 416 255.66 416a239.13 239.13 0 0 0 75.8-12.58a2 2 0 0 0 .77-3.31l-21.58-21.58a4 4 0 0 0-3.83-1a204.8 204.8 0 0 1-51.16 6.47z",
+ fill: "currentColor"
+ }), h("path", {
+ d: "M490.84 238.6c-26.46-40.92-60.79-75.68-99.27-100.53C349 110.55 302 96 255.66 96a227.34 227.34 0 0 0-74.89 12.83a2 2 0 0 0-.75 3.31l21.55 21.55a4 4 0 0 0 3.88 1a192.82 192.82 0 0 1 50.21-6.69c40.69 0 80.58 12.43 118.55 37c34.71 22.4 65.74 53.88 89.76 91a.13.13 0 0 1 0 .16a310.72 310.72 0 0 1-64.12 72.73a2 2 0 0 0-.15 2.95l19.9 19.89a2 2 0 0 0 2.7.13a343.49 343.49 0 0 0 68.64-78.48a32.2 32.2 0 0 0-.1-34.78z",
+ fill: "currentColor"
+ }), h("path", {
+ d: "M256 160a95.88 95.88 0 0 0-21.37 2.4a2 2 0 0 0-1 3.38l112.59 112.56a2 2 0 0 0 3.38-1A96 96 0 0 0 256 160z",
+ fill: "currentColor"
+ }), h("path", {
+ d: "M165.78 233.66a2 2 0 0 0-3.38 1a96 96 0 0 0 115 115a2 2 0 0 0 1-3.38z",
+ fill: "currentColor"
+ }));
+ }
+});
+const style$2 = cB("base-clear", `
+ flex-shrink: 0;
+ height: 1em;
+ width: 1em;
+ position: relative;
+`, [c(">", [cE("clear", `
+ font-size: var(--n-clear-size);
+ height: 1em;
+ width: 1em;
+ cursor: pointer;
+ color: var(--n-clear-color);
+ transition: color .3s var(--n-bezier);
+ display: flex;
+ `, [c("&:hover", `
+ color: var(--n-clear-color-hover)!important;
+ `), c("&:active", `
+ color: var(--n-clear-color-pressed)!important;
+ `)]), cE("placeholder", `
+ display: flex;
+ `), cE("clear, placeholder", `
+ position: absolute;
+ left: 50%;
+ top: 50%;
+ transform: translateX(-50%) translateY(-50%);
+ `, [iconSwitchTransition({
+ originalTransform: "translateX(-50%) translateY(-50%)",
+ left: "50%",
+ top: "50%"
+})])])]);
+const NBaseClear = defineComponent({
+ name: "BaseClear",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ show: Boolean,
+ onClear: Function
+ },
+ setup(props) {
+ useStyle("-base-clear", style$2, toRef(props, "clsPrefix"));
+ return {
+ handleMouseDown(e) {
+ e.preventDefault();
+ }
+ };
+ },
+ render() {
+ const {
+ clsPrefix
+ } = this;
+ return h("div", {
+ class: `${clsPrefix}-base-clear`
+ }, h(NIconSwitchTransition, null, {
+ default: () => {
+ var _a, _b;
+ return this.show ? h("div", {
+ key: "dismiss",
+ class: `${clsPrefix}-base-clear__clear`,
+ onClick: this.onClear,
+ onMousedown: this.handleMouseDown,
+ "data-clear": true
+ }, resolveSlot(this.$slots.icon, () => [h(NBaseIcon, {
+ clsPrefix
+ }, {
+ default: () => h(ClearIcon, null)
+ })])) : h("div", {
+ key: "icon",
+ class: `${clsPrefix}-base-clear__placeholder`
+ }, (_b = (_a = this.$slots).placeholder) === null || _b === void 0 ? void 0 : _b.call(_a));
+ }
+ }));
+ }
+});
+const NBaseSuffix = defineComponent({
+ name: "InternalSelectionSuffix",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ showArrow: {
+ type: Boolean,
+ default: void 0
+ },
+ showClear: {
+ type: Boolean,
+ default: void 0
+ },
+ loading: {
+ type: Boolean,
+ default: false
+ },
+ onClear: Function
+ },
+ setup(props, {
+ slots
+ }) {
+ return () => {
+ const {
+ clsPrefix
+ } = props;
+ return h(NBaseLoading, {
+ clsPrefix,
+ class: `${clsPrefix}-base-suffix`,
+ strokeWidth: 24,
+ scale: 0.85,
+ show: props.loading
+ }, {
+ default: () => props.showArrow ? h(NBaseClear, {
+ clsPrefix,
+ show: props.showClear,
+ onClear: props.onClear
+ }, {
+ placeholder: () => h(NBaseIcon, {
+ clsPrefix,
+ class: `${clsPrefix}-base-suffix__arrow`
+ }, {
+ default: () => resolveSlot(slots.default, () => [h(ChevronDownIcon, null)])
+ })
+ }) : null
+ });
+ };
+ }
+});
+const inputInjectionKey = createInjectionKey("n-input");
+const style$1 = cB("input", `
+ max-width: 100%;
+ cursor: text;
+ line-height: 1.5;
+ z-index: auto;
+ outline: none;
+ box-sizing: border-box;
+ position: relative;
+ display: inline-flex;
+ border-radius: var(--n-border-radius);
+ background-color: var(--n-color);
+ transition: background-color .3s var(--n-bezier);
+ font-size: var(--n-font-size);
+ font-weight: var(--n-font-weight);
+ --n-padding-vertical: calc((var(--n-height) - 1.5 * var(--n-font-size)) / 2);
+`, [
+ // common
+ cE("input, textarea", `
+ overflow: hidden;
+ flex-grow: 1;
+ position: relative;
+ `),
+ cE("input-el, textarea-el, input-mirror, textarea-mirror, separator, placeholder", `
+ box-sizing: border-box;
+ font-size: inherit;
+ line-height: 1.5;
+ font-family: inherit;
+ border: none;
+ outline: none;
+ background-color: #0000;
+ text-align: inherit;
+ transition:
+ -webkit-text-fill-color .3s var(--n-bezier),
+ caret-color .3s var(--n-bezier),
+ color .3s var(--n-bezier),
+ text-decoration-color .3s var(--n-bezier);
+ `),
+ cE("input-el, textarea-el", `
+ -webkit-appearance: none;
+ scrollbar-width: none;
+ width: 100%;
+ min-width: 0;
+ text-decoration-color: var(--n-text-decoration-color);
+ color: var(--n-text-color);
+ caret-color: var(--n-caret-color);
+ background-color: transparent;
+ `, [c("&::-webkit-scrollbar, &::-webkit-scrollbar-track-piece, &::-webkit-scrollbar-thumb", `
+ width: 0;
+ height: 0;
+ display: none;
+ `), c("&::placeholder", `
+ color: #0000;
+ -webkit-text-fill-color: transparent !important;
+ `), c("&:-webkit-autofill ~", [cE("placeholder", "display: none;")])]),
+ cM("round", [cNotM("textarea", "border-radius: calc(var(--n-height) / 2);")]),
+ cE("placeholder", `
+ pointer-events: none;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ overflow: hidden;
+ color: var(--n-placeholder-color);
+ `, [c("span", `
+ width: 100%;
+ display: inline-block;
+ `)]),
+ cM("textarea", [cE("placeholder", "overflow: visible;")]),
+ cNotM("autosize", "width: 100%;"),
+ cM("autosize", [cE("textarea-el, input-el", `
+ position: absolute;
+ top: 0;
+ left: 0;
+ height: 100%;
+ `)]),
+ // input
+ cB("input-wrapper", `
+ overflow: hidden;
+ display: inline-flex;
+ flex-grow: 1;
+ position: relative;
+ padding-left: var(--n-padding-left);
+ padding-right: var(--n-padding-right);
+ `),
+ cE("input-mirror", `
+ padding: 0;
+ height: var(--n-height);
+ line-height: var(--n-height);
+ overflow: hidden;
+ visibility: hidden;
+ position: static;
+ white-space: pre;
+ pointer-events: none;
+ `),
+ cE("input-el", `
+ padding: 0;
+ height: var(--n-height);
+ line-height: var(--n-height);
+ `, [c("&[type=password]::-ms-reveal", "display: none;"), c("+", [cE("placeholder", `
+ display: flex;
+ align-items: center;
+ `)])]),
+ cNotM("textarea", [cE("placeholder", "white-space: nowrap;")]),
+ cE("eye", `
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ transition: color .3s var(--n-bezier);
+ `),
+ // textarea
+ cM("textarea", "width: 100%;", [cB("input-word-count", `
+ position: absolute;
+ right: var(--n-padding-right);
+ bottom: var(--n-padding-vertical);
+ `), cM("resizable", [cB("input-wrapper", `
+ resize: vertical;
+ min-height: var(--n-height);
+ `)]), cE("textarea-el, textarea-mirror, placeholder", `
+ height: 100%;
+ padding-left: 0;
+ padding-right: 0;
+ padding-top: var(--n-padding-vertical);
+ padding-bottom: var(--n-padding-vertical);
+ word-break: break-word;
+ display: inline-block;
+ vertical-align: bottom;
+ box-sizing: border-box;
+ line-height: var(--n-line-height-textarea);
+ margin: 0;
+ resize: none;
+ white-space: pre-wrap;
+ scroll-padding-block-end: var(--n-padding-vertical);
+ `), cE("textarea-mirror", `
+ width: 100%;
+ pointer-events: none;
+ overflow: hidden;
+ visibility: hidden;
+ position: static;
+ white-space: pre-wrap;
+ overflow-wrap: break-word;
+ `)]),
+ // pair
+ cM("pair", [cE("input-el, placeholder", "text-align: center;"), cE("separator", `
+ display: flex;
+ align-items: center;
+ transition: color .3s var(--n-bezier);
+ color: var(--n-text-color);
+ white-space: nowrap;
+ `, [cB("icon", `
+ color: var(--n-icon-color);
+ `), cB("base-icon", `
+ color: var(--n-icon-color);
+ `)])]),
+ cM("disabled", `
+ cursor: not-allowed;
+ background-color: var(--n-color-disabled);
+ `, [cE("border", "border: var(--n-border-disabled);"), cE("input-el, textarea-el", `
+ cursor: not-allowed;
+ color: var(--n-text-color-disabled);
+ text-decoration-color: var(--n-text-color-disabled);
+ `), cE("placeholder", "color: var(--n-placeholder-color-disabled);"), cE("separator", "color: var(--n-text-color-disabled);", [cB("icon", `
+ color: var(--n-icon-color-disabled);
+ `), cB("base-icon", `
+ color: var(--n-icon-color-disabled);
+ `)]), cB("input-word-count", `
+ color: var(--n-count-text-color-disabled);
+ `), cE("suffix, prefix", "color: var(--n-text-color-disabled);", [cB("icon", `
+ color: var(--n-icon-color-disabled);
+ `), cB("internal-icon", `
+ color: var(--n-icon-color-disabled);
+ `)])]),
+ cNotM("disabled", [cE("eye", `
+ color: var(--n-icon-color);
+ cursor: pointer;
+ `, [c("&:hover", `
+ color: var(--n-icon-color-hover);
+ `), c("&:active", `
+ color: var(--n-icon-color-pressed);
+ `)]), c("&:hover", [cE("state-border", "border: var(--n-border-hover);")]), cM("focus", "background-color: var(--n-color-focus);", [cE("state-border", `
+ border: var(--n-border-focus);
+ box-shadow: var(--n-box-shadow-focus);
+ `)])]),
+ cE("border, state-border", `
+ box-sizing: border-box;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ pointer-events: none;
+ border-radius: inherit;
+ border: var(--n-border);
+ transition:
+ box-shadow .3s var(--n-bezier),
+ border-color .3s var(--n-bezier);
+ `),
+ cE("state-border", `
+ border-color: #0000;
+ z-index: 1;
+ `),
+ cE("prefix", "margin-right: 4px;"),
+ cE("suffix", `
+ margin-left: 4px;
+ `),
+ cE("suffix, prefix", `
+ transition: color .3s var(--n-bezier);
+ flex-wrap: nowrap;
+ flex-shrink: 0;
+ line-height: var(--n-height);
+ white-space: nowrap;
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ color: var(--n-suffix-text-color);
+ `, [cB("base-loading", `
+ font-size: var(--n-icon-size);
+ margin: 0 2px;
+ color: var(--n-loading-color);
+ `), cB("base-clear", `
+ font-size: var(--n-icon-size);
+ `, [cE("placeholder", [cB("base-icon", `
+ transition: color .3s var(--n-bezier);
+ color: var(--n-icon-color);
+ font-size: var(--n-icon-size);
+ `)])]), c(">", [cB("icon", `
+ transition: color .3s var(--n-bezier);
+ color: var(--n-icon-color);
+ font-size: var(--n-icon-size);
+ `)]), cB("base-icon", `
+ font-size: var(--n-icon-size);
+ `)]),
+ cB("input-word-count", `
+ pointer-events: none;
+ line-height: 1.5;
+ font-size: .85em;
+ color: var(--n-count-text-color);
+ transition: color .3s var(--n-bezier);
+ margin-left: 4px;
+ font-variant: tabular-nums;
+ `),
+ ["warning", "error"].map((status) => cM(`${status}-status`, [cNotM("disabled", [cB("base-loading", `
+ color: var(--n-loading-color-${status})
+ `), cE("input-el, textarea-el", `
+ caret-color: var(--n-caret-color-${status});
+ `), cE("state-border", `
+ border: var(--n-border-${status});
+ `), c("&:hover", [cE("state-border", `
+ border: var(--n-border-hover-${status});
+ `)]), c("&:focus", `
+ background-color: var(--n-color-focus-${status});
+ `, [cE("state-border", `
+ box-shadow: var(--n-box-shadow-focus-${status});
+ border: var(--n-border-focus-${status});
+ `)]), cM("focus", `
+ background-color: var(--n-color-focus-${status});
+ `, [cE("state-border", `
+ box-shadow: var(--n-box-shadow-focus-${status});
+ border: var(--n-border-focus-${status});
+ `)])])]))
+]);
+const safariStyle = cB("input", [cM("disabled", [cE("input-el, textarea-el", `
+ -webkit-text-fill-color: var(--n-text-color-disabled);
+ `)])]);
+function len(s) {
+ let count = 0;
+ for (const _ of s) {
+ count++;
+ }
+ return count;
+}
+function isEmptyInputValue(value) {
+ return value === "" || value == null;
+}
+function useCursor(inputElRef) {
+ const selectionRef = ref(null);
+ function recordCursor() {
+ const {
+ value: input
+ } = inputElRef;
+ if (!(input === null || input === void 0 ? void 0 : input.focus)) {
+ reset();
+ return;
+ }
+ const {
+ selectionStart,
+ selectionEnd,
+ value
+ } = input;
+ if (selectionStart == null || selectionEnd == null) {
+ reset();
+ return;
+ }
+ selectionRef.value = {
+ start: selectionStart,
+ end: selectionEnd,
+ beforeText: value.slice(0, selectionStart),
+ afterText: value.slice(selectionEnd)
+ };
+ }
+ function restoreCursor() {
+ var _a;
+ const {
+ value: selection
+ } = selectionRef;
+ const {
+ value: inputEl
+ } = inputElRef;
+ if (!selection || !inputEl) {
+ return;
+ }
+ const {
+ value
+ } = inputEl;
+ const {
+ start,
+ beforeText,
+ afterText
+ } = selection;
+ let startPos = value.length;
+ if (value.endsWith(afterText)) {
+ startPos = value.length - afterText.length;
+ } else if (value.startsWith(beforeText)) {
+ startPos = beforeText.length;
+ } else {
+ const beforeLastChar = beforeText[start - 1];
+ const newIndex = value.indexOf(beforeLastChar, start - 1);
+ if (newIndex !== -1) {
+ startPos = newIndex + 1;
+ }
+ }
+ (_a = inputEl.setSelectionRange) === null || _a === void 0 ? void 0 : _a.call(inputEl, startPos, startPos);
+ }
+ function reset() {
+ selectionRef.value = null;
+ }
+ watch(inputElRef, reset);
+ return {
+ recordCursor,
+ restoreCursor
+ };
+}
+const WordCount = defineComponent({
+ name: "InputWordCount",
+ setup(_, {
+ slots
+ }) {
+ const {
+ mergedValueRef,
+ maxlengthRef,
+ mergedClsPrefixRef,
+ countGraphemesRef
+ } = inject(inputInjectionKey);
+ const wordCountRef = computed(() => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (mergedValue === null || Array.isArray(mergedValue)) return 0;
+ return (countGraphemesRef.value || len)(mergedValue);
+ });
+ return () => {
+ const {
+ value: maxlength
+ } = maxlengthRef;
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ return h("span", {
+ class: `${mergedClsPrefixRef.value}-input-word-count`
+ }, resolveSlotWithProps(slots.default, {
+ value: mergedValue === null || Array.isArray(mergedValue) ? "" : mergedValue
+ }, () => [maxlength === void 0 ? wordCountRef.value : `${wordCountRef.value} / ${maxlength}`]));
+ };
+ }
+});
+const inputProps = Object.assign(Object.assign({}, useTheme.props), {
+ bordered: {
+ type: Boolean,
+ default: void 0
+ },
+ type: {
+ type: String,
+ default: "text"
+ },
+ placeholder: [Array, String],
+ defaultValue: {
+ type: [String, Array],
+ default: null
+ },
+ value: [String, Array],
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ size: String,
+ rows: {
+ type: [Number, String],
+ default: 3
+ },
+ round: Boolean,
+ minlength: [String, Number],
+ maxlength: [String, Number],
+ clearable: Boolean,
+ autosize: {
+ type: [Boolean, Object],
+ default: false
+ },
+ pair: Boolean,
+ separator: String,
+ readonly: {
+ type: [String, Boolean],
+ default: false
+ },
+ passivelyActivated: Boolean,
+ showPasswordOn: String,
+ stateful: {
+ type: Boolean,
+ default: true
+ },
+ autofocus: Boolean,
+ inputProps: Object,
+ resizable: {
+ type: Boolean,
+ default: true
+ },
+ showCount: Boolean,
+ loading: {
+ type: Boolean,
+ default: void 0
+ },
+ allowInput: Function,
+ renderCount: Function,
+ onMousedown: Function,
+ onKeydown: Function,
+ onKeyup: [Function, Array],
+ onInput: [Function, Array],
+ onFocus: [Function, Array],
+ onBlur: [Function, Array],
+ onClick: [Function, Array],
+ onChange: [Function, Array],
+ onClear: [Function, Array],
+ countGraphemes: Function,
+ status: String,
+ "onUpdate:value": [Function, Array],
+ onUpdateValue: [Function, Array],
+ /** private */
+ textDecoration: [String, Array],
+ attrSize: {
+ type: Number,
+ default: 20
+ },
+ onInputBlur: [Function, Array],
+ onInputFocus: [Function, Array],
+ onDeactivate: [Function, Array],
+ onActivate: [Function, Array],
+ onWrapperFocus: [Function, Array],
+ onWrapperBlur: [Function, Array],
+ internalDeactivateOnEnter: Boolean,
+ internalForceFocus: Boolean,
+ internalLoadingBeforeSuffix: {
+ type: Boolean,
+ default: true
+ },
+ /** deprecated */
+ showPasswordToggle: Boolean
+});
+const __unplugin_components_1 = defineComponent({
+ name: "Input",
+ props: inputProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ mergedBorderedRef,
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const themeRef = useTheme("Input", "-input", style$1, inputLight, props, mergedClsPrefixRef);
+ if (isSafari) {
+ useStyle("-input-safari", safariStyle, mergedClsPrefixRef);
+ }
+ const wrapperElRef = ref(null);
+ const textareaElRef = ref(null);
+ const textareaMirrorElRef = ref(null);
+ const inputMirrorElRef = ref(null);
+ const inputElRef = ref(null);
+ const inputEl2Ref = ref(null);
+ const currentFocusedInputRef = ref(null);
+ const focusedInputCursorControl = useCursor(currentFocusedInputRef);
+ const textareaScrollbarInstRef = ref(null);
+ const {
+ localeRef
+ } = useLocale("Input");
+ const uncontrolledValueRef = ref(props.defaultValue);
+ const controlledValueRef = toRef(props, "value");
+ const mergedValueRef = useMergedState(controlledValueRef, uncontrolledValueRef);
+ const formItem = useFormItem(props);
+ const {
+ mergedSizeRef,
+ mergedDisabledRef,
+ mergedStatusRef
+ } = formItem;
+ const focusedRef = ref(false);
+ const hoverRef = ref(false);
+ const isComposingRef = ref(false);
+ const activatedRef = ref(false);
+ let syncSource = null;
+ const mergedPlaceholderRef = computed(() => {
+ const {
+ placeholder,
+ pair
+ } = props;
+ if (pair) {
+ if (Array.isArray(placeholder)) {
+ return placeholder;
+ } else if (placeholder === void 0) {
+ return ["", ""];
+ }
+ return [placeholder, placeholder];
+ } else if (placeholder === void 0) {
+ return [localeRef.value.placeholder];
+ } else {
+ return [placeholder];
+ }
+ });
+ const showPlaceholder1Ref = computed(() => {
+ const {
+ value: isComposing
+ } = isComposingRef;
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ const {
+ value: mergedPlaceholder
+ } = mergedPlaceholderRef;
+ return !isComposing && (isEmptyInputValue(mergedValue) || Array.isArray(mergedValue) && isEmptyInputValue(mergedValue[0])) && mergedPlaceholder[0];
+ });
+ const showPlaceholder2Ref = computed(() => {
+ const {
+ value: isComposing
+ } = isComposingRef;
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ const {
+ value: mergedPlaceholder
+ } = mergedPlaceholderRef;
+ return !isComposing && mergedPlaceholder[1] && (isEmptyInputValue(mergedValue) || Array.isArray(mergedValue) && isEmptyInputValue(mergedValue[1]));
+ });
+ const mergedFocusRef = useMemo(() => {
+ return props.internalForceFocus || focusedRef.value;
+ });
+ const showClearButton = useMemo(() => {
+ if (mergedDisabledRef.value || props.readonly || !props.clearable || !mergedFocusRef.value && !hoverRef.value) {
+ return false;
+ }
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ const {
+ value: mergedFocus
+ } = mergedFocusRef;
+ if (props.pair) {
+ return !!(Array.isArray(mergedValue) && (mergedValue[0] || mergedValue[1])) && (hoverRef.value || mergedFocus);
+ } else {
+ return !!mergedValue && (hoverRef.value || mergedFocus);
+ }
+ });
+ const mergedShowPasswordOnRef = computed(() => {
+ const {
+ showPasswordOn
+ } = props;
+ if (showPasswordOn) {
+ return showPasswordOn;
+ }
+ if (props.showPasswordToggle) return "click";
+ return void 0;
+ });
+ const passwordVisibleRef = ref(false);
+ const textDecorationStyleRef = computed(() => {
+ const {
+ textDecoration
+ } = props;
+ if (!textDecoration) return ["", ""];
+ if (Array.isArray(textDecoration)) {
+ return textDecoration.map((v) => ({
+ textDecoration: v
+ }));
+ }
+ return [{
+ textDecoration
+ }];
+ });
+ const textAreaScrollContainerWidthRef = ref(void 0);
+ const updateTextAreaStyle = () => {
+ var _a, _b;
+ if (props.type === "textarea") {
+ const {
+ autosize
+ } = props;
+ if (autosize) {
+ textAreaScrollContainerWidthRef.value = (_b = (_a = textareaScrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.$el) === null || _b === void 0 ? void 0 : _b.offsetWidth;
+ }
+ if (!textareaElRef.value) return;
+ if (typeof autosize === "boolean") return;
+ const {
+ paddingTop: stylePaddingTop,
+ paddingBottom: stylePaddingBottom,
+ lineHeight: styleLineHeight
+ } = window.getComputedStyle(textareaElRef.value);
+ const paddingTop = Number(stylePaddingTop.slice(0, -2));
+ const paddingBottom = Number(stylePaddingBottom.slice(0, -2));
+ const lineHeight = Number(styleLineHeight.slice(0, -2));
+ const {
+ value: textareaMirrorEl
+ } = textareaMirrorElRef;
+ if (!textareaMirrorEl) return;
+ if (autosize.minRows) {
+ const minRows = Math.max(autosize.minRows, 1);
+ const styleMinHeight = `${paddingTop + paddingBottom + lineHeight * minRows}px`;
+ textareaMirrorEl.style.minHeight = styleMinHeight;
+ }
+ if (autosize.maxRows) {
+ const styleMaxHeight = `${paddingTop + paddingBottom + lineHeight * autosize.maxRows}px`;
+ textareaMirrorEl.style.maxHeight = styleMaxHeight;
+ }
+ }
+ };
+ const maxlengthRef = computed(() => {
+ const {
+ maxlength
+ } = props;
+ return maxlength === void 0 ? void 0 : Number(maxlength);
+ });
+ onMounted(() => {
+ const {
+ value
+ } = mergedValueRef;
+ if (!Array.isArray(value)) {
+ syncMirror(value);
+ }
+ });
+ const vm = getCurrentInstance().proxy;
+ function doUpdateValue(value, meta) {
+ const {
+ onUpdateValue,
+ "onUpdate:value": _onUpdateValue,
+ onInput
+ } = props;
+ const {
+ nTriggerFormInput
+ } = formItem;
+ if (onUpdateValue) call(onUpdateValue, value, meta);
+ if (_onUpdateValue) call(_onUpdateValue, value, meta);
+ if (onInput) call(onInput, value, meta);
+ uncontrolledValueRef.value = value;
+ nTriggerFormInput();
+ }
+ function doChange(value, meta) {
+ const {
+ onChange
+ } = props;
+ const {
+ nTriggerFormChange
+ } = formItem;
+ if (onChange) call(onChange, value, meta);
+ uncontrolledValueRef.value = value;
+ nTriggerFormChange();
+ }
+ function doBlur(e) {
+ const {
+ onBlur
+ } = props;
+ const {
+ nTriggerFormBlur
+ } = formItem;
+ if (onBlur) call(onBlur, e);
+ nTriggerFormBlur();
+ }
+ function doFocus(e) {
+ const {
+ onFocus
+ } = props;
+ const {
+ nTriggerFormFocus
+ } = formItem;
+ if (onFocus) call(onFocus, e);
+ nTriggerFormFocus();
+ }
+ function doClear(e) {
+ const {
+ onClear
+ } = props;
+ if (onClear) call(onClear, e);
+ }
+ function doUpdateValueBlur(e) {
+ const {
+ onInputBlur
+ } = props;
+ if (onInputBlur) call(onInputBlur, e);
+ }
+ function doUpdateValueFocus(e) {
+ const {
+ onInputFocus
+ } = props;
+ if (onInputFocus) call(onInputFocus, e);
+ }
+ function doDeactivate() {
+ const {
+ onDeactivate
+ } = props;
+ if (onDeactivate) call(onDeactivate);
+ }
+ function doActivate() {
+ const {
+ onActivate
+ } = props;
+ if (onActivate) call(onActivate);
+ }
+ function doClick(e) {
+ const {
+ onClick
+ } = props;
+ if (onClick) call(onClick, e);
+ }
+ function doWrapperFocus(e) {
+ const {
+ onWrapperFocus
+ } = props;
+ if (onWrapperFocus) call(onWrapperFocus, e);
+ }
+ function doWrapperBlur(e) {
+ const {
+ onWrapperBlur
+ } = props;
+ if (onWrapperBlur) call(onWrapperBlur, e);
+ }
+ function handleCompositionStart() {
+ isComposingRef.value = true;
+ }
+ function handleCompositionEnd(e) {
+ isComposingRef.value = false;
+ if (e.target === inputEl2Ref.value) {
+ handleInput(e, 1);
+ } else {
+ handleInput(e, 0);
+ }
+ }
+ function handleInput(e, index = 0, event = "input") {
+ const targetValue = e.target.value;
+ syncMirror(targetValue);
+ if (e instanceof InputEvent && !e.isComposing) {
+ isComposingRef.value = false;
+ }
+ if (props.type === "textarea") {
+ const {
+ value: textareaScrollbarInst
+ } = textareaScrollbarInstRef;
+ if (textareaScrollbarInst) {
+ textareaScrollbarInst.syncUnifiedContainer();
+ }
+ }
+ syncSource = targetValue;
+ if (isComposingRef.value) return;
+ focusedInputCursorControl.recordCursor();
+ const isIncomingValueValid = allowInput(targetValue);
+ if (isIncomingValueValid) {
+ if (!props.pair) {
+ if (event === "input") {
+ doUpdateValue(targetValue, {
+ source: index
+ });
+ } else {
+ doChange(targetValue, {
+ source: index
+ });
+ }
+ } else {
+ let {
+ value
+ } = mergedValueRef;
+ if (!Array.isArray(value)) {
+ value = ["", ""];
+ } else {
+ value = [value[0], value[1]];
+ }
+ value[index] = targetValue;
+ if (event === "input") {
+ doUpdateValue(value, {
+ source: index
+ });
+ } else {
+ doChange(value, {
+ source: index
+ });
+ }
+ }
+ }
+ vm.$forceUpdate();
+ if (!isIncomingValueValid) {
+ void nextTick(focusedInputCursorControl.restoreCursor);
+ }
+ }
+ function allowInput(value) {
+ const {
+ countGraphemes,
+ maxlength,
+ minlength
+ } = props;
+ if (countGraphemes) {
+ let graphemesCount;
+ if (maxlength !== void 0) {
+ if (graphemesCount === void 0) {
+ graphemesCount = countGraphemes(value);
+ }
+ if (graphemesCount > Number(maxlength)) return false;
+ }
+ if (minlength !== void 0) {
+ if (graphemesCount === void 0) {
+ graphemesCount = countGraphemes(value);
+ }
+ if (graphemesCount < Number(maxlength)) return false;
+ }
+ }
+ const {
+ allowInput: allowInput2
+ } = props;
+ if (typeof allowInput2 === "function") {
+ return allowInput2(value);
+ }
+ return true;
+ }
+ function handleInputBlur(e) {
+ doUpdateValueBlur(e);
+ if (e.relatedTarget === wrapperElRef.value) {
+ doDeactivate();
+ }
+ if (!(e.relatedTarget !== null && (e.relatedTarget === inputElRef.value || e.relatedTarget === inputEl2Ref.value || e.relatedTarget === textareaElRef.value))) {
+ activatedRef.value = false;
+ }
+ dealWithEvent(e, "blur");
+ currentFocusedInputRef.value = null;
+ }
+ function handleInputFocus(e, index) {
+ doUpdateValueFocus(e);
+ focusedRef.value = true;
+ activatedRef.value = true;
+ doActivate();
+ dealWithEvent(e, "focus");
+ if (index === 0) {
+ currentFocusedInputRef.value = inputElRef.value;
+ } else if (index === 1) {
+ currentFocusedInputRef.value = inputEl2Ref.value;
+ } else if (index === 2) {
+ currentFocusedInputRef.value = textareaElRef.value;
+ }
+ }
+ function handleWrapperBlur(e) {
+ if (props.passivelyActivated) {
+ doWrapperBlur(e);
+ dealWithEvent(e, "blur");
+ }
+ }
+ function handleWrapperFocus(e) {
+ if (props.passivelyActivated) {
+ focusedRef.value = true;
+ doWrapperFocus(e);
+ dealWithEvent(e, "focus");
+ }
+ }
+ function dealWithEvent(e, type) {
+ if (e.relatedTarget !== null && (e.relatedTarget === inputElRef.value || e.relatedTarget === inputEl2Ref.value || e.relatedTarget === textareaElRef.value || e.relatedTarget === wrapperElRef.value)) ;
+ else {
+ if (type === "focus") {
+ doFocus(e);
+ focusedRef.value = true;
+ } else if (type === "blur") {
+ doBlur(e);
+ focusedRef.value = false;
+ }
+ }
+ }
+ function handleChange(e, index) {
+ handleInput(e, index, "change");
+ }
+ function handleClick(e) {
+ doClick(e);
+ }
+ function handleClear(e) {
+ doClear(e);
+ clearValue();
+ }
+ function clearValue() {
+ if (props.pair) {
+ doUpdateValue(["", ""], {
+ source: "clear"
+ });
+ doChange(["", ""], {
+ source: "clear"
+ });
+ } else {
+ doUpdateValue("", {
+ source: "clear"
+ });
+ doChange("", {
+ source: "clear"
+ });
+ }
+ }
+ function handleMouseDown(e) {
+ const {
+ onMousedown
+ } = props;
+ if (onMousedown) onMousedown(e);
+ const {
+ tagName
+ } = e.target;
+ if (tagName !== "INPUT" && tagName !== "TEXTAREA") {
+ if (props.resizable) {
+ const {
+ value: wrapperEl
+ } = wrapperElRef;
+ if (wrapperEl) {
+ const {
+ left,
+ top,
+ width,
+ height
+ } = wrapperEl.getBoundingClientRect();
+ const resizeHandleSize = 14;
+ if (left + width - resizeHandleSize < e.clientX && e.clientX < left + width && top + height - resizeHandleSize < e.clientY && e.clientY < top + height) {
+ return;
+ }
+ }
+ }
+ e.preventDefault();
+ if (!focusedRef.value) {
+ focus();
+ }
+ }
+ }
+ function handleMouseEnter() {
+ var _a;
+ hoverRef.value = true;
+ if (props.type === "textarea") {
+ (_a = textareaScrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.handleMouseEnterWrapper();
+ }
+ }
+ function handleMouseLeave() {
+ var _a;
+ hoverRef.value = false;
+ if (props.type === "textarea") {
+ (_a = textareaScrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.handleMouseLeaveWrapper();
+ }
+ }
+ function handlePasswordToggleClick() {
+ if (mergedDisabledRef.value) return;
+ if (mergedShowPasswordOnRef.value !== "click") return;
+ passwordVisibleRef.value = !passwordVisibleRef.value;
+ }
+ function handlePasswordToggleMousedown(e) {
+ if (mergedDisabledRef.value) return;
+ e.preventDefault();
+ const preventDefaultOnce = (e2) => {
+ e2.preventDefault();
+ off("mouseup", document, preventDefaultOnce);
+ };
+ on("mouseup", document, preventDefaultOnce);
+ if (mergedShowPasswordOnRef.value !== "mousedown") return;
+ passwordVisibleRef.value = true;
+ const hidePassword = () => {
+ passwordVisibleRef.value = false;
+ off("mouseup", document, hidePassword);
+ };
+ on("mouseup", document, hidePassword);
+ }
+ function handleWrapperKeyup(e) {
+ if (props.onKeyup) call(props.onKeyup, e);
+ }
+ function handleWrapperKeydown(e) {
+ if (props.onKeydown) call(props.onKeydown, e);
+ switch (e.key) {
+ case "Escape":
+ handleWrapperKeydownEsc();
+ break;
+ case "Enter":
+ handleWrapperKeydownEnter(e);
+ break;
+ }
+ }
+ function handleWrapperKeydownEnter(e) {
+ var _a, _b;
+ if (props.passivelyActivated) {
+ const {
+ value: focused
+ } = activatedRef;
+ if (focused) {
+ if (props.internalDeactivateOnEnter) {
+ handleWrapperKeydownEsc();
+ }
+ return;
+ }
+ e.preventDefault();
+ if (props.type === "textarea") {
+ (_a = textareaElRef.value) === null || _a === void 0 ? void 0 : _a.focus();
+ } else {
+ (_b = inputElRef.value) === null || _b === void 0 ? void 0 : _b.focus();
+ }
+ }
+ }
+ function handleWrapperKeydownEsc() {
+ if (props.passivelyActivated) {
+ activatedRef.value = false;
+ void nextTick(() => {
+ var _a;
+ (_a = wrapperElRef.value) === null || _a === void 0 ? void 0 : _a.focus();
+ });
+ }
+ }
+ function focus() {
+ var _a, _b, _c;
+ if (mergedDisabledRef.value) return;
+ if (props.passivelyActivated) {
+ (_a = wrapperElRef.value) === null || _a === void 0 ? void 0 : _a.focus();
+ } else {
+ (_b = textareaElRef.value) === null || _b === void 0 ? void 0 : _b.focus();
+ (_c = inputElRef.value) === null || _c === void 0 ? void 0 : _c.focus();
+ }
+ }
+ function blur() {
+ var _a;
+ if ((_a = wrapperElRef.value) === null || _a === void 0 ? void 0 : _a.contains(document.activeElement)) {
+ document.activeElement.blur();
+ }
+ }
+ function select() {
+ var _a, _b;
+ (_a = textareaElRef.value) === null || _a === void 0 ? void 0 : _a.select();
+ (_b = inputElRef.value) === null || _b === void 0 ? void 0 : _b.select();
+ }
+ function activate() {
+ if (mergedDisabledRef.value) return;
+ if (textareaElRef.value) textareaElRef.value.focus();
+ else if (inputElRef.value) inputElRef.value.focus();
+ }
+ function deactivate() {
+ const {
+ value: wrapperEl
+ } = wrapperElRef;
+ if ((wrapperEl === null || wrapperEl === void 0 ? void 0 : wrapperEl.contains(document.activeElement)) && wrapperEl !== document.activeElement) {
+ handleWrapperKeydownEsc();
+ }
+ }
+ function scrollTo(options) {
+ if (props.type === "textarea") {
+ const {
+ value: textareaEl
+ } = textareaElRef;
+ textareaEl === null || textareaEl === void 0 ? void 0 : textareaEl.scrollTo(options);
+ } else {
+ const {
+ value: inputEl
+ } = inputElRef;
+ inputEl === null || inputEl === void 0 ? void 0 : inputEl.scrollTo(options);
+ }
+ }
+ function syncMirror(value) {
+ const {
+ type,
+ pair,
+ autosize
+ } = props;
+ if (!pair && autosize) {
+ if (type === "textarea") {
+ const {
+ value: textareaMirrorEl
+ } = textareaMirrorElRef;
+ if (textareaMirrorEl) {
+ textareaMirrorEl.textContent = `${value !== null && value !== void 0 ? value : ""}\r
+`;
+ }
+ } else {
+ const {
+ value: inputMirrorEl
+ } = inputMirrorElRef;
+ if (inputMirrorEl) {
+ if (value) {
+ inputMirrorEl.textContent = value;
+ } else {
+ inputMirrorEl.innerHTML = " ";
+ }
+ }
+ }
+ }
+ }
+ function handleTextAreaMirrorResize() {
+ updateTextAreaStyle();
+ }
+ const placeholderStyleRef = ref({
+ top: "0"
+ });
+ function handleTextAreaScroll(e) {
+ var _a;
+ const {
+ scrollTop
+ } = e.target;
+ placeholderStyleRef.value.top = `${-scrollTop}px`;
+ (_a = textareaScrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.syncUnifiedContainer();
+ }
+ let stopWatchMergedValue1 = null;
+ watchEffect(() => {
+ const {
+ autosize,
+ type
+ } = props;
+ if (autosize && type === "textarea") {
+ stopWatchMergedValue1 = watch(mergedValueRef, (value) => {
+ if (!Array.isArray(value) && value !== syncSource) {
+ syncMirror(value);
+ }
+ });
+ } else {
+ stopWatchMergedValue1 === null || stopWatchMergedValue1 === void 0 ? void 0 : stopWatchMergedValue1();
+ }
+ });
+ let stopWatchMergedValue2 = null;
+ watchEffect(() => {
+ if (props.type === "textarea") {
+ stopWatchMergedValue2 = watch(mergedValueRef, (value) => {
+ var _a;
+ if (!Array.isArray(value) && value !== syncSource) {
+ (_a = textareaScrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.syncUnifiedContainer();
+ }
+ });
+ } else {
+ stopWatchMergedValue2 === null || stopWatchMergedValue2 === void 0 ? void 0 : stopWatchMergedValue2();
+ }
+ });
+ provide(inputInjectionKey, {
+ mergedValueRef,
+ maxlengthRef,
+ mergedClsPrefixRef,
+ countGraphemesRef: toRef(props, "countGraphemes")
+ });
+ const exposedProps = {
+ wrapperElRef,
+ inputElRef,
+ textareaElRef,
+ isCompositing: isComposingRef,
+ clear: clearValue,
+ focus,
+ blur,
+ select,
+ deactivate,
+ activate,
+ scrollTo
+ };
+ const rtlEnabledRef = useRtl("Input", mergedRtlRef, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ value: size
+ } = mergedSizeRef;
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self: {
+ color,
+ borderRadius,
+ textColor,
+ caretColor,
+ caretColorError,
+ caretColorWarning,
+ textDecorationColor,
+ border,
+ borderDisabled,
+ borderHover,
+ borderFocus,
+ placeholderColor,
+ placeholderColorDisabled,
+ lineHeightTextarea,
+ colorDisabled,
+ colorFocus,
+ textColorDisabled,
+ boxShadowFocus,
+ iconSize,
+ colorFocusWarning,
+ boxShadowFocusWarning,
+ borderWarning,
+ borderFocusWarning,
+ borderHoverWarning,
+ colorFocusError,
+ boxShadowFocusError,
+ borderError,
+ borderFocusError,
+ borderHoverError,
+ clearSize,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ iconColor,
+ iconColorDisabled,
+ suffixTextColor,
+ countTextColor,
+ countTextColorDisabled,
+ iconColorHover,
+ iconColorPressed,
+ loadingColor,
+ loadingColorError,
+ loadingColorWarning,
+ fontWeight,
+ [createKey("padding", size)]: padding,
+ [createKey("fontSize", size)]: fontSize,
+ [createKey("height", size)]: height
+ }
+ } = themeRef.value;
+ const {
+ left: paddingLeft,
+ right: paddingRight
+ } = getMargin(padding);
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-count-text-color": countTextColor,
+ "--n-count-text-color-disabled": countTextColorDisabled,
+ "--n-color": color,
+ "--n-font-size": fontSize,
+ "--n-font-weight": fontWeight,
+ "--n-border-radius": borderRadius,
+ "--n-height": height,
+ "--n-padding-left": paddingLeft,
+ "--n-padding-right": paddingRight,
+ "--n-text-color": textColor,
+ "--n-caret-color": caretColor,
+ "--n-text-decoration-color": textDecorationColor,
+ "--n-border": border,
+ "--n-border-disabled": borderDisabled,
+ "--n-border-hover": borderHover,
+ "--n-border-focus": borderFocus,
+ "--n-placeholder-color": placeholderColor,
+ "--n-placeholder-color-disabled": placeholderColorDisabled,
+ "--n-icon-size": iconSize,
+ "--n-line-height-textarea": lineHeightTextarea,
+ "--n-color-disabled": colorDisabled,
+ "--n-color-focus": colorFocus,
+ "--n-text-color-disabled": textColorDisabled,
+ "--n-box-shadow-focus": boxShadowFocus,
+ "--n-loading-color": loadingColor,
+ // form warning
+ "--n-caret-color-warning": caretColorWarning,
+ "--n-color-focus-warning": colorFocusWarning,
+ "--n-box-shadow-focus-warning": boxShadowFocusWarning,
+ "--n-border-warning": borderWarning,
+ "--n-border-focus-warning": borderFocusWarning,
+ "--n-border-hover-warning": borderHoverWarning,
+ "--n-loading-color-warning": loadingColorWarning,
+ // form error
+ "--n-caret-color-error": caretColorError,
+ "--n-color-focus-error": colorFocusError,
+ "--n-box-shadow-focus-error": boxShadowFocusError,
+ "--n-border-error": borderError,
+ "--n-border-focus-error": borderFocusError,
+ "--n-border-hover-error": borderHoverError,
+ "--n-loading-color-error": loadingColorError,
+ // clear-button
+ "--n-clear-color": clearColor,
+ "--n-clear-size": clearSize,
+ "--n-clear-color-hover": clearColorHover,
+ "--n-clear-color-pressed": clearColorPressed,
+ "--n-icon-color": iconColor,
+ "--n-icon-color-hover": iconColorHover,
+ "--n-icon-color-pressed": iconColorPressed,
+ "--n-icon-color-disabled": iconColorDisabled,
+ "--n-suffix-text-color": suffixTextColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("input", computed(() => {
+ const {
+ value: size
+ } = mergedSizeRef;
+ return size[0];
+ }), cssVarsRef, props) : void 0;
+ return Object.assign(Object.assign({}, exposedProps), {
+ // DOM ref
+ wrapperElRef,
+ inputElRef,
+ inputMirrorElRef,
+ inputEl2Ref,
+ textareaElRef,
+ textareaMirrorElRef,
+ textareaScrollbarInstRef,
+ // value
+ rtlEnabled: rtlEnabledRef,
+ uncontrolledValue: uncontrolledValueRef,
+ mergedValue: mergedValueRef,
+ passwordVisible: passwordVisibleRef,
+ mergedPlaceholder: mergedPlaceholderRef,
+ showPlaceholder1: showPlaceholder1Ref,
+ showPlaceholder2: showPlaceholder2Ref,
+ mergedFocus: mergedFocusRef,
+ isComposing: isComposingRef,
+ activated: activatedRef,
+ showClearButton,
+ mergedSize: mergedSizeRef,
+ mergedDisabled: mergedDisabledRef,
+ textDecorationStyle: textDecorationStyleRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedBordered: mergedBorderedRef,
+ mergedShowPasswordOn: mergedShowPasswordOnRef,
+ placeholderStyle: placeholderStyleRef,
+ mergedStatus: mergedStatusRef,
+ textAreaScrollContainerWidth: textAreaScrollContainerWidthRef,
+ // methods
+ handleTextAreaScroll,
+ handleCompositionStart,
+ handleCompositionEnd,
+ handleInput,
+ handleInputBlur,
+ handleInputFocus,
+ handleWrapperBlur,
+ handleWrapperFocus,
+ handleMouseEnter,
+ handleMouseLeave,
+ handleMouseDown,
+ handleChange,
+ handleClick,
+ handleClear,
+ handlePasswordToggleClick,
+ handlePasswordToggleMousedown,
+ handleWrapperKeydown,
+ handleWrapperKeyup,
+ handleTextAreaMirrorResize,
+ getTextareaScrollContainer: () => {
+ return textareaElRef.value;
+ },
+ mergedTheme: themeRef,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ });
+ },
+ render() {
+ var _a, _b;
+ const {
+ mergedClsPrefix,
+ mergedStatus,
+ themeClass,
+ type,
+ countGraphemes,
+ onRender
+ } = this;
+ const $slots = this.$slots;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ return h("div", {
+ ref: "wrapperElRef",
+ class: [`${mergedClsPrefix}-input`, themeClass, mergedStatus && `${mergedClsPrefix}-input--${mergedStatus}-status`, {
+ [`${mergedClsPrefix}-input--rtl`]: this.rtlEnabled,
+ [`${mergedClsPrefix}-input--disabled`]: this.mergedDisabled,
+ [`${mergedClsPrefix}-input--textarea`]: type === "textarea",
+ [`${mergedClsPrefix}-input--resizable`]: this.resizable && !this.autosize,
+ [`${mergedClsPrefix}-input--autosize`]: this.autosize,
+ [`${mergedClsPrefix}-input--round`]: this.round && !(type === "textarea"),
+ [`${mergedClsPrefix}-input--pair`]: this.pair,
+ [`${mergedClsPrefix}-input--focus`]: this.mergedFocus,
+ [`${mergedClsPrefix}-input--stateful`]: this.stateful
+ }],
+ style: this.cssVars,
+ tabindex: !this.mergedDisabled && this.passivelyActivated && !this.activated ? 0 : void 0,
+ onFocus: this.handleWrapperFocus,
+ onBlur: this.handleWrapperBlur,
+ onClick: this.handleClick,
+ onMousedown: this.handleMouseDown,
+ onMouseenter: this.handleMouseEnter,
+ onMouseleave: this.handleMouseLeave,
+ onCompositionstart: this.handleCompositionStart,
+ onCompositionend: this.handleCompositionEnd,
+ onKeyup: this.handleWrapperKeyup,
+ onKeydown: this.handleWrapperKeydown
+ }, h("div", {
+ class: `${mergedClsPrefix}-input-wrapper`
+ }, resolveWrappedSlot($slots.prefix, (children) => children && h("div", {
+ class: `${mergedClsPrefix}-input__prefix`
+ }, children)), type === "textarea" ? h(Scrollbar, {
+ ref: "textareaScrollbarInstRef",
+ class: `${mergedClsPrefix}-input__textarea`,
+ container: this.getTextareaScrollContainer,
+ triggerDisplayManually: true,
+ useUnifiedContainer: true,
+ internalHoistYRail: true
+ }, {
+ default: () => {
+ var _a2, _b2;
+ const {
+ textAreaScrollContainerWidth
+ } = this;
+ const scrollContainerWidthStyle = {
+ width: this.autosize && textAreaScrollContainerWidth && `${textAreaScrollContainerWidth}px`
+ };
+ return h(Fragment, null, h("textarea", Object.assign({}, this.inputProps, {
+ ref: "textareaElRef",
+ class: [`${mergedClsPrefix}-input__textarea-el`, (_a2 = this.inputProps) === null || _a2 === void 0 ? void 0 : _a2.class],
+ autofocus: this.autofocus,
+ rows: Number(this.rows),
+ placeholder: this.placeholder,
+ value: this.mergedValue,
+ disabled: this.mergedDisabled,
+ maxlength: countGraphemes ? void 0 : this.maxlength,
+ minlength: countGraphemes ? void 0 : this.minlength,
+ readonly: this.readonly,
+ tabindex: this.passivelyActivated && !this.activated ? -1 : void 0,
+ style: [this.textDecorationStyle[0], (_b2 = this.inputProps) === null || _b2 === void 0 ? void 0 : _b2.style, scrollContainerWidthStyle],
+ onBlur: this.handleInputBlur,
+ onFocus: (e) => {
+ this.handleInputFocus(e, 2);
+ },
+ onInput: this.handleInput,
+ onChange: this.handleChange,
+ onScroll: this.handleTextAreaScroll
+ })), this.showPlaceholder1 ? h("div", {
+ class: `${mergedClsPrefix}-input__placeholder`,
+ style: [this.placeholderStyle, scrollContainerWidthStyle],
+ key: "placeholder"
+ }, this.mergedPlaceholder[0]) : null, this.autosize ? h(VResizeObserver, {
+ onResize: this.handleTextAreaMirrorResize
+ }, {
+ default: () => h("div", {
+ ref: "textareaMirrorElRef",
+ class: `${mergedClsPrefix}-input__textarea-mirror`,
+ key: "mirror"
+ })
+ }) : null);
+ }
+ }) : h("div", {
+ class: `${mergedClsPrefix}-input__input`
+ }, h("input", Object.assign({
+ type: type === "password" && this.mergedShowPasswordOn && this.passwordVisible ? "text" : type
+ }, this.inputProps, {
+ ref: "inputElRef",
+ class: [`${mergedClsPrefix}-input__input-el`, (_a = this.inputProps) === null || _a === void 0 ? void 0 : _a.class],
+ style: [this.textDecorationStyle[0], (_b = this.inputProps) === null || _b === void 0 ? void 0 : _b.style],
+ tabindex: this.passivelyActivated && !this.activated ? -1 : void 0,
+ placeholder: this.mergedPlaceholder[0],
+ disabled: this.mergedDisabled,
+ maxlength: countGraphemes ? void 0 : this.maxlength,
+ minlength: countGraphemes ? void 0 : this.minlength,
+ value: Array.isArray(this.mergedValue) ? this.mergedValue[0] : this.mergedValue,
+ readonly: this.readonly,
+ autofocus: this.autofocus,
+ size: this.attrSize,
+ onBlur: this.handleInputBlur,
+ onFocus: (e) => {
+ this.handleInputFocus(e, 0);
+ },
+ onInput: (e) => {
+ this.handleInput(e, 0);
+ },
+ onChange: (e) => {
+ this.handleChange(e, 0);
+ }
+ })), this.showPlaceholder1 ? h("div", {
+ class: `${mergedClsPrefix}-input__placeholder`
+ }, h("span", null, this.mergedPlaceholder[0])) : null, this.autosize ? h("div", {
+ class: `${mergedClsPrefix}-input__input-mirror`,
+ key: "mirror",
+ ref: "inputMirrorElRef"
+ }, " ") : null), !this.pair && resolveWrappedSlot($slots.suffix, (children) => {
+ return children || this.clearable || this.showCount || this.mergedShowPasswordOn || this.loading !== void 0 ? h("div", {
+ class: `${mergedClsPrefix}-input__suffix`
+ }, [resolveWrappedSlot($slots["clear-icon-placeholder"], (children2) => {
+ return (this.clearable || children2) && h(NBaseClear, {
+ clsPrefix: mergedClsPrefix,
+ show: this.showClearButton,
+ onClear: this.handleClear
+ }, {
+ placeholder: () => children2,
+ icon: () => {
+ var _a2, _b2;
+ return (_b2 = (_a2 = this.$slots)["clear-icon"]) === null || _b2 === void 0 ? void 0 : _b2.call(_a2);
+ }
+ });
+ }), !this.internalLoadingBeforeSuffix ? children : null, this.loading !== void 0 ? h(NBaseSuffix, {
+ clsPrefix: mergedClsPrefix,
+ loading: this.loading,
+ showArrow: false,
+ showClear: false,
+ style: this.cssVars
+ }) : null, this.internalLoadingBeforeSuffix ? children : null, this.showCount && this.type !== "textarea" ? h(WordCount, null, {
+ default: (props) => {
+ var _a2;
+ return (_a2 = $slots.count) === null || _a2 === void 0 ? void 0 : _a2.call($slots, props);
+ }
+ }) : null, this.mergedShowPasswordOn && this.type === "password" ? h("div", {
+ class: `${mergedClsPrefix}-input__eye`,
+ onMousedown: this.handlePasswordToggleMousedown,
+ onClick: this.handlePasswordToggleClick
+ }, this.passwordVisible ? resolveSlot($slots["password-visible-icon"], () => [h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix
+ }, {
+ default: () => h(EyeIcon, null)
+ })]) : resolveSlot($slots["password-invisible-icon"], () => [h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix
+ }, {
+ default: () => h(EyeOffIcon, null)
+ })])) : null]) : null;
+ })), this.pair ? h("span", {
+ class: `${mergedClsPrefix}-input__separator`
+ }, resolveSlot($slots.separator, () => [this.separator])) : null, this.pair ? h("div", {
+ class: `${mergedClsPrefix}-input-wrapper`
+ }, h("div", {
+ class: `${mergedClsPrefix}-input__input`
+ }, h("input", {
+ ref: "inputEl2Ref",
+ type: this.type,
+ class: `${mergedClsPrefix}-input__input-el`,
+ tabindex: this.passivelyActivated && !this.activated ? -1 : void 0,
+ placeholder: this.mergedPlaceholder[1],
+ disabled: this.mergedDisabled,
+ maxlength: countGraphemes ? void 0 : this.maxlength,
+ minlength: countGraphemes ? void 0 : this.minlength,
+ value: Array.isArray(this.mergedValue) ? this.mergedValue[1] : void 0,
+ readonly: this.readonly,
+ style: this.textDecorationStyle[1],
+ onBlur: this.handleInputBlur,
+ onFocus: (e) => {
+ this.handleInputFocus(e, 1);
+ },
+ onInput: (e) => {
+ this.handleInput(e, 1);
+ },
+ onChange: (e) => {
+ this.handleChange(e, 1);
+ }
+ }), this.showPlaceholder2 ? h("div", {
+ class: `${mergedClsPrefix}-input__placeholder`
+ }, h("span", null, this.mergedPlaceholder[1])) : null), resolveWrappedSlot($slots.suffix, (children) => {
+ return (this.clearable || children) && h("div", {
+ class: `${mergedClsPrefix}-input__suffix`
+ }, [this.clearable && h(NBaseClear, {
+ clsPrefix: mergedClsPrefix,
+ show: this.showClearButton,
+ onClear: this.handleClear
+ }, {
+ icon: () => {
+ var _a2;
+ return (_a2 = $slots["clear-icon"]) === null || _a2 === void 0 ? void 0 : _a2.call($slots);
+ },
+ placeholder: () => {
+ var _a2;
+ return (_a2 = $slots["clear-icon-placeholder"]) === null || _a2 === void 0 ? void 0 : _a2.call($slots);
+ }
+ }), children]);
+ })) : null, this.mergedBordered ? h("div", {
+ class: `${mergedClsPrefix}-input__border`
+ }) : null, this.mergedBordered ? h("div", {
+ class: `${mergedClsPrefix}-input__state-border`
+ }) : null, this.showCount && type === "textarea" ? h(WordCount, null, {
+ default: (props) => {
+ var _a2;
+ const {
+ renderCount
+ } = this;
+ if (renderCount) {
+ return renderCount(props);
+ }
+ return (_a2 = $slots.count) === null || _a2 === void 0 ? void 0 : _a2.call($slots, props);
+ }
+ }) : null);
+ }
+});
+const style = cB("switch", `
+ height: var(--n-height);
+ min-width: var(--n-width);
+ vertical-align: middle;
+ user-select: none;
+ -webkit-user-select: none;
+ display: inline-flex;
+ outline: none;
+ justify-content: center;
+ align-items: center;
+`, [cE("children-placeholder", `
+ height: var(--n-rail-height);
+ display: flex;
+ flex-direction: column;
+ overflow: hidden;
+ pointer-events: none;
+ visibility: hidden;
+ `), cE("rail-placeholder", `
+ display: flex;
+ flex-wrap: none;
+ `), cE("button-placeholder", `
+ width: calc(1.75 * var(--n-rail-height));
+ height: var(--n-rail-height);
+ `), cB("base-loading", `
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ transform: translateX(-50%) translateY(-50%);
+ font-size: calc(var(--n-button-width) - 4px);
+ color: var(--n-loading-color);
+ transition: color .3s var(--n-bezier);
+ `, [iconSwitchTransition({
+ left: "50%",
+ top: "50%",
+ originalTransform: "translateX(-50%) translateY(-50%)"
+})]), cE("checked, unchecked", `
+ transition: color .3s var(--n-bezier);
+ color: var(--n-text-color);
+ box-sizing: border-box;
+ position: absolute;
+ white-space: nowrap;
+ top: 0;
+ bottom: 0;
+ display: flex;
+ align-items: center;
+ line-height: 1;
+ `), cE("checked", `
+ right: 0;
+ padding-right: calc(1.25 * var(--n-rail-height) - var(--n-offset));
+ `), cE("unchecked", `
+ left: 0;
+ justify-content: flex-end;
+ padding-left: calc(1.25 * var(--n-rail-height) - var(--n-offset));
+ `), c("&:focus", [cE("rail", `
+ box-shadow: var(--n-box-shadow-focus);
+ `)]), cM("round", [cE("rail", "border-radius: calc(var(--n-rail-height) / 2);", [cE("button", "border-radius: calc(var(--n-button-height) / 2);")])]), cNotM("disabled", [cNotM("icon", [cM("rubber-band", [cM("pressed", [cE("rail", [cE("button", "max-width: var(--n-button-width-pressed);")])]), cE("rail", [c("&:active", [cE("button", "max-width: var(--n-button-width-pressed);")])]), cM("active", [cM("pressed", [cE("rail", [cE("button", "left: calc(100% - var(--n-offset) - var(--n-button-width-pressed));")])]), cE("rail", [c("&:active", [cE("button", "left: calc(100% - var(--n-offset) - var(--n-button-width-pressed));")])])])])])]), cM("active", [cE("rail", [cE("button", "left: calc(100% - var(--n-button-width) - var(--n-offset))")])]), cE("rail", `
+ overflow: hidden;
+ height: var(--n-rail-height);
+ min-width: var(--n-rail-width);
+ border-radius: var(--n-rail-border-radius);
+ cursor: pointer;
+ position: relative;
+ transition:
+ opacity .3s var(--n-bezier),
+ background .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier);
+ background-color: var(--n-rail-color);
+ `, [cE("button-icon", `
+ color: var(--n-icon-color);
+ transition: color .3s var(--n-bezier);
+ font-size: calc(var(--n-button-height) - 4px);
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ line-height: 1;
+ `, [iconSwitchTransition()]), cE("button", `
+ align-items: center;
+ top: var(--n-offset);
+ left: var(--n-offset);
+ height: var(--n-button-height);
+ width: var(--n-button-width-pressed);
+ max-width: var(--n-button-width);
+ border-radius: var(--n-button-border-radius);
+ background-color: var(--n-button-color);
+ box-shadow: var(--n-button-box-shadow);
+ box-sizing: border-box;
+ cursor: inherit;
+ content: "";
+ position: absolute;
+ transition:
+ background-color .3s var(--n-bezier),
+ left .3s var(--n-bezier),
+ opacity .3s var(--n-bezier),
+ max-width .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier);
+ `)]), cM("active", [cE("rail", "background-color: var(--n-rail-color-active);")]), cM("loading", [cE("rail", `
+ cursor: wait;
+ `)]), cM("disabled", [cE("rail", `
+ cursor: not-allowed;
+ opacity: .5;
+ `)])]);
+const switchProps = Object.assign(Object.assign({}, useTheme.props), {
+ size: {
+ type: String,
+ default: "medium"
+ },
+ value: {
+ type: [String, Number, Boolean],
+ default: void 0
+ },
+ loading: Boolean,
+ defaultValue: {
+ type: [String, Number, Boolean],
+ default: false
+ },
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ round: {
+ type: Boolean,
+ default: true
+ },
+ "onUpdate:value": [Function, Array],
+ onUpdateValue: [Function, Array],
+ checkedValue: {
+ type: [String, Number, Boolean],
+ default: true
+ },
+ uncheckedValue: {
+ type: [String, Number, Boolean],
+ default: false
+ },
+ railStyle: Function,
+ rubberBand: {
+ type: Boolean,
+ default: true
+ },
+ /** @deprecated */
+ onChange: [Function, Array]
+});
+let supportCssMax;
+const __unplugin_components_3 = defineComponent({
+ name: "Switch",
+ props: switchProps,
+ setup(props) {
+ if (supportCssMax === void 0) {
+ if (typeof CSS !== "undefined") {
+ if (typeof CSS.supports !== "undefined") {
+ supportCssMax = CSS.supports("width", "max(1px)");
+ } else {
+ supportCssMax = false;
+ }
+ } else {
+ supportCssMax = true;
+ }
+ }
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Switch", "-switch", style, switchLight, props, mergedClsPrefixRef);
+ const formItem = useFormItem(props);
+ const {
+ mergedSizeRef,
+ mergedDisabledRef
+ } = formItem;
+ const uncontrolledValueRef = ref(props.defaultValue);
+ const controlledValueRef = toRef(props, "value");
+ const mergedValueRef = useMergedState(controlledValueRef, uncontrolledValueRef);
+ const checkedRef = computed(() => {
+ return mergedValueRef.value === props.checkedValue;
+ });
+ const pressedRef = ref(false);
+ const focusedRef = ref(false);
+ const mergedRailStyleRef = computed(() => {
+ const {
+ railStyle
+ } = props;
+ if (!railStyle) return void 0;
+ return railStyle({
+ focused: focusedRef.value,
+ checked: checkedRef.value
+ });
+ });
+ function doUpdateValue(value) {
+ const {
+ "onUpdate:value": _onUpdateValue,
+ onChange,
+ onUpdateValue
+ } = props;
+ const {
+ nTriggerFormInput,
+ nTriggerFormChange
+ } = formItem;
+ if (_onUpdateValue) call(_onUpdateValue, value);
+ if (onUpdateValue) call(onUpdateValue, value);
+ if (onChange) call(onChange, value);
+ uncontrolledValueRef.value = value;
+ nTriggerFormInput();
+ nTriggerFormChange();
+ }
+ function doFocus() {
+ const {
+ nTriggerFormFocus
+ } = formItem;
+ nTriggerFormFocus();
+ }
+ function doBlur() {
+ const {
+ nTriggerFormBlur
+ } = formItem;
+ nTriggerFormBlur();
+ }
+ function handleClick() {
+ if (props.loading || mergedDisabledRef.value) return;
+ if (mergedValueRef.value !== props.checkedValue) {
+ doUpdateValue(props.checkedValue);
+ } else {
+ doUpdateValue(props.uncheckedValue);
+ }
+ }
+ function handleFocus() {
+ focusedRef.value = true;
+ doFocus();
+ }
+ function handleBlur() {
+ focusedRef.value = false;
+ doBlur();
+ pressedRef.value = false;
+ }
+ function handleKeyup(e) {
+ if (props.loading || mergedDisabledRef.value) return;
+ if (e.key === " ") {
+ if (mergedValueRef.value !== props.checkedValue) {
+ doUpdateValue(props.checkedValue);
+ } else {
+ doUpdateValue(props.uncheckedValue);
+ }
+ pressedRef.value = false;
+ }
+ }
+ function handleKeydown(e) {
+ if (props.loading || mergedDisabledRef.value) return;
+ if (e.key === " ") {
+ e.preventDefault();
+ pressedRef.value = true;
+ }
+ }
+ const cssVarsRef = computed(() => {
+ const {
+ value: size
+ } = mergedSizeRef;
+ const {
+ self: {
+ opacityDisabled,
+ railColor,
+ railColorActive,
+ buttonBoxShadow,
+ buttonColor,
+ boxShadowFocus,
+ loadingColor,
+ textColor,
+ iconColor,
+ [createKey("buttonHeight", size)]: buttonHeight,
+ [createKey("buttonWidth", size)]: buttonWidth,
+ [createKey("buttonWidthPressed", size)]: buttonWidthPressed,
+ [createKey("railHeight", size)]: railHeight,
+ [createKey("railWidth", size)]: railWidth,
+ [createKey("railBorderRadius", size)]: railBorderRadius,
+ [createKey("buttonBorderRadius", size)]: buttonBorderRadius
+ },
+ common: {
+ cubicBezierEaseInOut
+ }
+ } = themeRef.value;
+ let offset;
+ let height;
+ let width;
+ if (supportCssMax) {
+ offset = `calc((${railHeight} - ${buttonHeight}) / 2)`;
+ height = `max(${railHeight}, ${buttonHeight})`;
+ width = `max(${railWidth}, calc(${railWidth} + ${buttonHeight} - ${railHeight}))`;
+ } else {
+ offset = pxfy((depx(railHeight) - depx(buttonHeight)) / 2);
+ height = pxfy(Math.max(depx(railHeight), depx(buttonHeight)));
+ width = depx(railHeight) > depx(buttonHeight) ? railWidth : pxfy(depx(railWidth) + depx(buttonHeight) - depx(railHeight));
+ }
+ return {
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-button-border-radius": buttonBorderRadius,
+ "--n-button-box-shadow": buttonBoxShadow,
+ "--n-button-color": buttonColor,
+ "--n-button-width": buttonWidth,
+ "--n-button-width-pressed": buttonWidthPressed,
+ "--n-button-height": buttonHeight,
+ "--n-height": height,
+ "--n-offset": offset,
+ "--n-opacity-disabled": opacityDisabled,
+ "--n-rail-border-radius": railBorderRadius,
+ "--n-rail-color": railColor,
+ "--n-rail-color-active": railColorActive,
+ "--n-rail-height": railHeight,
+ "--n-rail-width": railWidth,
+ "--n-width": width,
+ "--n-box-shadow-focus": boxShadowFocus,
+ "--n-loading-color": loadingColor,
+ "--n-text-color": textColor,
+ "--n-icon-color": iconColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("switch", computed(() => {
+ return mergedSizeRef.value[0];
+ }), cssVarsRef, props) : void 0;
+ return {
+ handleClick,
+ handleBlur,
+ handleFocus,
+ handleKeyup,
+ handleKeydown,
+ mergedRailStyle: mergedRailStyleRef,
+ pressed: pressedRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedValue: mergedValueRef,
+ checked: checkedRef,
+ mergedDisabled: mergedDisabledRef,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const {
+ mergedClsPrefix,
+ mergedDisabled,
+ checked,
+ mergedRailStyle,
+ onRender,
+ $slots
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ const {
+ checked: checkedSlot,
+ unchecked: uncheckedSlot,
+ icon: iconSlot,
+ "checked-icon": checkedIconSlot,
+ "unchecked-icon": uncheckedIconSlot
+ } = $slots;
+ const hasIcon = !(isSlotEmpty(iconSlot) && isSlotEmpty(checkedIconSlot) && isSlotEmpty(uncheckedIconSlot));
+ return h("div", {
+ role: "switch",
+ "aria-checked": checked,
+ class: [`${mergedClsPrefix}-switch`, this.themeClass, hasIcon && `${mergedClsPrefix}-switch--icon`, checked && `${mergedClsPrefix}-switch--active`, mergedDisabled && `${mergedClsPrefix}-switch--disabled`, this.round && `${mergedClsPrefix}-switch--round`, this.loading && `${mergedClsPrefix}-switch--loading`, this.pressed && `${mergedClsPrefix}-switch--pressed`, this.rubberBand && `${mergedClsPrefix}-switch--rubber-band`],
+ tabindex: !this.mergedDisabled ? 0 : void 0,
+ style: this.cssVars,
+ onClick: this.handleClick,
+ onFocus: this.handleFocus,
+ onBlur: this.handleBlur,
+ onKeyup: this.handleKeyup,
+ onKeydown: this.handleKeydown
+ }, h("div", {
+ class: `${mergedClsPrefix}-switch__rail`,
+ "aria-hidden": "true",
+ style: mergedRailStyle
+ }, resolveWrappedSlot(checkedSlot, (checkedSlotChildren) => resolveWrappedSlot(uncheckedSlot, (uncheckedSlotChildren) => {
+ if (checkedSlotChildren || uncheckedSlotChildren) {
+ return h("div", {
+ "aria-hidden": true,
+ class: `${mergedClsPrefix}-switch__children-placeholder`
+ }, h("div", {
+ class: `${mergedClsPrefix}-switch__rail-placeholder`
+ }, h("div", {
+ class: `${mergedClsPrefix}-switch__button-placeholder`
+ }), checkedSlotChildren), h("div", {
+ class: `${mergedClsPrefix}-switch__rail-placeholder`
+ }, h("div", {
+ class: `${mergedClsPrefix}-switch__button-placeholder`
+ }), uncheckedSlotChildren));
+ }
+ return null;
+ })), h("div", {
+ class: `${mergedClsPrefix}-switch__button`
+ }, resolveWrappedSlot(iconSlot, (icon) => resolveWrappedSlot(checkedIconSlot, (checkedIcon) => resolveWrappedSlot(uncheckedIconSlot, (uncheckedIcon) => {
+ return h(NIconSwitchTransition, null, {
+ default: () => this.loading ? h(NBaseLoading, {
+ key: "loading",
+ clsPrefix: mergedClsPrefix,
+ strokeWidth: 20
+ }) : this.checked && (checkedIcon || icon) ? h("div", {
+ class: `${mergedClsPrefix}-switch__button-icon`,
+ key: checkedIcon ? "checked-icon" : "icon"
+ }, checkedIcon || icon) : !this.checked && (uncheckedIcon || icon) ? h("div", {
+ class: `${mergedClsPrefix}-switch__button-icon`,
+ key: uncheckedIcon ? "unchecked-icon" : "icon"
+ }, uncheckedIcon || icon) : null
+ });
+ }))), resolveWrappedSlot(checkedSlot, (children) => children && h("div", {
+ key: "checked",
+ class: `${mergedClsPrefix}-switch__checked`
+ }, children)), resolveWrappedSlot(uncheckedSlot, (children) => children && h("div", {
+ key: "unchecked",
+ class: `${mergedClsPrefix}-switch__unchecked`
+ }, children)))));
+ }
+});
+export {
+ __unplugin_components_1 as _,
+ __unplugin_components_3 as a
+};
diff --git a/out/renderer/assets/Switch-D3Z_Vg3u.js.gz b/out/renderer/assets/Switch-D3Z_Vg3u.js.gz
new file mode 100644
index 0000000..3e65ca6
Binary files /dev/null and b/out/renderer/assets/Switch-D3Z_Vg3u.js.gz differ
diff --git a/out/renderer/assets/Tag-C0oC92WF.js b/out/renderer/assets/Tag-C0oC92WF.js
new file mode 100644
index 0000000..1c3002f
--- /dev/null
+++ b/out/renderer/assets/Tag-C0oC92WF.js
@@ -0,0 +1,344 @@
+import { p as cB, W as cM, Y as cE, V as cNotM, m as c, q as useTheme, d as defineComponent, r as ref, x as useConfig, by as tagLight, $ as provide, A as toRef, F as useRtl, G as computed, ao as createKey, bs as getMargin, ap as useThemeClass, bx as color2Class, I as resolveWrappedSlot, l as h, bz as NBaseClose, aL as createInjectionKey, L as call } from "./index-DKaFsuse.js";
+const commonProps = {
+ color: Object,
+ type: {
+ type: String,
+ default: "default"
+ },
+ round: Boolean,
+ size: {
+ type: String,
+ default: "medium"
+ },
+ closable: Boolean,
+ disabled: {
+ type: Boolean,
+ default: void 0
+ }
+};
+const style = cB("tag", `
+ --n-close-margin: var(--n-close-margin-top) var(--n-close-margin-right) var(--n-close-margin-bottom) var(--n-close-margin-left);
+ white-space: nowrap;
+ position: relative;
+ box-sizing: border-box;
+ cursor: default;
+ display: inline-flex;
+ align-items: center;
+ flex-wrap: nowrap;
+ padding: var(--n-padding);
+ border-radius: var(--n-border-radius);
+ color: var(--n-text-color);
+ background-color: var(--n-color);
+ transition:
+ border-color .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier),
+ opacity .3s var(--n-bezier);
+ line-height: 1;
+ height: var(--n-height);
+ font-size: var(--n-font-size);
+`, [cM("strong", `
+ font-weight: var(--n-font-weight-strong);
+ `), cE("border", `
+ pointer-events: none;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ border-radius: inherit;
+ border: var(--n-border);
+ transition: border-color .3s var(--n-bezier);
+ `), cE("icon", `
+ display: flex;
+ margin: 0 4px 0 0;
+ color: var(--n-text-color);
+ transition: color .3s var(--n-bezier);
+ font-size: var(--n-avatar-size-override);
+ `), cE("avatar", `
+ display: flex;
+ margin: 0 6px 0 0;
+ `), cE("close", `
+ margin: var(--n-close-margin);
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ `), cM("round", `
+ padding: 0 calc(var(--n-height) / 3);
+ border-radius: calc(var(--n-height) / 2);
+ `, [cE("icon", `
+ margin: 0 4px 0 calc((var(--n-height) - 8px) / -2);
+ `), cE("avatar", `
+ margin: 0 6px 0 calc((var(--n-height) - 8px) / -2);
+ `), cM("closable", `
+ padding: 0 calc(var(--n-height) / 4) 0 calc(var(--n-height) / 3);
+ `)]), cM("icon, avatar", [cM("round", `
+ padding: 0 calc(var(--n-height) / 3) 0 calc(var(--n-height) / 2);
+ `)]), cM("disabled", `
+ cursor: not-allowed !important;
+ opacity: var(--n-opacity-disabled);
+ `), cM("checkable", `
+ cursor: pointer;
+ box-shadow: none;
+ color: var(--n-text-color-checkable);
+ background-color: var(--n-color-checkable);
+ `, [cNotM("disabled", [c("&:hover", "background-color: var(--n-color-hover-checkable);", [cNotM("checked", "color: var(--n-text-color-hover-checkable);")]), c("&:active", "background-color: var(--n-color-pressed-checkable);", [cNotM("checked", "color: var(--n-text-color-pressed-checkable);")])]), cM("checked", `
+ color: var(--n-text-color-checked);
+ background-color: var(--n-color-checked);
+ `, [cNotM("disabled", [c("&:hover", "background-color: var(--n-color-checked-hover);"), c("&:active", "background-color: var(--n-color-checked-pressed);")])])])]);
+const tagProps = Object.assign(Object.assign(Object.assign({}, useTheme.props), commonProps), {
+ bordered: {
+ type: Boolean,
+ default: void 0
+ },
+ checked: Boolean,
+ checkable: Boolean,
+ strong: Boolean,
+ triggerClickOnClose: Boolean,
+ onClose: [Array, Function],
+ onMouseenter: Function,
+ onMouseleave: Function,
+ "onUpdate:checked": Function,
+ onUpdateChecked: Function,
+ // private
+ internalCloseFocusable: {
+ type: Boolean,
+ default: true
+ },
+ internalCloseIsButtonTag: {
+ type: Boolean,
+ default: true
+ },
+ // deprecated
+ onCheckedChange: Function
+});
+const tagInjectionKey = createInjectionKey("n-tag");
+const __unplugin_components_4 = defineComponent({
+ name: "Tag",
+ props: tagProps,
+ setup(props) {
+ const contentRef = ref(null);
+ const {
+ mergedBorderedRef,
+ mergedClsPrefixRef,
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const themeRef = useTheme("Tag", "-tag", style, tagLight, props, mergedClsPrefixRef);
+ provide(tagInjectionKey, {
+ roundRef: toRef(props, "round")
+ });
+ function handleClick() {
+ if (!props.disabled) {
+ if (props.checkable) {
+ const {
+ checked,
+ onCheckedChange,
+ onUpdateChecked,
+ "onUpdate:checked": _onUpdateChecked
+ } = props;
+ if (onUpdateChecked) onUpdateChecked(!checked);
+ if (_onUpdateChecked) _onUpdateChecked(!checked);
+ if (onCheckedChange) onCheckedChange(!checked);
+ }
+ }
+ }
+ function handleCloseClick(e) {
+ if (!props.triggerClickOnClose) {
+ e.stopPropagation();
+ }
+ if (!props.disabled) {
+ const {
+ onClose
+ } = props;
+ if (onClose) call(onClose, e);
+ }
+ }
+ const tagPublicMethods = {
+ setTextContent(textContent) {
+ const {
+ value
+ } = contentRef;
+ if (value) value.textContent = textContent;
+ }
+ };
+ const rtlEnabledRef = useRtl("Tag", mergedRtlRef, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ type,
+ size,
+ color: {
+ color,
+ textColor
+ } = {}
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self: {
+ padding,
+ closeMargin,
+ borderRadius,
+ opacityDisabled,
+ textColorCheckable,
+ textColorHoverCheckable,
+ textColorPressedCheckable,
+ textColorChecked,
+ colorCheckable,
+ colorHoverCheckable,
+ colorPressedCheckable,
+ colorChecked,
+ colorCheckedHover,
+ colorCheckedPressed,
+ closeBorderRadius,
+ fontWeightStrong,
+ [createKey("colorBordered", type)]: colorBordered,
+ [createKey("closeSize", size)]: closeSize,
+ [createKey("closeIconSize", size)]: closeIconSize,
+ [createKey("fontSize", size)]: fontSize,
+ [createKey("height", size)]: height,
+ [createKey("color", type)]: typedColor,
+ [createKey("textColor", type)]: typeTextColor,
+ [createKey("border", type)]: border,
+ [createKey("closeIconColor", type)]: closeIconColor,
+ [createKey("closeIconColorHover", type)]: closeIconColorHover,
+ [createKey("closeIconColorPressed", type)]: closeIconColorPressed,
+ [createKey("closeColorHover", type)]: closeColorHover,
+ [createKey("closeColorPressed", type)]: closeColorPressed
+ }
+ } = themeRef.value;
+ const closeMarginDiscrete = getMargin(closeMargin);
+ return {
+ "--n-font-weight-strong": fontWeightStrong,
+ "--n-avatar-size-override": `calc(${height} - 8px)`,
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-border-radius": borderRadius,
+ "--n-border": border,
+ "--n-close-icon-size": closeIconSize,
+ "--n-close-color-pressed": closeColorPressed,
+ "--n-close-color-hover": closeColorHover,
+ "--n-close-border-radius": closeBorderRadius,
+ "--n-close-icon-color": closeIconColor,
+ "--n-close-icon-color-hover": closeIconColorHover,
+ "--n-close-icon-color-pressed": closeIconColorPressed,
+ "--n-close-icon-color-disabled": closeIconColor,
+ "--n-close-margin-top": closeMarginDiscrete.top,
+ "--n-close-margin-right": closeMarginDiscrete.right,
+ "--n-close-margin-bottom": closeMarginDiscrete.bottom,
+ "--n-close-margin-left": closeMarginDiscrete.left,
+ "--n-close-size": closeSize,
+ "--n-color": color || (mergedBorderedRef.value ? colorBordered : typedColor),
+ "--n-color-checkable": colorCheckable,
+ "--n-color-checked": colorChecked,
+ "--n-color-checked-hover": colorCheckedHover,
+ "--n-color-checked-pressed": colorCheckedPressed,
+ "--n-color-hover-checkable": colorHoverCheckable,
+ "--n-color-pressed-checkable": colorPressedCheckable,
+ "--n-font-size": fontSize,
+ "--n-height": height,
+ "--n-opacity-disabled": opacityDisabled,
+ "--n-padding": padding,
+ "--n-text-color": textColor || typeTextColor,
+ "--n-text-color-checkable": textColorCheckable,
+ "--n-text-color-checked": textColorChecked,
+ "--n-text-color-hover-checkable": textColorHoverCheckable,
+ "--n-text-color-pressed-checkable": textColorPressedCheckable
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("tag", computed(() => {
+ let hash = "";
+ const {
+ type,
+ size,
+ color: {
+ color,
+ textColor
+ } = {}
+ } = props;
+ hash += type[0];
+ hash += size[0];
+ if (color) {
+ hash += `a${color2Class(color)}`;
+ }
+ if (textColor) {
+ hash += `b${color2Class(textColor)}`;
+ }
+ if (mergedBorderedRef.value) {
+ hash += "c";
+ }
+ return hash;
+ }), cssVarsRef, props) : void 0;
+ return Object.assign(Object.assign({}, tagPublicMethods), {
+ rtlEnabled: rtlEnabledRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ contentRef,
+ mergedBordered: mergedBorderedRef,
+ handleClick,
+ handleCloseClick,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ });
+ },
+ render() {
+ var _a, _b;
+ const {
+ mergedClsPrefix,
+ rtlEnabled,
+ closable,
+ color: {
+ borderColor
+ } = {},
+ round,
+ onRender,
+ $slots
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ const avatarNode = resolveWrappedSlot($slots.avatar, (children) => children && h("div", {
+ class: `${mergedClsPrefix}-tag__avatar`
+ }, children));
+ const iconNode = resolveWrappedSlot($slots.icon, (children) => children && h("div", {
+ class: `${mergedClsPrefix}-tag__icon`
+ }, children));
+ return h("div", {
+ class: [`${mergedClsPrefix}-tag`, this.themeClass, {
+ [`${mergedClsPrefix}-tag--rtl`]: rtlEnabled,
+ [`${mergedClsPrefix}-tag--strong`]: this.strong,
+ [`${mergedClsPrefix}-tag--disabled`]: this.disabled,
+ [`${mergedClsPrefix}-tag--checkable`]: this.checkable,
+ [`${mergedClsPrefix}-tag--checked`]: this.checkable && this.checked,
+ [`${mergedClsPrefix}-tag--round`]: round,
+ [`${mergedClsPrefix}-tag--avatar`]: avatarNode,
+ [`${mergedClsPrefix}-tag--icon`]: iconNode,
+ [`${mergedClsPrefix}-tag--closable`]: closable
+ }],
+ style: this.cssVars,
+ onClick: this.handleClick,
+ onMouseenter: this.onMouseenter,
+ onMouseleave: this.onMouseleave
+ }, iconNode || avatarNode, h("span", {
+ class: `${mergedClsPrefix}-tag__content`,
+ ref: "contentRef"
+ }, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a)), !this.checkable && closable ? h(NBaseClose, {
+ clsPrefix: mergedClsPrefix,
+ class: `${mergedClsPrefix}-tag__close`,
+ disabled: this.disabled,
+ onClick: this.handleCloseClick,
+ focusable: this.internalCloseFocusable,
+ round,
+ isButtonTag: this.internalCloseIsButtonTag,
+ absolute: true
+ }) : null, !this.checkable && this.mergedBordered ? h("div", {
+ class: `${mergedClsPrefix}-tag__border`,
+ style: {
+ borderColor
+ }
+ }) : null);
+ }
+});
+export {
+ __unplugin_components_4 as _,
+ tagInjectionKey as t
+};
diff --git a/out/renderer/assets/Tag-C0oC92WF.js.gz b/out/renderer/assets/Tag-C0oC92WF.js.gz
new file mode 100644
index 0000000..debcfbe
Binary files /dev/null and b/out/renderer/assets/Tag-C0oC92WF.js.gz differ
diff --git a/out/renderer/assets/TitleBar-Bl1cFyS0.js b/out/renderer/assets/TitleBar-Bl1cFyS0.js
new file mode 100644
index 0000000..93ebdd2
--- /dev/null
+++ b/out/renderer/assets/TitleBar-Bl1cFyS0.js
@@ -0,0 +1,63 @@
+import { as as inject, ce as dialogApiInjectionKey, bi as throwError, d as defineComponent, j as openBlock, c as createElementBlock, b as createBaseVNode, R as isElectron, _ as _export_sfc } from "./index-DKaFsuse.js";
+function useDialog() {
+ const dialog = inject(dialogApiInjectionKey, null);
+ if (dialog === null) {
+ throwError("use-dialog", "No outer founded.");
+ }
+ return dialog;
+}
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "TitleBar",
+ setup(__props) {
+ const dialog = useDialog();
+ const minimize = () => {
+ if (!isElectron) {
+ return;
+ }
+ window.api.minimize();
+ };
+ const close = () => {
+ if (!isElectron) {
+ return;
+ }
+ dialog.warning({
+ title: "提示",
+ content: "确定要退出吗?",
+ positiveText: "最小化",
+ negativeText: "关闭",
+ onPositiveClick: () => {
+ window.api.minimize();
+ },
+ onNegativeClick: () => {
+ window.api.close();
+ }
+ });
+ };
+ const drag = (event) => {
+ if (!isElectron) {
+ return;
+ }
+ window.api.dragStart(event);
+ };
+ return (_ctx, _cache) => {
+ return openBlock(), createElementBlock("div", {
+ id: "title-bar",
+ onMousedown: drag
+ }, [
+ _cache[2] || (_cache[2] = createBaseVNode("div", { id: "title" }, "Alger Music", -1)),
+ createBaseVNode("div", { id: "buttons" }, [
+ createBaseVNode("button", { onClick: minimize }, _cache[0] || (_cache[0] = [
+ createBaseVNode("i", { class: "iconfont icon-minisize" }, null, -1)
+ ])),
+ createBaseVNode("button", { onClick: close }, _cache[1] || (_cache[1] = [
+ createBaseVNode("i", { class: "iconfont icon-close" }, null, -1)
+ ]))
+ ])
+ ], 32);
+ };
+ }
+});
+const TitleBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-6ad4ce60"]]);
+export {
+ TitleBar as default
+};
diff --git a/out/renderer/assets/TitleBar-Bl1cFyS0.js.gz b/out/renderer/assets/TitleBar-Bl1cFyS0.js.gz
new file mode 100644
index 0000000..dc21eaa
Binary files /dev/null and b/out/renderer/assets/TitleBar-Bl1cFyS0.js.gz differ
diff --git a/out/renderer/assets/TitleBar-DxNBjVsT.css b/out/renderer/assets/TitleBar-DxNBjVsT.css
new file mode 100644
index 0000000..6f68512
--- /dev/null
+++ b/out/renderer/assets/TitleBar-DxNBjVsT.css
@@ -0,0 +1,37 @@
+#title-bar[data-v-6ad4ce60] {
+ -webkit-app-region: drag;
+ position: relative;
+ display: flex;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+ justify-content: space-between;
+ padding-left: 1.5rem;
+ padding-right: 1.5rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(0 0 0 / var(--tw-text-opacity, 1));
+}#title-bar[data-v-6ad4ce60]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}#title-bar[data-v-6ad4ce60] {
+ z-index: 9999999;
+}
+#buttons[data-v-6ad4ce60] {
+ display: flex;
+ gap: 1rem;
+ -webkit-app-region: no-drag;
+}
+button[data-v-6ad4ce60] {
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+button[data-v-6ad4ce60]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+button[data-v-6ad4ce60]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
\ No newline at end of file
diff --git a/src/assets/alipay.png b/out/renderer/assets/alipay-CcfmUela.png
similarity index 100%
rename from src/assets/alipay.png
rename to out/renderer/assets/alipay-CcfmUela.png
diff --git a/out/renderer/assets/home-BXGE9AqN.js b/out/renderer/assets/home-BXGE9AqN.js
new file mode 100644
index 0000000..dfbcc25
--- /dev/null
+++ b/out/renderer/assets/home-BXGE9AqN.js
@@ -0,0 +1,31 @@
+import { ad as request } from "./index-DKaFsuse.js";
+const getHotSinger = (params) => {
+ return request.get("/top/artists", { params });
+};
+const getSearchKeyword = () => {
+ return request.get("/search/default");
+};
+const getHotSearch = () => {
+ return request.get("/search/hot/detail");
+};
+const getPlaylistCategory = () => {
+ return request.get("/playlist/catlist");
+};
+const getRecommendMusic = (params) => {
+ return request.get("/personalized/newsong", { params });
+};
+const getDayRecommend = () => {
+ return request.get("/recommend/songs");
+};
+const getNewAlbum = () => {
+ return request.get("/album/newest");
+};
+export {
+ getNewAlbum as a,
+ getHotSinger as b,
+ getDayRecommend as c,
+ getRecommendMusic as d,
+ getHotSearch as e,
+ getSearchKeyword as f,
+ getPlaylistCategory as g
+};
diff --git a/public/icon.png b/out/renderer/assets/icon-mGmYaNg4.png
similarity index 100%
rename from public/icon.png
rename to out/renderer/assets/icon-mGmYaNg4.png
diff --git a/public/icon/iconfont.woff b/out/renderer/assets/iconfont-53c_NoX9.woff
similarity index 100%
rename from public/icon/iconfont.woff
rename to out/renderer/assets/iconfont-53c_NoX9.woff
diff --git a/public/icon/iconfont.ttf b/out/renderer/assets/iconfont-Cio8idH0.ttf
similarity index 100%
rename from public/icon/iconfont.ttf
rename to out/renderer/assets/iconfont-Cio8idH0.ttf
diff --git a/public/icon/iconfont.woff2 b/out/renderer/assets/iconfont-DzQUHqRQ.woff2
similarity index 100%
rename from public/icon/iconfont.woff2
rename to out/renderer/assets/iconfont-DzQUHqRQ.woff2
diff --git a/out/renderer/assets/index-B-m4kL_6.css b/out/renderer/assets/index-B-m4kL_6.css
new file mode 100644
index 0000000..c9ea2bb
--- /dev/null
+++ b/out/renderer/assets/index-B-m4kL_6.css
@@ -0,0 +1,43 @@
+.favorite-page[data-v-2d1a7423] {display: flex;height: 100%;flex-direction: column;padding-top: 0.5rem;--tw-bg-opacity: 1;background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1))
+}.favorite-page[data-v-2d1a7423]:is(.dark *) {--tw-bg-opacity: 1;background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1))
+}
+.favorite-page .favorite-header[data-v-2d1a7423] {display: flex;flex-shrink: 0;align-items: center;justify-content: space-between;padding-left: 1rem;padding-right: 1rem
+}
+.favorite-page .favorite-header h2[data-v-2d1a7423] {padding-bottom: 0.5rem;font-size: 1.25rem;line-height: 1.75rem;font-weight: 700;--tw-text-opacity: 1;color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-header h2[data-v-2d1a7423]:is(.dark *) {--tw-text-opacity: 1;color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-header .favorite-count[data-v-2d1a7423] {font-size: 0.875rem;line-height: 1.25rem;--tw-text-opacity: 1;color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-header .favorite-count[data-v-2d1a7423]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-main[data-v-2d1a7423] {display: flex;min-height: 0px;flex-grow: 1;flex-direction: column
+}
+.favorite-page .favorite-main .favorite-content[data-v-2d1a7423] {min-height: 0px;flex-grow: 1
+}
+.favorite-page .favorite-main .favorite-content .empty-tip[data-v-2d1a7423] {display: flex;height: 100%;align-items: center;justify-content: center;--tw-text-opacity: 1;color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-main .favorite-content .empty-tip[data-v-2d1a7423]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-main .favorite-content .favorite-list[data-v-2d1a7423] > :not([hidden]) ~ :not([hidden]) {--tw-space-y-reverse: 0;margin-top: calc(0.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom: calc(0.5rem * var(--tw-space-y-reverse))
+}
+.favorite-page .favorite-main .favorite-content .favorite-list[data-v-2d1a7423] {padding-left: 1rem;padding-right: 1rem;padding-bottom: 1rem
+}
+.favorite-page .favorite-main .favorite-content .favorite-list-more[data-v-2d1a7423] {margin-top: 1rem
+}
+.favorite-page .favorite-main .favorite-content .favorite-list-more .n-button[data-v-2d1a7423] {--tw-text-opacity: 1;color: rgb(34 197 94 / var(--tw-text-opacity, 1))
+}
+.favorite-page .favorite-main .favorite-content .favorite-list-more .n-button[data-v-2d1a7423]:hover {--tw-text-opacity: 1;color: rgb(22 163 74 / var(--tw-text-opacity, 1))
+}
+.loading-wrapper[data-v-2d1a7423] {display: flex;align-items: center;justify-content: center;padding-top: 5rem;padding-bottom: 5rem
+}
+.no-more-tip[data-v-2d1a7423] {padding-top: 1rem;padding-bottom: 1rem;text-align: center;font-size: 0.875rem;line-height: 1.25rem;--tw-text-opacity: 1;color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.no-more-tip[data-v-2d1a7423]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.mobile .favorite-page[data-v-2d1a7423] {padding: 1rem
+}
+.mobile .favorite-page .favorite-header[data-v-2d1a7423] {margin-bottom: 1rem
+}
+.mobile .favorite-page .favorite-header h2[data-v-2d1a7423] {font-size: 1.25rem;line-height: 1.75rem
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-B-m4kL_6.css.gz b/out/renderer/assets/index-B-m4kL_6.css.gz
new file mode 100644
index 0000000..f823f02
Binary files /dev/null and b/out/renderer/assets/index-B-m4kL_6.css.gz differ
diff --git a/out/renderer/assets/index-BCv4VDKm.js b/out/renderer/assets/index-BCv4VDKm.js
new file mode 100644
index 0000000..3bf4984
--- /dev/null
+++ b/out/renderer/assets/index-BCv4VDKm.js
@@ -0,0 +1,540 @@
+import { p as cB, V as cNotM, m as c, W as cM, Y as cE, d as defineComponent, x as useConfig, Z as useStyle, $ as provide, F as useRtl, l as h, a0 as buttonGroupInjectionKey, r as ref, G as computed, E as watch, o as onMounted, a1 as onUnmounted, c as createElementBlock, b as createBaseVNode, e as createVNode, f as withCtx, t as toDisplayString, n as normalizeClass, a2 as normalizeStyle, a3 as Fragment, a4 as renderList, j as openBlock, T as createCommentVNode, B as Button, _ as _export_sfc } from "./index-DKaFsuse.js";
+const zero = "0!important";
+const n1 = "-1px!important";
+function createLeftBorderStyle(type) {
+ return cM(`${type}-type`, [c("& +", [cB("button", {}, [cM(`${type}-type`, [cE("border", {
+ borderLeftWidth: zero
+ }), cE("state-border", {
+ left: n1
+ })])])])]);
+}
+function createTopBorderStyle(type) {
+ return cM(`${type}-type`, [c("& +", [cB("button", [cM(`${type}-type`, [cE("border", {
+ borderTopWidth: zero
+ }), cE("state-border", {
+ top: n1
+ })])])])]);
+}
+const style = cB("button-group", `
+ flex-wrap: nowrap;
+ display: inline-flex;
+ position: relative;
+`, [cNotM("vertical", {
+ flexDirection: "row"
+}, [cNotM("rtl", [cB("button", [c("&:first-child:not(:last-child)", `
+ margin-right: ${zero};
+ border-top-right-radius: ${zero};
+ border-bottom-right-radius: ${zero};
+ `), c("&:last-child:not(:first-child)", `
+ margin-left: ${zero};
+ border-top-left-radius: ${zero};
+ border-bottom-left-radius: ${zero};
+ `), c("&:not(:first-child):not(:last-child)", `
+ margin-left: ${zero};
+ margin-right: ${zero};
+ border-radius: ${zero};
+ `), createLeftBorderStyle("default"), cM("ghost", [createLeftBorderStyle("primary"), createLeftBorderStyle("info"), createLeftBorderStyle("success"), createLeftBorderStyle("warning"), createLeftBorderStyle("error")])])])]), cM("vertical", {
+ flexDirection: "column"
+}, [cB("button", [c("&:first-child:not(:last-child)", `
+ margin-bottom: ${zero};
+ margin-left: ${zero};
+ margin-right: ${zero};
+ border-bottom-left-radius: ${zero};
+ border-bottom-right-radius: ${zero};
+ `), c("&:last-child:not(:first-child)", `
+ margin-top: ${zero};
+ margin-left: ${zero};
+ margin-right: ${zero};
+ border-top-left-radius: ${zero};
+ border-top-right-radius: ${zero};
+ `), c("&:not(:first-child):not(:last-child)", `
+ margin: ${zero};
+ border-radius: ${zero};
+ `), createTopBorderStyle("default"), cM("ghost", [createTopBorderStyle("primary"), createTopBorderStyle("info"), createTopBorderStyle("success"), createTopBorderStyle("warning"), createTopBorderStyle("error")])])])]);
+const buttonGroupProps = {
+ size: {
+ type: String,
+ default: void 0
+ },
+ vertical: Boolean
+};
+const __unplugin_components_1 = defineComponent({
+ name: "ButtonGroup",
+ props: buttonGroupProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ mergedRtlRef
+ } = useConfig(props);
+ useStyle("-button-group", style, mergedClsPrefixRef);
+ provide(buttonGroupInjectionKey, props);
+ const rtlEnabledRef = useRtl("ButtonGroup", mergedRtlRef, mergedClsPrefixRef);
+ return {
+ rtlEnabled: rtlEnabledRef,
+ mergedClsPrefix: mergedClsPrefixRef
+ };
+ },
+ render() {
+ const {
+ mergedClsPrefix
+ } = this;
+ return h("div", {
+ class: [`${mergedClsPrefix}-button-group`, this.rtlEnabled && `${mergedClsPrefix}-button-group--rtl`, this.vertical && `${mergedClsPrefix}-button-group--vertical`],
+ role: "group"
+ }, this.$slots);
+ }
+});
+const _hoisted_1 = { class: "font-size-controls" };
+const _hoisted_2 = { class: "play-controls" };
+const _hoisted_3 = { class: "control-buttons" };
+const _hoisted_4 = {
+ key: 0,
+ class: "ri-sun-line"
+};
+const _hoisted_5 = {
+ key: 1,
+ class: "ri-moon-line"
+};
+const _hoisted_6 = {
+ key: 0,
+ class: "ri-lock-line"
+};
+const _hoisted_7 = {
+ key: 1,
+ class: "ri-lock-unlock-line"
+};
+const _hoisted_8 = { class: "lyric-scroll" };
+const _hoisted_9 = {
+ key: 1,
+ class: "lyric-empty"
+};
+const fontSizeStep = 2;
+const TIME_OFFSET = 400;
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "Lyric"
+ },
+ __name: "index",
+ setup(__props) {
+ const windowData = window;
+ const containerRef = ref(null);
+ const containerHeight = ref(0);
+ const lineHeight = ref(60);
+ const currentIndex = ref(0);
+ const fontSize = ref(24);
+ const animationFrameId = ref(null);
+ const lastUpdateTime = ref(performance.now());
+ const staticData = ref({
+ lrcArray: [],
+ lrcTimeArray: [],
+ allTime: 0,
+ playMusic: {}
+ });
+ const dynamicData = ref({
+ nowTime: 0,
+ startCurrentTime: 0,
+ nextTime: 0,
+ isPlay: true
+ });
+ const lyricSetting = ref({
+ ...localStorage.getItem("lyricData") ? JSON.parse(localStorage.getItem("lyricData") || "") : {
+ isTop: false,
+ theme: "dark",
+ isLock: false
+ }
+ });
+ const isHovering = ref(false);
+ const showControls = computed(() => {
+ if (lyricSetting.value.isLock) {
+ return isHovering.value;
+ }
+ return true;
+ });
+ const handleMouseEnter = () => {
+ if (lyricSetting.value.isLock) {
+ isHovering.value = true;
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", true);
+ } else {
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", false);
+ }
+ };
+ const handleMouseLeave = () => {
+ if (!lyricSetting.value.isLock) return;
+ isHovering.value = false;
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", false);
+ };
+ watch(
+ () => lyricSetting.value.isLock,
+ (newLock) => {
+ if (newLock) {
+ isHovering.value = false;
+ }
+ }
+ );
+ onMounted(() => {
+ if (lyricSetting.value.isLock) {
+ isHovering.value = false;
+ }
+ });
+ onUnmounted(() => {
+ });
+ const wrapperStyle = computed(() => {
+ if (!containerHeight.value) {
+ return {
+ transform: "translateY(0)",
+ transition: "none"
+ };
+ }
+ const containerCenter = containerHeight.value / 2;
+ const currentLineTop = currentIndex.value * lineHeight.value + containerHeight.value * 0.2 + lineHeight.value;
+ const targetOffset = containerCenter - currentLineTop;
+ const contentHeight = staticData.value.lrcArray.length * lineHeight.value + containerHeight.value * 0.4;
+ const minOffset = -(contentHeight - containerHeight.value);
+ const maxOffset = 0;
+ const finalOffset = Math.min(maxOffset, Math.max(minOffset, targetOffset));
+ return {
+ transform: `translateY(${finalOffset}px)`,
+ transition: "transform 0.3s cubic-bezier(0.4, 0, 0.2, 1)"
+ };
+ });
+ const lyricLineStyle = computed(() => ({
+ height: `${lineHeight.value}px`
+ }));
+ const updateContainerHeight = () => {
+ if (!containerRef.value) return;
+ containerHeight.value = containerRef.value.clientHeight;
+ const baseLineHeight = fontSize.value * 2.5;
+ const maxAllowedHeight = containerHeight.value / 3;
+ lineHeight.value = Math.min(maxAllowedHeight, Math.max(40, baseLineHeight));
+ };
+ const handleFontSizeChange = async () => {
+ saveFontSize();
+ updateContainerHeight();
+ };
+ const increaseFontSize = async () => {
+ if (fontSize.value < 48) {
+ fontSize.value += fontSizeStep;
+ await handleFontSizeChange();
+ }
+ };
+ const decreaseFontSize = async () => {
+ if (fontSize.value > 12) {
+ fontSize.value -= fontSizeStep;
+ await handleFontSizeChange();
+ }
+ };
+ const saveFontSize = () => {
+ localStorage.setItem("lyricFontSize", fontSize.value.toString());
+ };
+ onMounted(() => {
+ const resizeObserver = new ResizeObserver(() => {
+ updateContainerHeight();
+ });
+ if (containerRef.value) {
+ resizeObserver.observe(containerRef.value);
+ }
+ onUnmounted(() => {
+ resizeObserver.disconnect();
+ });
+ });
+ const actualTime = ref(0);
+ const currentProgress = computed(() => {
+ const { startCurrentTime, nextTime } = dynamicData.value;
+ if (!startCurrentTime || !nextTime) return 0;
+ const duration = nextTime - startCurrentTime;
+ const elapsed = actualTime.value - startCurrentTime;
+ return Math.min(Math.max(elapsed / duration, 0), 1);
+ });
+ const getLyricStyle = (index2) => {
+ if (index2 !== currentIndex.value) return {};
+ const progress = currentProgress.value * 100;
+ return {
+ background: `linear-gradient(to right, var(--highlight-color) ${progress}%, var(--text-color) ${progress}%)`,
+ WebkitBackgroundClip: "text",
+ WebkitTextFillColor: "transparent",
+ transition: "all 0.1s linear"
+ };
+ };
+ const updateProgress = () => {
+ if (!dynamicData.value.isPlay) {
+ if (animationFrameId.value) {
+ cancelAnimationFrame(animationFrameId.value);
+ animationFrameId.value = null;
+ }
+ return;
+ }
+ const timeDiff = (performance.now() - lastUpdateTime.value) / 1e3;
+ actualTime.value = dynamicData.value.nowTime + timeDiff + TIME_OFFSET / 1e3;
+ animationFrameId.value = requestAnimationFrame(updateProgress);
+ };
+ watch(
+ () => dynamicData.value,
+ (newData) => {
+ lastUpdateTime.value = performance.now();
+ actualTime.value = newData.nowTime + TIME_OFFSET / 1e3;
+ if (newData.isPlay && !animationFrameId.value) {
+ updateProgress();
+ }
+ },
+ { deep: true }
+ );
+ watch(
+ () => dynamicData.value.isPlay,
+ (isPlaying) => {
+ if (isPlaying) {
+ lastUpdateTime.value = performance.now();
+ updateProgress();
+ } else if (animationFrameId.value) {
+ cancelAnimationFrame(animationFrameId.value);
+ animationFrameId.value = null;
+ }
+ }
+ );
+ const handleDataUpdate = (parsedData) => {
+ if (!parsedData) {
+ console.error("Invalid update data received:", parsedData);
+ return;
+ }
+ staticData.value = {
+ lrcArray: parsedData.lrcArray || [],
+ lrcTimeArray: parsedData.lrcTimeArray || [],
+ allTime: parsedData.allTime || 0,
+ playMusic: parsedData.playMusic || {}
+ };
+ dynamicData.value = {
+ nowTime: parsedData.nowTime || 0,
+ startCurrentTime: parsedData.startCurrentTime || 0,
+ nextTime: parsedData.nextTime || 0,
+ isPlay: parsedData.isPlay
+ };
+ if (typeof parsedData.nowIndex === "number") {
+ currentIndex.value = parsedData.nowIndex;
+ }
+ };
+ onMounted(() => {
+ const savedFontSize = localStorage.getItem("lyricFontSize");
+ if (savedFontSize) {
+ fontSize.value = Number(savedFontSize);
+ lineHeight.value = fontSize.value * 2.5;
+ }
+ updateContainerHeight();
+ window.addEventListener("resize", updateContainerHeight);
+ windowData.electron.ipcRenderer.on("receive-lyric", (_, data) => {
+ try {
+ const parsedData = JSON.parse(data);
+ handleDataUpdate(parsedData);
+ } catch (error) {
+ console.error("Error parsing lyric data:", error);
+ }
+ });
+ });
+ onUnmounted(() => {
+ window.removeEventListener("resize", updateContainerHeight);
+ });
+ const checkTheme = () => {
+ if (lyricSetting.value.theme === "light") {
+ lyricSetting.value.theme = "dark";
+ } else {
+ lyricSetting.value.theme = "light";
+ }
+ };
+ const handleLock = () => {
+ lyricSetting.value.isLock = !lyricSetting.value.isLock;
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", lyricSetting.value.isLock);
+ };
+ const handleClose = () => {
+ windowData.electron.ipcRenderer.send("close-lyric");
+ };
+ watch(
+ () => lyricSetting.value,
+ (newValue) => {
+ localStorage.setItem("lyricData", JSON.stringify(newValue));
+ },
+ { deep: true }
+ );
+ const isDragging = ref(false);
+ const startPosition = ref({ x: 0, y: 0 });
+ const handleMouseDown = (e) => {
+ if (lyricSetting.value.isLock || e.target.closest(".control-buttons") || e.target.closest(".font-size-controls")) {
+ return;
+ }
+ if (e.button !== 0) return;
+ isDragging.value = true;
+ startPosition.value = { x: e.screenX, y: e.screenY };
+ const handleMouseMove = (e2) => {
+ if (!isDragging.value) return;
+ const deltaX = e2.screenX - startPosition.value.x;
+ const deltaY = e2.screenY - startPosition.value.y;
+ windowData.electron.ipcRenderer.send("lyric-drag-move", { deltaX, deltaY });
+ startPosition.value = { x: e2.screenX, y: e2.screenY };
+ };
+ const handleMouseUp = () => {
+ if (!isDragging.value) return;
+ isDragging.value = false;
+ document.removeEventListener("mousemove", handleMouseMove);
+ document.removeEventListener("mouseup", handleMouseUp);
+ };
+ document.addEventListener("mousemove", handleMouseMove);
+ document.addEventListener("mouseup", handleMouseUp);
+ };
+ onUnmounted(() => {
+ isDragging.value = false;
+ });
+ onMounted(() => {
+ const lyricLock = document.getElementById("lyric-lock");
+ if (lyricLock) {
+ lyricLock.onmouseenter = () => {
+ if (lyricSetting.value.isLock) {
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", false);
+ }
+ };
+ lyricLock.onmouseleave = () => {
+ if (lyricSetting.value.isLock) {
+ windowData.electron.ipcRenderer.send("set-ignore-mouse", true);
+ }
+ };
+ }
+ });
+ const handlePlayPause = () => {
+ windowData.electron.ipcRenderer.send("control-back", "playpause");
+ };
+ const handlePrev = () => {
+ windowData.electron.ipcRenderer.send("control-back", "prev");
+ };
+ const handleNext = () => {
+ windowData.electron.ipcRenderer.send("control-back", "next");
+ };
+ return (_ctx, _cache) => {
+ const _component_n_button = Button;
+ const _component_n_button_group = __unplugin_components_1;
+ return openBlock(), createElementBlock("div", {
+ class: normalizeClass(["lyric-window", [lyricSetting.value.theme, { lyric_lock: lyricSetting.value.isLock }]]),
+ onMousedown: handleMouseDown,
+ onMouseenter: handleMouseEnter,
+ onMouseleave: handleMouseLeave
+ }, [
+ _cache[5] || (_cache[5] = createBaseVNode("div", { class: "drag-overlay" }, null, -1)),
+ createBaseVNode("div", {
+ class: normalizeClass(["control-bar", { "control-bar-show": showControls.value }])
+ }, [
+ createBaseVNode("div", _hoisted_1, [
+ createVNode(_component_n_button_group, null, {
+ default: withCtx(() => [
+ createVNode(_component_n_button, {
+ quaternary: "",
+ size: "small",
+ disabled: fontSize.value <= 12,
+ onClick: decreaseFontSize
+ }, {
+ default: withCtx(() => _cache[0] || (_cache[0] = [
+ createBaseVNode("i", { class: "ri-subtract-line" }, null, -1)
+ ])),
+ _: 1
+ }, 8, ["disabled"]),
+ createVNode(_component_n_button, {
+ quaternary: "",
+ size: "small",
+ disabled: fontSize.value >= 48,
+ onClick: increaseFontSize
+ }, {
+ default: withCtx(() => _cache[1] || (_cache[1] = [
+ createBaseVNode("i", { class: "ri-add-line" }, null, -1)
+ ])),
+ _: 1
+ }, 8, ["disabled"])
+ ]),
+ _: 1
+ }),
+ createBaseVNode("div", null, toDisplayString(staticData.value.playMusic.name), 1)
+ ]),
+ createBaseVNode("div", _hoisted_2, [
+ createBaseVNode("div", {
+ class: "control-button",
+ onClick: handlePrev
+ }, _cache[2] || (_cache[2] = [
+ createBaseVNode("i", { class: "ri-skip-back-fill" }, null, -1)
+ ])),
+ createBaseVNode("div", {
+ class: "control-button play-button",
+ onClick: handlePlayPause
+ }, [
+ createBaseVNode("i", {
+ class: normalizeClass(dynamicData.value.isPlay ? "ri-pause-fill" : "ri-play-fill")
+ }, null, 2)
+ ]),
+ createBaseVNode("div", {
+ class: "control-button",
+ onClick: handleNext
+ }, _cache[3] || (_cache[3] = [
+ createBaseVNode("i", { class: "ri-skip-forward-fill" }, null, -1)
+ ]))
+ ]),
+ createBaseVNode("div", _hoisted_3, [
+ createBaseVNode("div", {
+ class: "control-button",
+ onClick: checkTheme
+ }, [
+ lyricSetting.value.theme === "light" ? (openBlock(), createElementBlock("i", _hoisted_4)) : (openBlock(), createElementBlock("i", _hoisted_5))
+ ]),
+ createBaseVNode("div", {
+ id: "lyric-lock",
+ class: "control-button",
+ onClick: handleLock
+ }, [
+ lyricSetting.value.isLock ? (openBlock(), createElementBlock("i", _hoisted_6)) : (openBlock(), createElementBlock("i", _hoisted_7))
+ ]),
+ createBaseVNode("div", {
+ class: "control-button",
+ onClick: handleClose
+ }, _cache[4] || (_cache[4] = [
+ createBaseVNode("i", { class: "ri-close-line" }, null, -1)
+ ]))
+ ])
+ ], 2),
+ createBaseVNode("div", {
+ ref_key: "containerRef",
+ ref: containerRef,
+ class: "lyric-container"
+ }, [
+ createBaseVNode("div", _hoisted_8, [
+ createBaseVNode("div", {
+ class: "lyric-wrapper",
+ style: normalizeStyle(wrapperStyle.value)
+ }, [
+ staticData.value.lrcArray?.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(staticData.value.lrcArray, (line, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: index2,
+ class: normalizeClass(["lyric-line", {
+ "lyric-line-current": index2 === currentIndex.value,
+ "lyric-line-passed": index2 < currentIndex.value,
+ "lyric-line-next": index2 === currentIndex.value + 1
+ }]),
+ style: normalizeStyle(lyricLineStyle.value)
+ }, [
+ createBaseVNode("div", {
+ class: "lyric-text",
+ style: normalizeStyle({ fontSize: `${fontSize.value}px` })
+ }, [
+ createBaseVNode("span", {
+ class: "lyric-text-inner",
+ style: normalizeStyle(getLyricStyle(index2))
+ }, toDisplayString(line.text || ""), 5)
+ ], 4),
+ line.trText ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: "lyric-translation",
+ style: normalizeStyle({ fontSize: `${fontSize.value * 0.6}px` })
+ }, toDisplayString(line.trText), 5)) : createCommentVNode("", true)
+ ], 6);
+ }), 128)) : (openBlock(), createElementBlock("div", _hoisted_9, "无歌词"))
+ ], 4)
+ ])
+ ], 512)
+ ], 34);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-4abaac34"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-BCv4VDKm.js.gz b/out/renderer/assets/index-BCv4VDKm.js.gz
new file mode 100644
index 0000000..5ecef4a
Binary files /dev/null and b/out/renderer/assets/index-BCv4VDKm.js.gz differ
diff --git a/out/renderer/assets/index-BE7j41Na.css b/out/renderer/assets/index-BE7j41Na.css
new file mode 100644
index 0000000..9bce8ff
--- /dev/null
+++ b/out/renderer/assets/index-BE7j41Na.css
@@ -0,0 +1,203 @@
+
+body {
+ background-color: transparent !important;
+}
+.lyric-window[data-v-4abaac34] {
+ width: 100vw;
+ height: 100vh;
+ position: relative;
+ overflow: hidden;
+ background: transparent;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+ transition: background-color 0.2s ease;
+ cursor: default;
+}
+.lyric-window[data-v-4abaac34]:hover {
+ background: rgba(0, 0, 0, 0.5);
+}
+.lyric-window:hover .control-bar-show[data-v-4abaac34] {
+ opacity: 1;
+ visibility: visible;
+}
+.lyric-window[data-v-4abaac34]:active {
+ cursor: grabbing;
+}
+.lyric-window.dark[data-v-4abaac34] {
+ --text-color: #ffffff;
+ --text-secondary: rgba(255, 255, 255, 0.6);
+ --highlight-color: #1db954;
+ --control-bg: rgba(124, 124, 124, 0.3);
+}
+.lyric-window.light[data-v-4abaac34] {
+ --text-color: #333333;
+ --text-secondary: rgba(51, 51, 51, 0.6);
+ --highlight-color: #1db954;
+ --control-bg: rgba(255, 255, 255, 0.3);
+}
+.control-bar[data-v-4abaac34] {
+ position: absolute;
+ top: 10px;
+ left: 0;
+ right: 0;
+ height: 80px;
+ display: flex;
+ justify-content: space-between;
+ align-items: start;
+ padding: 0 20px;
+ opacity: 0;
+ visibility: hidden;
+ transition: opacity 0.2s ease, visibility 0.2s ease;
+ z-index: 100;
+}
+.control-bar .font-size-controls[data-v-4abaac34] {
+ -webkit-app-region: no-drag;
+ color: var(--text-color);
+ display: flex;
+ align-items: center;
+ gap: 16px;
+}
+.control-bar .play-controls[data-v-4abaac34] {
+ position: absolute;
+ top: 0px;
+ left: 50%;
+ transform: translateX(-50%);
+ display: flex;
+ align-items: center;
+ gap: 16px;
+ -webkit-app-region: no-drag;
+}
+.control-bar .play-controls .play-button[data-v-4abaac34] {
+ width: 36px;
+ height: 36px;
+}
+.control-bar .play-controls .play-button i[data-v-4abaac34] {
+ font-size: 24px;
+}
+.control-bar .control-buttons[data-v-4abaac34] {
+ -webkit-app-region: no-drag;
+}
+.control-buttons[data-v-4abaac34] {
+ display: flex;
+ gap: 16px;
+ -webkit-app-region: no-drag;
+}
+.control-button[data-v-4abaac34] {
+ width: 36px;
+ height: 36px;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ cursor: pointer;
+ border-radius: 8px;
+ color: var(--text-color);
+ transition: all 0.2s ease;
+}
+.control-button[data-v-4abaac34]:hover {
+ background: var(--control-bg);
+}
+.control-button i[data-v-4abaac34] {
+ font-size: 20px;
+ text-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
+}
+.control-button i.active[data-v-4abaac34] {
+ color: var(--highlight-color);
+}
+.lyric-container[data-v-4abaac34] {
+ position: absolute;
+ top: 80px;
+ left: 0;
+ right: 0;
+ bottom: 0;
+ overflow: hidden;
+ z-index: 100;
+}
+.lyric-scroll[data-v-4abaac34] {
+ height: 100%;
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+ justify-content: flex-start;
+ align-items: center;
+ -webkit-mask-image: linear-gradient(to bottom, transparent 0%, black 20%, black 80%, transparent 100%);
+ mask-image: linear-gradient(to bottom, transparent 0%, black 20%, black 80%, transparent 100%);
+}
+.lyric-wrapper[data-v-4abaac34] {
+ will-change: transform;
+ padding: 20vh 0;
+ transform-origin: center center;
+ transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
+}
+.lyric-line[data-v-4abaac34] {
+ padding: 4px 20px;
+ text-align: center;
+ transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
+ display: flex;
+ flex-direction: column;
+ justify-content: center;
+ align-items: center;
+}
+.lyric-line.lyric-line-current[data-v-4abaac34] {
+ transform: scale(1.05);
+ opacity: 1;
+}
+.lyric-line.lyric-line-passed[data-v-4abaac34] {
+ opacity: 0.6;
+}
+.lyric-text[data-v-4abaac34] {
+ font-weight: 600;
+ margin-bottom: 2px;
+ color: var(--text-color);
+ white-space: pre-wrap;
+ word-break: break-all;
+ text-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
+ transition: all 0.2s ease;
+ line-height: 1.4;
+}
+.lyric-translation[data-v-4abaac34] {
+ color: var(--text-secondary);
+ white-space: pre-wrap;
+ word-break: break-all;
+ text-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
+ transition: font-size 0.2s ease;
+ line-height: 1.4;
+}
+.lyric-empty[data-v-4abaac34] {
+ text-align: center;
+ color: var(--text-secondary);
+ font-size: 16px;
+ padding: 20px;
+}
+body[data-v-4abaac34] {
+ background-color: transparent !important;
+ margin: 0;
+ font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
+}
+.lyric-content[data-v-4abaac34] {
+ transition: font-size 0.2s ease;
+}
+.lyric-line-current[data-v-4abaac34] {
+ opacity: 1;
+}
+.lyric_lock .control-bar .control-buttons .control-button[data-v-4abaac34]:not(:has(.ri-lock-line)):not(:has(.ri-lock-unlock-line)) {
+ display: none;
+}
+.lyric_lock .control-bar .font-size-controls[data-v-4abaac34] {
+ display: none;
+}
+.lyric_lock .control-bar .play-controls[data-v-4abaac34] {
+ display: none;
+}
+.lyric_lock[data-v-4abaac34] {
+ background: transparent;
+}
+.lyric_lock[data-v-4abaac34]:hover {
+ background: transparent;
+}
+.lyric_lock #lyric-lock[data-v-4abaac34] {
+ position: absolute;
+ top: 0;
+ right: 72px;
+ background: var(--control-bg);
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-BE7j41Na.css.gz b/out/renderer/assets/index-BE7j41Na.css.gz
new file mode 100644
index 0000000..74e0ed9
Binary files /dev/null and b/out/renderer/assets/index-BE7j41Na.css.gz differ
diff --git a/out/renderer/assets/index-BPmJoRDi.js b/out/renderer/assets/index-BPmJoRDi.js
new file mode 100644
index 0000000..cb3acc0
--- /dev/null
+++ b/out/renderer/assets/index-BPmJoRDi.js
@@ -0,0 +1,203 @@
+import { ad as request, d as defineComponent, r as ref, G as computed, aq as onActivated, c as createElementBlock, n as normalizeClass, u as unref, a2 as normalizeStyle, b as createBaseVNode, t as toDisplayString, e as createVNode, f as withCtx, T as createCommentVNode, w as withDirectives, S as Scrollbar, ab as resolveDirective, g as useStore, h as useRouter, j as openBlock, s as setAnimationClass, a7 as getImgUrl, a3 as Fragment, a4 as renderList, U as PlayBottom, ac as isMobile, a5 as setAnimationDelay, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { M as MusicList, a as getListDetail } from "./MusicList-s-QHu-iA.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { _ as __unplugin_components_2 } from "./Avatar-rQ2og-6c.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import "./Drawer-BEJ8Ydua.js";
+import "./Ellipsis-D4R5dIX2.js";
+import "./Tag-C0oC92WF.js";
+import "./use-locale-DLWAOXez.js";
+function getUserDetail(uid) {
+ return request.get("/user/detail", { params: { uid } });
+}
+function getUserPlaylist(uid) {
+ return request.get("/user/playlist", { params: { uid } });
+}
+function getUserRecord(uid, type = 0) {
+ return request.get("/user/record", { params: { uid, type } });
+}
+const _hoisted_1 = { class: "user-page" };
+const _hoisted_2 = { class: "page" };
+const _hoisted_3 = { class: "user-name" };
+const _hoisted_4 = { class: "user-info" };
+const _hoisted_5 = { class: "user-info-list" };
+const _hoisted_6 = { class: "user-info-item" };
+const _hoisted_7 = { class: "label" };
+const _hoisted_8 = { class: "user-info-item" };
+const _hoisted_9 = { class: "label" };
+const _hoisted_10 = { class: "user-info-item" };
+const _hoisted_11 = { class: "label" };
+const _hoisted_12 = { class: "uesr-signature" };
+const _hoisted_13 = ["onClick"];
+const _hoisted_14 = { class: "play-list-item-info" };
+const _hoisted_15 = { class: "play-list-item-name" };
+const _hoisted_16 = { class: "play-list-item-count" };
+const _hoisted_17 = { class: "record-list" };
+const _hoisted_18 = { class: "play-count" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "User"
+ },
+ __name: "index",
+ setup(__props) {
+ const store = useStore();
+ const router = useRouter();
+ const userDetail = ref();
+ const playList = ref([]);
+ const recordList = ref();
+ const infoLoading = ref(false);
+ const user = computed(() => store.state.user);
+ const loadPage = async () => {
+ if (!user.value) {
+ router.push("/login");
+ return;
+ }
+ infoLoading.value = true;
+ const { data: userData } = await getUserDetail(user.value.userId);
+ userDetail.value = userData;
+ const { data: playlistData } = await getUserPlaylist(user.value.userId);
+ playList.value = playlistData.playlist;
+ const { data: recordData } = await getUserRecord(user.value.userId);
+ recordList.value = recordData.allData.map((item) => ({
+ ...item,
+ ...item.song,
+ picUrl: item.song.al.picUrl
+ }));
+ infoLoading.value = false;
+ };
+ onActivated(() => {
+ if (!user.value) {
+ router.push("/login");
+ } else {
+ loadPage();
+ }
+ });
+ const isShowList = ref(false);
+ const list = ref();
+ const listLoading = ref(false);
+ const showPlaylist = async (id, name) => {
+ isShowList.value = true;
+ listLoading.value = true;
+ list.value = {
+ name
+ };
+ const { data } = await getListDetail(id);
+ list.value = data.playlist;
+ listLoading.value = false;
+ };
+ const handlePlay = () => {
+ const tracks = recordList.value || [];
+ store.commit("setPlayList", tracks);
+ };
+ return (_ctx, _cache) => {
+ const _component_n_avatar = __unplugin_components_2;
+ const _component_n_image = NImage;
+ const _component_n_scrollbar = Scrollbar;
+ const _directive_loading = resolveDirective("loading");
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ userDetail.value ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: normalizeClass(["left", unref(setAnimationClass)("animate__fadeInLeft")]),
+ style: normalizeStyle({ backgroundImage: `url(${unref(getImgUrl)(user.value.backgroundUrl)})` })
+ }, [
+ createBaseVNode("div", _hoisted_2, [
+ createBaseVNode("div", _hoisted_3, toDisplayString(user.value.nickname), 1),
+ createBaseVNode("div", _hoisted_4, [
+ createVNode(_component_n_avatar, {
+ round: "",
+ size: 50,
+ src: unref(getImgUrl)(user.value.avatarUrl, "50y50")
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("div", _hoisted_6, [
+ createBaseVNode("div", _hoisted_7, toDisplayString(userDetail.value.profile.followeds), 1),
+ _cache[1] || (_cache[1] = createBaseVNode("div", null, "粉丝", -1))
+ ]),
+ createBaseVNode("div", _hoisted_8, [
+ createBaseVNode("div", _hoisted_9, toDisplayString(userDetail.value.profile.follows), 1),
+ _cache[2] || (_cache[2] = createBaseVNode("div", null, "关注", -1))
+ ]),
+ createBaseVNode("div", _hoisted_10, [
+ createBaseVNode("div", _hoisted_11, toDisplayString(userDetail.value.level), 1),
+ _cache[3] || (_cache[3] = createBaseVNode("div", null, "等级", -1))
+ ])
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_12, toDisplayString(userDetail.value.profile.signature), 1),
+ createBaseVNode("div", {
+ class: normalizeClass(["play-list", unref(setAnimationClass)("animate__fadeInLeft")])
+ }, [
+ _cache[4] || (_cache[4] = createBaseVNode("div", { class: "title" }, "创建的歌单", -1)),
+ createVNode(_component_n_scrollbar, null, {
+ default: withCtx(() => [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(playList.value, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: index2,
+ class: "play-list-item",
+ onClick: ($event) => showPlaylist(item.id, item.name)
+ }, [
+ createVNode(_component_n_image, {
+ src: unref(getImgUrl)(item.coverImgUrl, "50y50"),
+ class: "play-list-item-img",
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_14, [
+ createBaseVNode("div", _hoisted_15, toDisplayString(item.name), 1),
+ createBaseVNode("div", _hoisted_16, toDisplayString(item.trackCount) + "首,播放" + toDisplayString(item.playCount) + "次 ", 1)
+ ])
+ ], 8, _hoisted_13);
+ }), 128)),
+ createVNode(PlayBottom)
+ ]),
+ _: 1
+ })
+ ], 2)
+ ])
+ ], 6)) : createCommentVNode("", true),
+ !unref(isMobile) ? withDirectives((openBlock(), createElementBlock("div", {
+ key: 1,
+ class: normalizeClass(["right", unref(setAnimationClass)("animate__fadeInRight")])
+ }, [
+ _cache[5] || (_cache[5] = createBaseVNode("div", { class: "title" }, "听歌排行", -1)),
+ createBaseVNode("div", _hoisted_17, [
+ createVNode(_component_n_scrollbar, null, {
+ default: withCtx(() => [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(recordList.value, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["record-item", unref(setAnimationClass)("animate__bounceInUp")]),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 25))
+ }, [
+ createVNode(SongItem, {
+ class: "song-item",
+ item,
+ onPlay: handlePlay
+ }, null, 8, ["item"]),
+ createBaseVNode("div", _hoisted_18, toDisplayString(item.playCount) + "次", 1)
+ ], 6);
+ }), 128)),
+ createVNode(PlayBottom)
+ ]),
+ _: 1
+ })
+ ])
+ ], 2)), [
+ [_directive_loading, infoLoading.value]
+ ]) : createCommentVNode("", true),
+ createVNode(MusicList, {
+ show: isShowList.value,
+ "onUpdate:show": _cache[0] || (_cache[0] = ($event) => isShowList.value = $event),
+ name: list.value?.name || "",
+ "song-list": list.value?.tracks || [],
+ "list-info": list.value,
+ loading: listLoading.value
+ }, null, 8, ["show", "name", "song-list", "list-info", "loading"])
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-be63ae6f"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-BPmJoRDi.js.gz b/out/renderer/assets/index-BPmJoRDi.js.gz
new file mode 100644
index 0000000..a2be49e
Binary files /dev/null and b/out/renderer/assets/index-BPmJoRDi.js.gz differ
diff --git a/out/renderer/assets/index-Bc5fdT5j.js b/out/renderer/assets/index-Bc5fdT5j.js
new file mode 100644
index 0000000..fe3f94f
--- /dev/null
+++ b/out/renderer/assets/index-Bc5fdT5j.js
@@ -0,0 +1,233 @@
+import { d as defineComponent, r as ref, G as computed, o as onMounted, E as watch, c as createElementBlock, b as createBaseVNode, e as createVNode, f as withCtx, u as unref, i as isRef, af as useRoute, S as Scrollbar, a5 as setAnimationDelay, ab as resolveDirective, j as openBlock, ah as withModifiers, a3 as Fragment, a4 as renderList, n as normalizeClass, s as setAnimationClass, a2 as normalizeStyle, t as toDisplayString, w as withDirectives, a7 as getImgUrl, ai as formatNumber, T as createCommentVNode, aj as __unplugin_components_0, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { g as getPlaylistCategory } from "./home-BXGE9AqN.js";
+import { M as MusicList, b as getListByCat, a as getListDetail } from "./MusicList-s-QHu-iA.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import "./SongItem-CoswpGn6.js";
+import "./Ellipsis-D4R5dIX2.js";
+import "./Drawer-BEJ8Ydua.js";
+import "./Avatar-rQ2og-6c.js";
+import "./Tag-C0oC92WF.js";
+import "./use-locale-DLWAOXez.js";
+const _hoisted_1 = { class: "list-page" };
+const _hoisted_2 = { class: "play-list-type" };
+const _hoisted_3 = ["onClick"];
+const _hoisted_4 = { class: "recommend-list" };
+const _hoisted_5 = ["onClick"];
+const _hoisted_6 = { class: "recommend-item-img" };
+const _hoisted_7 = { class: "top" };
+const _hoisted_8 = { class: "play-count" };
+const _hoisted_9 = { class: "recommend-item-title" };
+const _hoisted_10 = {
+ key: 0,
+ class: "loading-more"
+};
+const _hoisted_11 = {
+ key: 1,
+ class: "no-more"
+};
+const TOTAL_ITEMS = 42;
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "List"
+ },
+ __name: "index",
+ setup(__props) {
+ const recommendList = ref([]);
+ const showMusic = ref(false);
+ const page = ref(0);
+ const hasMore = ref(true);
+ const isLoadingMore = ref(false);
+ const getItemAnimationDelay = (index2) => {
+ const currentPageIndex = index2 % TOTAL_ITEMS;
+ return setAnimationDelay(currentPageIndex, 30);
+ };
+ const recommendItem = ref();
+ const listDetail = ref();
+ const listLoading = ref(true);
+ const selectRecommendItem = async (item) => {
+ listLoading.value = true;
+ recommendItem.value = null;
+ listDetail.value = null;
+ showMusic.value = true;
+ recommendItem.value = item;
+ const { data } = await getListDetail(item.id);
+ listDetail.value = data;
+ listLoading.value = false;
+ };
+ const route = useRoute();
+ const listTitle = ref(route.query.type || "歌单列表");
+ const loading = ref(false);
+ const loadList = async (type, isLoadMore = false) => {
+ if (!hasMore.value && isLoadMore) return;
+ if (isLoadMore) {
+ isLoadingMore.value = true;
+ } else {
+ loading.value = true;
+ page.value = 0;
+ recommendList.value = [];
+ }
+ try {
+ const params = {
+ cat: type === "每日推荐" ? "" : type,
+ limit: TOTAL_ITEMS,
+ offset: page.value * TOTAL_ITEMS
+ };
+ const { data } = await getListByCat(params);
+ if (isLoadMore) {
+ recommendList.value.push(...data.playlists);
+ } else {
+ recommendList.value = data.playlists;
+ }
+ hasMore.value = data.more;
+ page.value++;
+ } catch (error) {
+ console.error("加载歌单列表失败:", error);
+ } finally {
+ loading.value = false;
+ isLoadingMore.value = false;
+ }
+ };
+ const handleScroll = (e) => {
+ const { scrollTop, scrollHeight, clientHeight } = e.target;
+ if (scrollTop + clientHeight >= scrollHeight - 100 && !isLoadingMore.value && hasMore.value) {
+ loadList(route.query.type, true);
+ }
+ };
+ const playlistCategory = ref();
+ const currentType = ref(route.query.type || "每日推荐");
+ const getAnimationDelay = computed(() => {
+ return (index2) => setAnimationDelay(index2, 30);
+ });
+ const loadPlaylistCategory = async () => {
+ const { data } = await getPlaylistCategory();
+ playlistCategory.value = {
+ ...data,
+ sub: [
+ {
+ name: "每日推荐",
+ category: 0
+ },
+ ...data.sub
+ ]
+ };
+ };
+ const handleClickPlaylistType = (type) => {
+ currentType.value = type;
+ listTitle.value = type;
+ loading.value = true;
+ loadList(type);
+ };
+ const scrollbarRef = ref();
+ const handleWheel = (e) => {
+ const scrollbar = scrollbarRef.value;
+ if (scrollbar) {
+ const delta = e.deltaY || e.detail;
+ scrollbar.scrollBy({ left: delta });
+ }
+ };
+ onMounted(() => {
+ loadPlaylistCategory();
+ currentType.value = route.query.type || currentType.value;
+ loadList(currentType.value);
+ });
+ watch(
+ () => route.query,
+ async (newParams) => {
+ if (newParams.type) {
+ recommendList.value = [];
+ listTitle.value = newParams.type || "歌单列表";
+ currentType.value = newParams.type;
+ loading.value = true;
+ loadList(newParams.type);
+ }
+ }
+ );
+ return (_ctx, _cache) => {
+ const _component_n_scrollbar = Scrollbar;
+ const _component_n_image = NImage;
+ const _component_n_spin = __unplugin_components_0;
+ const _directive_loading = resolveDirective("loading");
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ createVNode(_component_n_scrollbar, {
+ ref_key: "scrollbarRef",
+ ref: scrollbarRef,
+ "x-scrollable": ""
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", {
+ class: "categories-wrapper",
+ onWheel: withModifiers(handleWheel, ["prevent"])
+ }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(playlistCategory)?.sub, (item, index2) => {
+ return openBlock(), createElementBlock("span", {
+ key: item.name,
+ class: normalizeClass(["play-list-type-item", [unref(setAnimationClass)("animate__bounceIn"), { active: unref(currentType) === item.name }]]),
+ style: normalizeStyle(unref(getAnimationDelay)(index2)),
+ onClick: ($event) => handleClickPlaylistType(item.name)
+ }, toDisplayString(item.name), 15, _hoisted_3);
+ }), 128))
+ ], 32)
+ ]),
+ _: 1
+ }, 512)
+ ]),
+ createVNode(_component_n_scrollbar, {
+ class: "recommend",
+ size: 100,
+ onScroll: handleScroll
+ }, {
+ default: withCtx(() => [
+ withDirectives((openBlock(), createElementBlock("div", _hoisted_4, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(recommendList), (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["recommend-item", unref(setAnimationClass)("animate__bounceIn")]),
+ style: normalizeStyle(getItemAnimationDelay(index2)),
+ onClick: withModifiers(($event) => selectRecommendItem(item), ["stop"])
+ }, [
+ createBaseVNode("div", _hoisted_6, [
+ createVNode(_component_n_image, {
+ class: "recommend-item-img-img",
+ src: unref(getImgUrl)(item.picUrl || item.coverImgUrl, "200y200"),
+ width: "200",
+ height: "200",
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_7, [
+ createBaseVNode("div", _hoisted_8, toDisplayString(unref(formatNumber)(item.playCount)), 1),
+ _cache[2] || (_cache[2] = createBaseVNode("i", { class: "iconfont icon-videofill" }, null, -1))
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_9, toDisplayString(item.name), 1)
+ ], 14, _hoisted_5);
+ }), 128))
+ ])), [
+ [_directive_loading, unref(loading)]
+ ]),
+ unref(isLoadingMore) ? (openBlock(), createElementBlock("div", _hoisted_10, [
+ createVNode(_component_n_spin, { size: "small" }),
+ _cache[3] || (_cache[3] = createBaseVNode("span", { class: "ml-2" }, "加载中...", -1))
+ ])) : createCommentVNode("", true),
+ !unref(hasMore) && unref(recommendList).length > 0 ? (openBlock(), createElementBlock("div", _hoisted_11, "没有更多了")) : createCommentVNode("", true)
+ ]),
+ _: 1
+ }),
+ createVNode(MusicList, {
+ show: unref(showMusic),
+ "onUpdate:show": _cache[0] || (_cache[0] = ($event) => isRef(showMusic) ? showMusic.value = $event : null),
+ loading: unref(listLoading),
+ "onUpdate:loading": _cache[1] || (_cache[1] = ($event) => isRef(listLoading) ? listLoading.value = $event : null),
+ name: unref(recommendItem)?.name || "",
+ "song-list": unref(listDetail)?.playlist.tracks || [],
+ "list-info": unref(listDetail)?.playlist
+ }, null, 8, ["show", "loading", "name", "song-list", "list-info"])
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-f9f1189c"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-Bc5fdT5j.js.gz b/out/renderer/assets/index-Bc5fdT5j.js.gz
new file mode 100644
index 0000000..954327f
Binary files /dev/null and b/out/renderer/assets/index-Bc5fdT5j.js.gz differ
diff --git a/out/renderer/assets/index-BlaUC8oz.css b/out/renderer/assets/index-BlaUC8oz.css
new file mode 100644
index 0000000..79d9ff1
--- /dev/null
+++ b/out/renderer/assets/index-BlaUC8oz.css
@@ -0,0 +1,336 @@
+.title[data-v-686a7f41] {
+ margin-bottom: 1rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.title[data-v-686a7f41]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list-type[data-v-686a7f41] {
+ width: 250px;
+ margin-right: 1rem;
+}
+.play-list-type-item[data-v-686a7f41], .play-list-type-showall[data-v-686a7f41] {
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.play-list-type-item[data-v-686a7f41]:is(.dark *), .play-list-type-showall[data-v-686a7f41]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list-type-item[data-v-686a7f41], .play-list-type-showall[data-v-686a7f41] {
+ margin-right: 0.75rem;
+ margin-bottom: 0.75rem;
+ display: inline-block;
+ cursor: pointer;
+ border-radius: 0.75rem;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.play-list-type-item[data-v-686a7f41]:hover, .play-list-type-showall[data-v-686a7f41]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list-type-item[data-v-686a7f41]:is(.dark *), .play-list-type-showall[data-v-686a7f41]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.play-list-type-showall[data-v-686a7f41] {
+ display: block;
+ text-align: center;
+}
+.mobile .play-list-type[data-v-686a7f41] {
+ margin-left: 0px;
+ margin-right: 0px;
+ width: 100%;
+}.recommend-album[data-v-1df7dbee] {
+ margin-left: 1.25rem;
+ margin-right: 1.25rem;
+ flex: 1 1 0%;
+}
+.recommend-album .title[data-v-1df7dbee] {
+ margin-bottom: 1rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.recommend-album .title[data-v-1df7dbee]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.recommend-album .recommend-album-list[data-v-1df7dbee] {
+ display: grid;
+ grid-template-columns: repeat(2, minmax(0, 1fr));
+ grid-template-rows: repeat(3, minmax(0, 1fr));
+ gap: 0.5rem;
+}
+.recommend-album .recommend-album-list-item[data-v-1df7dbee] {
+ position: relative;
+ overflow: hidden;
+ border-radius: 0.75rem;
+}
+.recommend-album .recommend-album-list-item-img[data-v-1df7dbee] {
+ height: 100%;
+ width: 100%;
+ border-radius: 0.75rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.recommend-album .recommend-album-list-item:hover img[data-v-1df7dbee] {
+ filter: brightness(50%);
+}
+.recommend-album .recommend-album-list-item-content[data-v-1df7dbee] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ z-index: 10;
+ height: 100%;
+ width: 100%;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.6;
+ padding: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ opacity: 0;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.recommend-album .recommend-album-list-item-content[data-v-1df7dbee]:is(.dark *) {
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.6;
+}
+.recommend-album .recommend-album-list-item-content[data-v-1df7dbee]:hover {
+ opacity: 1;
+}.recommend-singer-list[data-v-f8da161d] {
+ display: flex;
+ height: 280px;
+}
+.recommend-singer-item[data-v-f8da161d] {
+ margin-right: 1.25rem;
+ display: flex;
+ height: 100%;
+ flex: 1 1 0%;
+ flex-direction: column;
+ justify-content: space-between;
+ overflow: hidden;
+ border-radius: 1.5rem;
+ padding: 1.25rem;
+}
+.recommend-singer-item-bg[data-v-f8da161d] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ z-index: 0;
+ height: 100%;
+ width: 100%;
+ border-radius: 1.5rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(17 24 39 / var(--tw-bg-opacity, 1));
+ background-size: cover;
+ background-position: center;
+ background-repeat: no-repeat;
+}
+.recommend-singer-item-bg[data-v-f8da161d]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.recommend-singer-item-bg[data-v-f8da161d] {
+ filter: brightness(60%);
+}
+.recommend-singer-item-info[data-v-f8da161d] {
+ display: flex;
+ align-items: center;
+ padding: 0.5rem;
+}
+.recommend-singer-item-info-play[data-v-f8da161d] {
+ display: flex;
+ height: 3rem;
+ width: 3rem;
+ cursor: pointer;
+ align-items: center;
+ justify-content: center;
+ border-radius: 9999px;
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.recommend-singer-item-info-play[data-v-f8da161d]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1));
+}
+.recommend-singer-item-info-name[data-v-f8da161d] {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+.recommend-singer-item-info-name[data-v-f8da161d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+.recommend-singer-item-count[data-v-f8da161d] {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+.recommend-singer-item-count[data-v-f8da161d]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+.mobile .recommend-singer-list[data-v-f8da161d] {
+ height: 180px;
+ margin-left: 1rem;
+}
+.mobile .recommend-singer-item[data-v-f8da161d] {
+ border-radius: 0.75rem;
+ padding: 1rem;
+}
+.mobile .recommend-singer-item-bg[data-v-f8da161d] {
+ border-radius: 0.75rem;
+}.title[data-v-ae2da107] {
+ margin-bottom: 1rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.title[data-v-ae2da107]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.recommend-music[data-v-ae2da107] {
+ flex: 1 1 auto;
+}
+.recommend-music .text-ellipsis[data-v-ae2da107] {
+ width: 100%;
+}
+.recommend-music-list[data-v-ae2da107] {
+ width: 100%;
+ border-radius: 1.5rem;
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ padding: 0.5rem;
+}
+.recommend-music-list[data-v-ae2da107]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}.main-page[data-v-b0ca1b97] {
+
+ height: 100%;
+
+ width: 100%;
+
+ overflow: hidden;
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1))
+}
+.main-page[data-v-b0ca1b97]:is(.dark *) {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1))
+}
+.main-content[data-v-b0ca1b97] {
+
+ margin-top: 1.5rem;
+
+ margin-bottom: 7rem;
+
+ display: flex
+}
+.mobile .main-content[data-v-b0ca1b97] {
+
+ margin-left: 1rem;
+
+ margin-right: 1rem;
+
+ flex-direction: column
+}
+.mobile[data-v-b0ca1b97] .favorite-page {
+
+ margin-left: 1rem;
+
+ margin-right: 1rem;
+
+ height: 100%;
+
+ padding: 0px
+}
+[data-v-b0ca1b97] .favorite-page {
+
+ margin-left: 1rem;
+
+ margin-right: 1rem;
+
+ height: 300px;
+
+ padding: 0px
+}
+[data-v-b0ca1b97] .favorite-page .favorite-header {
+
+ margin-bottom: 0px !important;
+
+ padding-left: 0px !important;
+
+ padding-right: 0px !important
+}
+[data-v-b0ca1b97] .favorite-page .favorite-header h2 {
+
+ font-size: 1.125rem;
+
+ line-height: 1.75rem;
+
+ font-weight: 700;
+
+ --tw-text-opacity: 1;
+
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+[data-v-b0ca1b97] .favorite-page .favorite-header h2:is(.dark *) {
+
+ --tw-text-opacity: 1;
+
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+[data-v-b0ca1b97] .favorite-page .favorite-list {
+
+ padding-left: 0px !important;
+
+ padding-right: 0px !important
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-BlaUC8oz.css.gz b/out/renderer/assets/index-BlaUC8oz.css.gz
new file mode 100644
index 0000000..2b686f4
Binary files /dev/null and b/out/renderer/assets/index-BlaUC8oz.css.gz differ
diff --git a/out/renderer/assets/index-BmgzcEyo.css b/out/renderer/assets/index-BmgzcEyo.css
new file mode 100644
index 0000000..eed51fc
--- /dev/null
+++ b/out/renderer/assets/index-BmgzcEyo.css
@@ -0,0 +1,44 @@
+.history-page[data-v-7e434221] {height: 100%;width: 100%;padding-top: 0.5rem;--tw-bg-opacity: 1;background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1))
+}.history-page[data-v-7e434221]:is(.dark *) {--tw-bg-opacity: 1;background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1))
+}
+.history-page .title[data-v-7e434221] {padding-right: 1rem;padding-left: 1rem;padding-bottom: 0.5rem;font-size: 1.25rem;line-height: 1.75rem;font-weight: 700;--tw-text-opacity: 1;color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.history-page .title[data-v-7e434221]:is(.dark *) {--tw-text-opacity: 1;color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.history-page .history-list-content[data-v-7e434221] {margin-top: 0.5rem;padding-left: 1rem;padding-right: 1rem;padding-bottom: 7rem
+}
+.history-page .history-list-content .history-item[data-v-7e434221] {display: flex;align-items: center;justify-content: space-between
+}
+.history-page .history-list-content .history-item-content[data-v-7e434221] {flex: 1 1 0%
+}
+.history-page .history-list-content .history-item-count[data-v-7e434221] {padding-left: 1rem;padding-right: 1rem;text-align: center;font-size: 1.125rem;line-height: 1.75rem;--tw-text-opacity: 1;color: rgb(75 85 99 / var(--tw-text-opacity, 1))
+}
+.history-page .history-list-content .history-item-count[data-v-7e434221]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.history-page .history-list-content .history-item-delete[data-v-7e434221] {display: flex;height: 2rem;width: 2rem;cursor: pointer;align-items: center;justify-content: center;border-radius: 9999px;border-width: 2px;--tw-border-opacity: 1;border-color: rgb(156 163 175 / var(--tw-border-opacity, 1))
+}
+.history-page .history-list-content .history-item-delete[data-v-7e434221]:is(.dark *) {--tw-border-opacity: 1;border-color: rgb(75 85 99 / var(--tw-border-opacity, 1))
+}
+.history-page .history-list-content .history-item-delete[data-v-7e434221] {--tw-text-opacity: 1;color: rgb(75 85 99 / var(--tw-text-opacity, 1))
+}
+.history-page .history-list-content .history-item-delete[data-v-7e434221]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.history-page .history-list-content .history-item-delete[data-v-7e434221]:hover {--tw-border-opacity: 1;border-color: rgb(239 68 68 / var(--tw-border-opacity, 1));--tw-text-opacity: 1;color: rgb(239 68 68 / var(--tw-text-opacity, 1))
+}
+.loading-wrapper[data-v-7e434221] {display: flex;align-items: center;justify-content: center;padding-top: 2rem;padding-bottom: 2rem
+}
+.no-more-tip[data-v-7e434221] {padding-top: 1rem;padding-bottom: 1rem;text-align: center;font-size: 0.875rem;line-height: 1.25rem;--tw-text-opacity: 1;color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.no-more-tip[data-v-7e434221]:is(.dark *) {--tw-text-opacity: 1;color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.flex-item[data-v-36d023b3] {
+ flex: 1 1 0%;
+ overflow: hidden;
+ border-radius: 1rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1))
+}
+.flex-item[data-v-36d023b3]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1))
+}
diff --git a/out/renderer/assets/index-BmgzcEyo.css.gz b/out/renderer/assets/index-BmgzcEyo.css.gz
new file mode 100644
index 0000000..28756f6
Binary files /dev/null and b/out/renderer/assets/index-BmgzcEyo.css.gz differ
diff --git a/out/renderer/assets/index-C-VCusx9.js b/out/renderer/assets/index-C-VCusx9.js
new file mode 100644
index 0000000..56bc1ac
--- /dev/null
+++ b/out/renderer/assets/index-C-VCusx9.js
@@ -0,0 +1,276 @@
+import { ad as request, d as defineComponent, r as ref, g as useStore, j as openBlock, c as createElementBlock, b as createBaseVNode, e as createVNode, u as unref, a7 as getImgUrl, T as createCommentVNode, t as toDisplayString, O as createBlock, i as isRef, n as normalizeClass, ae as audioService, _ as _export_sfc, G as computed, o as onMounted, E as watch, f as withCtx, af as useRoute, ag as useDateFormat, ab as resolveDirective, ac as isMobile, a3 as Fragment, a4 as renderList, s as setAnimationClass, a2 as normalizeStyle, a5 as setAnimationDelay, ah as withModifiers, k as createTextVNode, w as withDirectives } from "./index-DKaFsuse.js";
+import { e as getHotSearch } from "./home-BXGE9AqN.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { M as MusicList, g as getAlbum, a as getListDetail } from "./MusicList-s-QHu-iA.js";
+import { M as MvPlayer } from "./MvPlayer-I4IDK1xL.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import { _ as __unplugin_components_1 } from "./Layout-CvYBg1vI.js";
+import "./Ellipsis-D4R5dIX2.js";
+import "./Drawer-BEJ8Ydua.js";
+import "./Avatar-rQ2og-6c.js";
+import "./Tag-C0oC92WF.js";
+import "./Icon-DucaliTK.js";
+import "./Slider-BA6NituQ.js";
+import "./use-locale-DLWAOXez.js";
+const getSearch = (params) => {
+ return request.get("/cloudsearch", {
+ params
+ });
+};
+const _hoisted_1$1 = { class: "search-item-img" };
+const _hoisted_2$1 = {
+ key: 0,
+ class: "play"
+};
+const _hoisted_3$1 = { class: "search-item-info" };
+const _hoisted_4$1 = { class: "search-item-name" };
+const _hoisted_5$1 = { class: "search-item-artist" };
+const _sfc_main$1 = /* @__PURE__ */ defineComponent({
+ __name: "SearchItem",
+ props: {
+ item: {}
+ },
+ setup(__props) {
+ const props = __props;
+ const songList = ref([]);
+ const showPop = ref(false);
+ const listInfo = ref(null);
+ const getCurrentMv = () => {
+ return {
+ id: props.item.id,
+ name: props.item.name
+ };
+ };
+ const store = useStore();
+ const handleClick = async () => {
+ listInfo.value = null;
+ if (props.item.type === "专辑") {
+ showPop.value = true;
+ const res = await getAlbum(props.item.id);
+ songList.value = res.data.songs.map((song) => {
+ song.al.picUrl = song.al.picUrl || props.item.picUrl;
+ return song;
+ });
+ listInfo.value = {
+ ...res.data.album,
+ creator: {
+ avatarUrl: res.data.album.artist.img1v1Url,
+ nickname: `${res.data.album.artist.name} - ${res.data.album.company}`
+ },
+ description: res.data.album.description
+ };
+ }
+ if (props.item.type === "playlist") {
+ showPop.value = true;
+ const res = await getListDetail(props.item.id);
+ songList.value = res.data.playlist.tracks;
+ listInfo.value = res.data.playlist;
+ }
+ if (props.item.type === "mv") {
+ store.commit("setIsPlay", false);
+ store.commit("setPlayMusic", false);
+ audioService.getCurrentSound()?.pause();
+ showPop.value = true;
+ }
+ };
+ return (_ctx, _cache) => {
+ const _component_n_image = NImage;
+ return openBlock(), createElementBlock("div", {
+ class: normalizeClass(["search-item", _ctx.item.type]),
+ onClick: handleClick
+ }, [
+ createBaseVNode("div", _hoisted_1$1, [
+ createVNode(_component_n_image, {
+ src: unref(getImgUrl)(_ctx.item.picUrl, _ctx.item.type === "mv" ? "320y180" : "100y100"),
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ _ctx.item.type === "mv" ? (openBlock(), createElementBlock("div", _hoisted_2$1, _cache[2] || (_cache[2] = [
+ createBaseVNode("i", { class: "iconfont icon icon-play" }, null, -1)
+ ]))) : createCommentVNode("", true)
+ ]),
+ createBaseVNode("div", _hoisted_3$1, [
+ createBaseVNode("p", _hoisted_4$1, toDisplayString(_ctx.item.name), 1),
+ createBaseVNode("p", _hoisted_5$1, toDisplayString(_ctx.item.desc), 1)
+ ]),
+ ["专辑", "playlist"].includes(_ctx.item.type) ? (openBlock(), createBlock(MusicList, {
+ key: 0,
+ show: unref(showPop),
+ "onUpdate:show": _cache[0] || (_cache[0] = ($event) => isRef(showPop) ? showPop.value = $event : null),
+ name: _ctx.item.name,
+ "song-list": unref(songList),
+ "list-info": unref(listInfo),
+ cover: false
+ }, null, 8, ["show", "name", "song-list", "list-info"])) : createCommentVNode("", true),
+ _ctx.item.type === "mv" ? (openBlock(), createBlock(MvPlayer, {
+ key: 1,
+ show: unref(showPop),
+ "onUpdate:show": _cache[1] || (_cache[1] = ($event) => isRef(showPop) ? showPop.value = $event : null),
+ "current-mv": getCurrentMv(),
+ "no-list": ""
+ }, null, 8, ["show", "current-mv"])) : createCommentVNode("", true)
+ ], 2);
+ };
+ }
+});
+const SearchItem = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-3449f610"]]);
+const _hoisted_1 = { class: "search-page" };
+const _hoisted_2 = { class: "hot-search-list" };
+const _hoisted_3 = ["onClick"];
+const _hoisted_4 = { class: "title" };
+const _hoisted_5 = { class: "search-list-box" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "Search"
+ },
+ __name: "index",
+ setup(__props) {
+ const route = useRoute();
+ const store = useStore();
+ const searchDetail = ref();
+ const searchType = computed(() => store.state.searchType);
+ const searchDetailLoading = ref(false);
+ const hotSearchData = ref();
+ const loadHotSearch = async () => {
+ const { data } = await getHotSearch();
+ hotSearchData.value = data;
+ };
+ onMounted(() => {
+ loadHotSearch();
+ loadSearch(route.query.keyword);
+ });
+ const hotKeyword = ref(route.query.keyword || "搜索列表");
+ watch(
+ () => store.state.searchValue,
+ (value) => {
+ loadSearch(value);
+ }
+ );
+ const dateFormat = (time) => useDateFormat(time, "YYYY.MM.DD").value;
+ const loadSearch = async (keywords, type = null) => {
+ hotKeyword.value = keywords;
+ searchDetail.value = void 0;
+ if (!keywords) return;
+ searchDetailLoading.value = true;
+ const { data } = await getSearch({ keywords, type: type || searchType.value });
+ const songs = data.result.songs || [];
+ const albums = data.result.albums || [];
+ const mvs = (data.result.mvs || []).map((item) => ({
+ ...item,
+ picUrl: item.cover,
+ playCount: item.playCount,
+ desc: item.artists.map((artist) => artist.name).join("/"),
+ type: "mv"
+ }));
+ const playlists = (data.result.playlists || []).map((item) => ({
+ ...item,
+ picUrl: item.coverImgUrl,
+ playCount: item.playCount,
+ desc: item.creator.nickname,
+ type: "playlist"
+ }));
+ songs.forEach((item) => {
+ item.picUrl = item.al.picUrl;
+ item.artists = item.ar;
+ });
+ albums.forEach((item) => {
+ item.desc = `${item.artist.name} ${item.company} ${dateFormat(item.publishTime)}`;
+ });
+ searchDetail.value = {
+ songs,
+ albums,
+ mvs,
+ playlists
+ };
+ searchDetailLoading.value = false;
+ };
+ watch(
+ () => route.path,
+ async (path) => {
+ if (path === "/search") {
+ store.state.searchValue = route.query.keyword;
+ }
+ }
+ );
+ const handlePlay = () => {
+ const tracks = searchDetail.value?.songs || [];
+ store.commit("setPlayList", tracks);
+ };
+ return (_ctx, _cache) => {
+ const _component_n_layout = __unplugin_components_1;
+ const _directive_loading = resolveDirective("loading");
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ (unref(isMobile) ? !searchDetail.value : true) ? (openBlock(), createBlock(_component_n_layout, {
+ key: 0,
+ class: normalizeClass(["hot-search", unref(setAnimationClass)("animate__fadeInDown")]),
+ "native-scrollbar": false
+ }, {
+ default: withCtx(() => [
+ _cache[0] || (_cache[0] = createBaseVNode("div", { class: "title" }, "热搜列表", -1)),
+ createBaseVNode("div", _hoisted_2, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(hotSearchData.value?.data, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: index2,
+ class: normalizeClass([unref(setAnimationClass)("animate__bounceInLeft"), "hot-search-item"]),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 10)),
+ onClick: withModifiers(($event) => loadSearch(item.searchWord, 1), ["stop"])
+ }, [
+ createBaseVNode("span", {
+ class: normalizeClass(["hot-search-item-count", { "hot-search-item-count-3": index2 < 3 }])
+ }, toDisplayString(index2 + 1), 3),
+ createTextVNode(" " + toDisplayString(item.searchWord), 1)
+ ], 14, _hoisted_3);
+ }), 128))
+ ])
+ ]),
+ _: 1
+ }, 8, ["class"])) : createCommentVNode("", true),
+ (unref(isMobile) ? searchDetail.value : true) ? (openBlock(), createBlock(_component_n_layout, {
+ key: 1,
+ class: normalizeClass(["search-list", unref(setAnimationClass)("animate__fadeInUp")]),
+ "native-scrollbar": false
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_4, toDisplayString(hotKeyword.value), 1),
+ withDirectives((openBlock(), createElementBlock("div", _hoisted_5, [
+ searchDetail.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(searchDetail.value?.songs, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(unref(setAnimationClass)("animate__bounceInRight")),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 50))
+ }, [
+ createVNode(SongItem, {
+ item,
+ onPlay: handlePlay
+ }, null, 8, ["item"])
+ ], 6);
+ }), 128)),
+ (openBlock(true), createElementBlock(Fragment, null, renderList(searchDetail.value, (list, key) => {
+ return openBlock(), createElementBlock(Fragment, null, [
+ key.toString() !== "songs" ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(list, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(unref(setAnimationClass)("animate__bounceInRight")),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 50))
+ }, [
+ createVNode(SearchItem, { item }, null, 8, ["item"])
+ ], 6);
+ }), 128)) : createCommentVNode("", true)
+ ], 64);
+ }), 256))
+ ], 64)) : createCommentVNode("", true)
+ ])), [
+ [_directive_loading, searchDetailLoading.value]
+ ])
+ ]),
+ _: 1
+ }, 8, ["class"])) : createCommentVNode("", true)
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-254ebbc1"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-C-VCusx9.js.gz b/out/renderer/assets/index-C-VCusx9.js.gz
new file mode 100644
index 0000000..49050e5
Binary files /dev/null and b/out/renderer/assets/index-C-VCusx9.js.gz differ
diff --git a/out/renderer/assets/index-COH3Oisr.css b/out/renderer/assets/index-COH3Oisr.css
new file mode 100644
index 0000000..d389a75
--- /dev/null
+++ b/out/renderer/assets/index-COH3Oisr.css
@@ -0,0 +1,197 @@
+.user-page[data-v-be63ae6f] {
+ display: flex;
+ height: 100%;
+}
+.user-page .left[data-v-be63ae6f] {
+ max-width: 600px;
+ position: relative;
+ height: 100%;
+ flex: 1 1 0%;
+ overflow: hidden;
+ border-radius: 1rem;
+ background-repeat: no-repeat;
+ --tw-bg-opacity: 1;
+ background-color: rgb(17 24 39 / var(--tw-bg-opacity, 1));
+}
+.user-page .left[data-v-be63ae6f]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+.user-page .left .page[data-v-be63ae6f] {
+ z-index: 10;
+ display: flex;
+ height: 100%;
+ width: 100%;
+ flex-direction: column;
+ padding: 1rem;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.4;
+}
+.user-page .left .title[data-v-be63ae6f] {
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.user-page .left .title[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.user-page .left .user-name[data-v-be63ae6f] {
+ margin-bottom: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ --tw-text-opacity: 0.7;
+}
+.user-page .left .uesr-signature[data-v-be63ae6f] {
+ margin-top: 1rem;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ --tw-text-opacity: 0.7;
+}
+.user-page .left .user-info[data-v-be63ae6f] {
+ display: flex;
+ align-items: center;
+}
+.user-page .left .user-info-list[data-v-be63ae6f] {
+ display: flex;
+ width: 40%;
+ justify-content: space-around;
+ text-align: center;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ --tw-text-opacity: 0.7;
+}
+.user-page .left .user-info-list .label[data-v-be63ae6f] {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.user-page .right[data-v-be63ae6f] {
+ margin-left: 1rem;
+ height: 100%;
+ flex: 1 1 0%;
+ overflow: hidden;
+}
+.user-page .right .record-list[data-v-be63ae6f] {
+ border-radius: 1rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.user-page .right .record-list[data-v-be63ae6f]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.user-page .right .record-list[data-v-be63ae6f] {
+ height: calc(100% - 3.75rem);
+}
+.user-page .right .record-list .record-item[data-v-be63ae6f] {
+ display: flex;
+ align-items: center;
+ padding-left: 1rem;
+ padding-right: 1rem;
+}
+.user-page .right .record-list .song-item[data-v-be63ae6f] {
+ flex: 1 1 0%;
+}
+.user-page .right .record-list .play-count[data-v-be63ae6f] {
+ margin-left: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+.user-page .right .record-list .play-count[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.user-page .right .title[data-v-be63ae6f] {
+ margin: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.user-page .right .title[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list[data-v-be63ae6f] {
+ margin-top: 1rem;
+ flex: 1 1 0%;
+ overflow: hidden;
+ border-radius: 0.75rem;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.play-list[data-v-be63ae6f]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.play-list-title[data-v-be63ae6f] {
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.play-list-title[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list-item[data-v-be63ae6f] {
+ display: flex;
+ cursor: pointer;
+ align-items: center;
+ border-radius: 0.75rem;
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+ padding-top: 0.25rem;
+ padding-bottom: 0.25rem;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 200ms;
+}
+.play-list-item[data-v-be63ae6f]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(233 236 239 / var(--tw-bg-opacity, 1));
+}
+.play-list-item[data-v-be63ae6f]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(45 45 45 / var(--tw-bg-opacity, 1));
+}
+.play-list-item-img[data-v-be63ae6f] {
+ width: 60px;
+ height: 60px;
+ border-radius: 0.75rem;
+}
+.play-list-item-info[data-v-be63ae6f] {
+ margin-left: 0.5rem;
+}
+.play-list-item-name[data-v-be63ae6f] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.play-list-item-name[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.play-list-item-count[data-v-be63ae6f] {
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.play-list-item-count[data-v-be63ae6f]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.mobile .user-page[data-v-be63ae6f] {
+ padding-left: 1rem;
+ padding-right: 1rem;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-COH3Oisr.css.gz b/out/renderer/assets/index-COH3Oisr.css.gz
new file mode 100644
index 0000000..32dffea
Binary files /dev/null and b/out/renderer/assets/index-COH3Oisr.css.gz differ
diff --git a/out/renderer/assets/index-ChDcb7c6.css b/out/renderer/assets/index-ChDcb7c6.css
new file mode 100644
index 0000000..8006188
--- /dev/null
+++ b/out/renderer/assets/index-ChDcb7c6.css
@@ -0,0 +1,7332 @@
+@charset "UTF-8";@font-face {
+ font-family: 'iconfont'; /* Project id 2685283 */
+ src:
+ url('./iconfont-DzQUHqRQ.woff2?t=1703643214551') format('woff2'),
+ url('./iconfont-53c_NoX9.woff?t=1703643214551') format('woff'),
+ url('./iconfont-Cio8idH0.ttf?t=1703643214551') format('truetype');
+}
+
+.iconfont {
+ font-family: 'iconfont' !important;
+ font-size: 16px;
+ font-style: normal;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+}
+
+.icon-list:before {
+ content: '\e603';
+}
+
+.icon-maxsize:before {
+ content: '\e692';
+}
+
+.icon-close:before {
+ content: '\e616';
+}
+
+.icon-minisize:before {
+ content: '\e602';
+}
+
+.icon-shuaxin:before {
+ content: '\e627';
+}
+
+.icon-icon_error:before {
+ content: '\e615';
+}
+
+.icon-a-3User:before {
+ content: '\e601';
+}
+
+.icon-Chat:before {
+ content: '\e605';
+}
+
+.icon-Category:before {
+ content: '\e606';
+}
+
+.icon-Document:before {
+ content: '\e607';
+}
+
+.icon-Heart:before {
+ content: '\e608';
+}
+
+.icon-Hide:before {
+ content: '\e609';
+}
+
+.icon-Home:before {
+ content: '\e60a';
+}
+
+.icon-a-Image2:before {
+ content: '\e60b';
+}
+
+.icon-Profile:before {
+ content: '\e60c';
+}
+
+.icon-Search:before {
+ content: '\e60d';
+}
+
+.icon-Paper:before {
+ content: '\e60e';
+}
+
+.icon-Play:before {
+ content: '\e60f';
+}
+
+.icon-Setting:before {
+ content: '\e610';
+}
+
+.icon-a-TicketStar:before {
+ content: '\e611';
+}
+
+.icon-a-VolumeOff:before {
+ content: '\e612';
+}
+
+.icon-a-VolumeUp:before {
+ content: '\e613';
+}
+
+.icon-a-VolumeDown:before {
+ content: '\e614';
+}
+
+.icon-stop:before {
+ content: '\e600';
+}
+
+.icon-next:before {
+ content: '\e6a9';
+}
+
+.icon-prev:before {
+ content: '\e6ac';
+}
+
+.icon-play:before {
+ content: '\e6aa';
+}
+
+.icon-xiasanjiaoxing:before {
+ content: '\e642';
+}
+
+.icon-videofill:before {
+ content: '\e7c7';
+}
+
+.icon-favorfill:before {
+ content: '\e64b';
+}
+
+.icon-favor:before {
+ content: '\e64c';
+}
+
+.icon-loading:before {
+ content: '\e64f';
+}
+
+.icon-search:before {
+ content: '\e65c';
+}
+
+.icon-likefill:before {
+ content: '\e668';
+}
+
+.icon-like:before {
+ content: '\e669';
+}
+
+.icon-notificationfill:before {
+ content: '\e66a';
+}
+
+.icon-notification:before {
+ content: '\e66b';
+}
+
+.icon-evaluate:before {
+ content: '\e672';
+}
+
+.icon-homefill:before {
+ content: '\e6bb';
+}
+
+.icon-link:before {
+ content: '\e6bf';
+}
+
+.icon-roundaddfill:before {
+ content: '\e6d8';
+}
+
+.icon-roundadd:before {
+ content: '\e6d9';
+}
+
+.icon-add:before {
+ content: '\e6da';
+}
+
+.icon-appreciatefill:before {
+ content: '\e6e3';
+}
+
+.icon-forwardfill:before {
+ content: '\e6ea';
+}
+
+.icon-voicefill:before {
+ content: '\e6f0';
+}
+
+.icon-wefill:before {
+ content: '\e6f4';
+}
+
+.icon-keyboard:before {
+ content: '\e71b';
+}
+
+.icon-picfill:before {
+ content: '\e72c';
+}
+
+.icon-markfill:before {
+ content: '\e730';
+}
+
+.icon-presentfill:before {
+ content: '\e732';
+}
+
+.icon-peoplefill:before {
+ content: '\e735';
+}
+
+.icon-read:before {
+ content: '\e742';
+}
+
+.icon-backwardfill:before {
+ content: '\e74d';
+}
+
+.icon-playfill:before {
+ content: '\e74f';
+}
+
+.icon-all:before {
+ content: '\e755';
+}
+
+.icon-hotfill:before {
+ content: '\e757';
+}
+
+.icon-recordfill:before {
+ content: '\e7a4';
+}
+
+.icon-full:before {
+ content: '\e7bc';
+}
+
+.icon-favor_fill_light:before {
+ content: '\e7ec';
+}
+
+.icon-round_favor_fill:before {
+ content: '\e80a';
+}
+
+.icon-round_location_fill:before {
+ content: '\e80b';
+}
+
+.icon-round_like_fill:before {
+ content: '\e80c';
+}
+
+.icon-round_people_fill:before {
+ content: '\e80d';
+}
+
+.icon-round_skin_fill:before {
+ content: '\e80e';
+}
+
+.icon-broadcast_fill:before {
+ content: '\e81d';
+}
+
+.icon-card_fill:before {
+ content: '\e81f';
+}
+ /*!
+ * animate.css - https://animate.style/
+ * Version - 4.1.1
+ * Licensed under the MIT license - http://opensource.org/licenses/MIT
+ *
+ * Copyright (c) 2020 Animate.css
+ */
+:root {
+ --animate-duration: 1s;
+ --animate-delay: 1s;
+ --animate-repeat: 1;
+}
+.animate__animated {
+ animation-duration: 1s;
+ animation-duration: var(--animate-duration);
+ animation-fill-mode: both;
+}
+.animate__animated.animate__infinite {
+ animation-iteration-count: infinite;
+}
+.animate__animated.animate__repeat-1 {
+ animation-iteration-count: 1;
+ animation-iteration-count: var(--animate-repeat);
+}
+.animate__animated.animate__repeat-2 {
+ animation-iteration-count: 2;
+ animation-iteration-count: calc(var(--animate-repeat) * 2);
+}
+.animate__animated.animate__repeat-3 {
+ animation-iteration-count: 3;
+ animation-iteration-count: calc(var(--animate-repeat) * 3);
+}
+.animate__animated.animate__delay-1s {
+ animation-delay: 1s;
+ animation-delay: var(--animate-delay);
+}
+.animate__animated.animate__delay-2s {
+ animation-delay: 2s;
+ animation-delay: calc(var(--animate-delay) * 2);
+}
+.animate__animated.animate__delay-3s {
+ animation-delay: 3s;
+ animation-delay: calc(var(--animate-delay) * 3);
+}
+.animate__animated.animate__delay-4s {
+ animation-delay: 4s;
+ animation-delay: calc(var(--animate-delay) * 4);
+}
+.animate__animated.animate__delay-5s {
+ animation-delay: 5s;
+ animation-delay: calc(var(--animate-delay) * 5);
+}
+.animate__animated.animate__faster {
+ animation-duration: 0.5s;
+ animation-duration: calc(var(--animate-duration) / 2);
+}
+.animate__animated.animate__fast {
+ animation-duration: 0.8s;
+ animation-duration: calc(var(--animate-duration) * 0.8);
+}
+.animate__animated.animate__slow {
+ animation-duration: 2s;
+ animation-duration: calc(var(--animate-duration) * 2);
+}
+.animate__animated.animate__slower {
+ animation-duration: 3s;
+ animation-duration: calc(var(--animate-duration) * 3);
+}
+@media (prefers-reduced-motion: reduce), print {
+ .animate__animated {
+ animation-duration: 1ms !important;
+ transition-duration: 1ms !important;
+ animation-iteration-count: 1 !important;
+ }
+ .animate__animated[class*='Out'] {
+ opacity: 0;
+ }
+}
+@keyframes bounce {
+ 0%,
+ 20%,
+ 53%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ transform: translateZ(0);
+ }
+ 40%,
+ 43% {
+ animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
+ transform: translate3d(0, -30px, 0) scaleY(1.1);
+ }
+ 70% {
+ animation-timing-function: cubic-bezier(0.755, 0.05, 0.855, 0.06);
+ transform: translate3d(0, -15px, 0) scaleY(1.05);
+ }
+ 80% {
+ transition-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ transform: translateZ(0) scaleY(0.95);
+ }
+ 90% {
+ transform: translate3d(0, -4px, 0) scaleY(1.02);
+ }
+}
+.animate__bounce {
+ animation-name: bounce;
+ transform-origin: center bottom;
+}
+@keyframes flash {
+ 0%,
+ 50%,
+ to {
+ opacity: 1;
+ }
+ 25%,
+ 75% {
+ opacity: 0;
+ }
+}
+.animate__flash {
+ animation-name: flash;
+}
+@keyframes pulse {
+ 0% {
+ transform: scaleX(1);
+ }
+ 50% {
+ transform: scale3d(1.05, 1.05, 1.05);
+ }
+ to {
+ transform: scaleX(1);
+ }
+}
+.animate__pulse {
+ animation-name: pulse;
+ animation-timing-function: ease-in-out;
+}
+@keyframes rubberBand {
+ 0% {
+ transform: scaleX(1);
+ }
+ 30% {
+ transform: scale3d(1.25, 0.75, 1);
+ }
+ 40% {
+ transform: scale3d(0.75, 1.25, 1);
+ }
+ 50% {
+ transform: scale3d(1.15, 0.85, 1);
+ }
+ 65% {
+ transform: scale3d(0.95, 1.05, 1);
+ }
+ 75% {
+ transform: scale3d(1.05, 0.95, 1);
+ }
+ to {
+ transform: scaleX(1);
+ }
+}
+.animate__rubberBand {
+ animation-name: rubberBand;
+}
+@keyframes shakeX {
+ 0%,
+ to {
+ transform: translateZ(0);
+ }
+ 10%,
+ 30%,
+ 50%,
+ 70%,
+ 90% {
+ transform: translate3d(-10px, 0, 0);
+ }
+ 20%,
+ 40%,
+ 60%,
+ 80% {
+ transform: translate3d(10px, 0, 0);
+ }
+}
+.animate__shakeX {
+ animation-name: shakeX;
+}
+@keyframes shakeY {
+ 0%,
+ to {
+ transform: translateZ(0);
+ }
+ 10%,
+ 30%,
+ 50%,
+ 70%,
+ 90% {
+ transform: translate3d(0, -10px, 0);
+ }
+ 20%,
+ 40%,
+ 60%,
+ 80% {
+ transform: translate3d(0, 10px, 0);
+ }
+}
+.animate__shakeY {
+ animation-name: shakeY;
+}
+@keyframes headShake {
+ 0% {
+ transform: translateX(0);
+ }
+ 6.5% {
+ transform: translateX(-6px) rotateY(-9deg);
+ }
+ 18.5% {
+ transform: translateX(5px) rotateY(7deg);
+ }
+ 31.5% {
+ transform: translateX(-3px) rotateY(-5deg);
+ }
+ 43.5% {
+ transform: translateX(2px) rotateY(3deg);
+ }
+ 50% {
+ transform: translateX(0);
+ }
+}
+.animate__headShake {
+ animation-timing-function: ease-in-out;
+ animation-name: headShake;
+}
+@keyframes swing {
+ 20% {
+ transform: rotate(15deg);
+ }
+ 40% {
+ transform: rotate(-10deg);
+ }
+ 60% {
+ transform: rotate(5deg);
+ }
+ 80% {
+ transform: rotate(-5deg);
+ }
+ to {
+ transform: rotate(0deg);
+ }
+}
+.animate__swing {
+ transform-origin: top center;
+ animation-name: swing;
+}
+@keyframes tada {
+ 0% {
+ transform: scaleX(1);
+ }
+ 10%,
+ 20% {
+ transform: scale3d(0.9, 0.9, 0.9) rotate(-3deg);
+ }
+ 30%,
+ 50%,
+ 70%,
+ 90% {
+ transform: scale3d(1.1, 1.1, 1.1) rotate(3deg);
+ }
+ 40%,
+ 60%,
+ 80% {
+ transform: scale3d(1.1, 1.1, 1.1) rotate(-3deg);
+ }
+ to {
+ transform: scaleX(1);
+ }
+}
+.animate__tada {
+ animation-name: tada;
+}
+@keyframes wobble {
+ 0% {
+ transform: translateZ(0);
+ }
+ 15% {
+ transform: translate3d(-25%, 0, 0) rotate(-5deg);
+ }
+ 30% {
+ transform: translate3d(20%, 0, 0) rotate(3deg);
+ }
+ 45% {
+ transform: translate3d(-15%, 0, 0) rotate(-3deg);
+ }
+ 60% {
+ transform: translate3d(10%, 0, 0) rotate(2deg);
+ }
+ 75% {
+ transform: translate3d(-5%, 0, 0) rotate(-1deg);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__wobble {
+ animation-name: wobble;
+}
+@keyframes jello {
+ 0%,
+ 11.1%,
+ to {
+ transform: translateZ(0);
+ }
+ 22.2% {
+ transform: skewX(-12.5deg) skewY(-12.5deg);
+ }
+ 33.3% {
+ transform: skewX(6.25deg) skewY(6.25deg);
+ }
+ 44.4% {
+ transform: skewX(-3.125deg) skewY(-3.125deg);
+ }
+ 55.5% {
+ transform: skewX(1.5625deg) skewY(1.5625deg);
+ }
+ 66.6% {
+ transform: skewX(-0.78125deg) skewY(-0.78125deg);
+ }
+ 77.7% {
+ transform: skewX(0.390625deg) skewY(0.390625deg);
+ }
+ 88.8% {
+ transform: skewX(-0.1953125deg) skewY(-0.1953125deg);
+ }
+}
+.animate__jello {
+ animation-name: jello;
+ transform-origin: center;
+}
+@keyframes heartBeat {
+ 0% {
+ transform: scale(1);
+ }
+ 14% {
+ transform: scale(1.3);
+ }
+ 28% {
+ transform: scale(1);
+ }
+ 42% {
+ transform: scale(1.3);
+ }
+ 70% {
+ transform: scale(1);
+ }
+}
+.animate__heartBeat {
+ animation-name: heartBeat;
+ animation-duration: 1.3s;
+ animation-duration: calc(var(--animate-duration) * 1.3);
+ animation-timing-function: ease-in-out;
+}
+@keyframes backInDown {
+ 0% {
+ transform: translateY(-1200px) scale(0.7);
+ opacity: 0.7;
+ }
+ 80% {
+ transform: translateY(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: scale(1);
+ opacity: 1;
+ }
+}
+.animate__backInDown {
+ animation-name: backInDown;
+}
+@keyframes backInLeft {
+ 0% {
+ transform: translateX(-2000px) scale(0.7);
+ opacity: 0.7;
+ }
+ 80% {
+ transform: translateX(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: scale(1);
+ opacity: 1;
+ }
+}
+.animate__backInLeft {
+ animation-name: backInLeft;
+}
+@keyframes backInRight {
+ 0% {
+ transform: translateX(2000px) scale(0.7);
+ opacity: 0.7;
+ }
+ 80% {
+ transform: translateX(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: scale(1);
+ opacity: 1;
+ }
+}
+.animate__backInRight {
+ animation-name: backInRight;
+}
+@keyframes backInUp {
+ 0% {
+ transform: translateY(1200px) scale(0.7);
+ opacity: 0.7;
+ }
+ 80% {
+ transform: translateY(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: scale(1);
+ opacity: 1;
+ }
+}
+.animate__backInUp {
+ animation-name: backInUp;
+}
+@keyframes backOutDown {
+ 0% {
+ transform: scale(1);
+ opacity: 1;
+ }
+ 20% {
+ transform: translateY(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: translateY(700px) scale(0.7);
+ opacity: 0.7;
+ }
+}
+.animate__backOutDown {
+ animation-name: backOutDown;
+}
+@keyframes backOutLeft {
+ 0% {
+ transform: scale(1);
+ opacity: 1;
+ }
+ 20% {
+ transform: translateX(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: translateX(-2000px) scale(0.7);
+ opacity: 0.7;
+ }
+}
+.animate__backOutLeft {
+ animation-name: backOutLeft;
+}
+@keyframes backOutRight {
+ 0% {
+ transform: scale(1);
+ opacity: 1;
+ }
+ 20% {
+ transform: translateX(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: translateX(2000px) scale(0.7);
+ opacity: 0.7;
+ }
+}
+.animate__backOutRight {
+ animation-name: backOutRight;
+}
+@keyframes backOutUp {
+ 0% {
+ transform: scale(1);
+ opacity: 1;
+ }
+ 20% {
+ transform: translateY(0) scale(0.7);
+ opacity: 0.7;
+ }
+ to {
+ transform: translateY(-700px) scale(0.7);
+ opacity: 0.7;
+ }
+}
+.animate__backOutUp {
+ animation-name: backOutUp;
+}
+@keyframes bounceIn {
+ 0%,
+ 20%,
+ 40%,
+ 60%,
+ 80%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ }
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.3, 0.3, 0.3);
+ }
+ 20% {
+ transform: scale3d(1.1, 1.1, 1.1);
+ }
+ 40% {
+ transform: scale3d(0.9, 0.9, 0.9);
+ }
+ 60% {
+ opacity: 1;
+ transform: scale3d(1.03, 1.03, 1.03);
+ }
+ 80% {
+ transform: scale3d(0.97, 0.97, 0.97);
+ }
+ to {
+ opacity: 1;
+ transform: scaleX(1);
+ }
+}
+.animate__bounceIn {
+ animation-duration: 0.75s;
+ animation-duration: calc(var(--animate-duration) * 0.75);
+ animation-name: bounceIn;
+}
+@keyframes bounceInDown {
+ 0%,
+ 60%,
+ 75%,
+ 90%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ }
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, -3000px, 0) scaleY(3);
+ }
+ 60% {
+ opacity: 1;
+ transform: translate3d(0, 25px, 0) scaleY(0.9);
+ }
+ 75% {
+ transform: translate3d(0, -10px, 0) scaleY(0.95);
+ }
+ 90% {
+ transform: translate3d(0, 5px, 0) scaleY(0.985);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__bounceInDown {
+ animation-name: bounceInDown;
+}
+@keyframes bounceInLeft {
+ 0%,
+ 60%,
+ 75%,
+ 90%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ }
+ 0% {
+ opacity: 0;
+ transform: translate3d(-3000px, 0, 0) scaleX(3);
+ }
+ 60% {
+ opacity: 1;
+ transform: translate3d(25px, 0, 0) scaleX(1);
+ }
+ 75% {
+ transform: translate3d(-10px, 0, 0) scaleX(0.98);
+ }
+ 90% {
+ transform: translate3d(5px, 0, 0) scaleX(0.995);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__bounceInLeft {
+ animation-name: bounceInLeft;
+}
+@keyframes bounceInRight {
+ 0%,
+ 60%,
+ 75%,
+ 90%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ }
+ 0% {
+ opacity: 0;
+ transform: translate3d(3000px, 0, 0) scaleX(3);
+ }
+ 60% {
+ opacity: 1;
+ transform: translate3d(-25px, 0, 0) scaleX(1);
+ }
+ 75% {
+ transform: translate3d(10px, 0, 0) scaleX(0.98);
+ }
+ 90% {
+ transform: translate3d(-5px, 0, 0) scaleX(0.995);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__bounceInRight {
+ animation-name: bounceInRight;
+}
+@keyframes bounceInUp {
+ 0%,
+ 60%,
+ 75%,
+ 90%,
+ to {
+ animation-timing-function: cubic-bezier(0.215, 0.61, 0.355, 1);
+ }
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, 3000px, 0) scaleY(5);
+ }
+ 60% {
+ opacity: 1;
+ transform: translate3d(0, -20px, 0) scaleY(0.9);
+ }
+ 75% {
+ transform: translate3d(0, 10px, 0) scaleY(0.95);
+ }
+ 90% {
+ transform: translate3d(0, -5px, 0) scaleY(0.985);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__bounceInUp {
+ animation-name: bounceInUp;
+}
+@keyframes bounceOut {
+ 20% {
+ transform: scale3d(0.9, 0.9, 0.9);
+ }
+ 50%,
+ 55% {
+ opacity: 1;
+ transform: scale3d(1.1, 1.1, 1.1);
+ }
+ to {
+ opacity: 0;
+ transform: scale3d(0.3, 0.3, 0.3);
+ }
+}
+.animate__bounceOut {
+ animation-duration: 0.75s;
+ animation-duration: calc(var(--animate-duration) * 0.75);
+ animation-name: bounceOut;
+}
+@keyframes bounceOutDown {
+ 20% {
+ transform: translate3d(0, 10px, 0) scaleY(0.985);
+ }
+ 40%,
+ 45% {
+ opacity: 1;
+ transform: translate3d(0, -20px, 0) scaleY(0.9);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, 2000px, 0) scaleY(3);
+ }
+}
+.animate__bounceOutDown {
+ animation-name: bounceOutDown;
+}
+@keyframes bounceOutLeft {
+ 20% {
+ opacity: 1;
+ transform: translate3d(20px, 0, 0) scaleX(0.9);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(-2000px, 0, 0) scaleX(2);
+ }
+}
+.animate__bounceOutLeft {
+ animation-name: bounceOutLeft;
+}
+@keyframes bounceOutRight {
+ 20% {
+ opacity: 1;
+ transform: translate3d(-20px, 0, 0) scaleX(0.9);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(2000px, 0, 0) scaleX(2);
+ }
+}
+.animate__bounceOutRight {
+ animation-name: bounceOutRight;
+}
+@keyframes bounceOutUp {
+ 20% {
+ transform: translate3d(0, -10px, 0) scaleY(0.985);
+ }
+ 40%,
+ 45% {
+ opacity: 1;
+ transform: translate3d(0, 20px, 0) scaleY(0.9);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, -2000px, 0) scaleY(3);
+ }
+}
+.animate__bounceOutUp {
+ animation-name: bounceOutUp;
+}
+@keyframes fadeIn {
+ 0% {
+ opacity: 0;
+ }
+ to {
+ opacity: 1;
+ }
+}
+.animate__fadeIn {
+ animation-name: fadeIn;
+}
+@keyframes fadeInDown {
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, -100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInDown {
+ animation-name: fadeInDown;
+}
+@keyframes fadeInDownBig {
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, -2000px, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInDownBig {
+ animation-name: fadeInDownBig;
+}
+@keyframes fadeInLeft {
+ 0% {
+ opacity: 0;
+ transform: translate3d(-100%, 0, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInLeft {
+ animation-name: fadeInLeft;
+}
+@keyframes fadeInLeftBig {
+ 0% {
+ opacity: 0;
+ transform: translate3d(-2000px, 0, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInLeftBig {
+ animation-name: fadeInLeftBig;
+}
+@keyframes fadeInRight {
+ 0% {
+ opacity: 0;
+ transform: translate3d(100%, 0, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInRight {
+ animation-name: fadeInRight;
+}
+@keyframes fadeInRightBig {
+ 0% {
+ opacity: 0;
+ transform: translate3d(2000px, 0, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInRightBig {
+ animation-name: fadeInRightBig;
+}
+@keyframes fadeInUp {
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, 100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInUp {
+ animation-name: fadeInUp;
+}
+@keyframes fadeInUpBig {
+ 0% {
+ opacity: 0;
+ transform: translate3d(0, 2000px, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInUpBig {
+ animation-name: fadeInUpBig;
+}
+@keyframes fadeInTopLeft {
+ 0% {
+ opacity: 0;
+ transform: translate3d(-100%, -100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInTopLeft {
+ animation-name: fadeInTopLeft;
+}
+@keyframes fadeInTopRight {
+ 0% {
+ opacity: 0;
+ transform: translate3d(100%, -100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInTopRight {
+ animation-name: fadeInTopRight;
+}
+@keyframes fadeInBottomLeft {
+ 0% {
+ opacity: 0;
+ transform: translate3d(-100%, 100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInBottomLeft {
+ animation-name: fadeInBottomLeft;
+}
+@keyframes fadeInBottomRight {
+ 0% {
+ opacity: 0;
+ transform: translate3d(100%, 100%, 0);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__fadeInBottomRight {
+ animation-name: fadeInBottomRight;
+}
+@keyframes fadeOut {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ }
+}
+.animate__fadeOut {
+ animation-name: fadeOut;
+}
+@keyframes fadeOutDown {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, 100%, 0);
+ }
+}
+.animate__fadeOutDown {
+ animation-name: fadeOutDown;
+}
+@keyframes fadeOutDownBig {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, 2000px, 0);
+ }
+}
+.animate__fadeOutDownBig {
+ animation-name: fadeOutDownBig;
+}
+@keyframes fadeOutLeft {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(-100%, 0, 0);
+ }
+}
+.animate__fadeOutLeft {
+ animation-name: fadeOutLeft;
+}
+@keyframes fadeOutLeftBig {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(-2000px, 0, 0);
+ }
+}
+.animate__fadeOutLeftBig {
+ animation-name: fadeOutLeftBig;
+}
+@keyframes fadeOutRight {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(100%, 0, 0);
+ }
+}
+.animate__fadeOutRight {
+ animation-name: fadeOutRight;
+}
+@keyframes fadeOutRightBig {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(2000px, 0, 0);
+ }
+}
+.animate__fadeOutRightBig {
+ animation-name: fadeOutRightBig;
+}
+@keyframes fadeOutUp {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, -100%, 0);
+ }
+}
+.animate__fadeOutUp {
+ animation-name: fadeOutUp;
+}
+@keyframes fadeOutUpBig {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(0, -2000px, 0);
+ }
+}
+.animate__fadeOutUpBig {
+ animation-name: fadeOutUpBig;
+}
+@keyframes fadeOutTopLeft {
+ 0% {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(-100%, -100%, 0);
+ }
+}
+.animate__fadeOutTopLeft {
+ animation-name: fadeOutTopLeft;
+}
+@keyframes fadeOutTopRight {
+ 0% {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(100%, -100%, 0);
+ }
+}
+.animate__fadeOutTopRight {
+ animation-name: fadeOutTopRight;
+}
+@keyframes fadeOutBottomRight {
+ 0% {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(100%, 100%, 0);
+ }
+}
+.animate__fadeOutBottomRight {
+ animation-name: fadeOutBottomRight;
+}
+@keyframes fadeOutBottomLeft {
+ 0% {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(-100%, 100%, 0);
+ }
+}
+.animate__fadeOutBottomLeft {
+ animation-name: fadeOutBottomLeft;
+}
+@keyframes flip {
+ 0% {
+ transform: perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);
+ animation-timing-function: ease-out;
+ }
+ 40% {
+ transform: perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);
+ animation-timing-function: ease-out;
+ }
+ 50% {
+ transform: perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);
+ animation-timing-function: ease-in;
+ }
+ 80% {
+ transform: perspective(400px) scale3d(0.95, 0.95, 0.95) translateZ(0) rotateY(0deg);
+ animation-timing-function: ease-in;
+ }
+ to {
+ transform: perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);
+ animation-timing-function: ease-in;
+ }
+}
+.animate__animated.animate__flip {
+ backface-visibility: visible;
+ animation-name: flip;
+}
+@keyframes flipInX {
+ 0% {
+ transform: perspective(400px) rotateX(90deg);
+ animation-timing-function: ease-in;
+ opacity: 0;
+ }
+ 40% {
+ transform: perspective(400px) rotateX(-20deg);
+ animation-timing-function: ease-in;
+ }
+ 60% {
+ transform: perspective(400px) rotateX(10deg);
+ opacity: 1;
+ }
+ 80% {
+ transform: perspective(400px) rotateX(-5deg);
+ }
+ to {
+ transform: perspective(400px);
+ }
+}
+.animate__flipInX {
+ backface-visibility: visible !important;
+ animation-name: flipInX;
+}
+@keyframes flipInY {
+ 0% {
+ transform: perspective(400px) rotateY(90deg);
+ animation-timing-function: ease-in;
+ opacity: 0;
+ }
+ 40% {
+ transform: perspective(400px) rotateY(-20deg);
+ animation-timing-function: ease-in;
+ }
+ 60% {
+ transform: perspective(400px) rotateY(10deg);
+ opacity: 1;
+ }
+ 80% {
+ transform: perspective(400px) rotateY(-5deg);
+ }
+ to {
+ transform: perspective(400px);
+ }
+}
+.animate__flipInY {
+ backface-visibility: visible !important;
+ animation-name: flipInY;
+}
+@keyframes flipOutX {
+ 0% {
+ transform: perspective(400px);
+ }
+ 30% {
+ transform: perspective(400px) rotateX(-20deg);
+ opacity: 1;
+ }
+ to {
+ transform: perspective(400px) rotateX(90deg);
+ opacity: 0;
+ }
+}
+.animate__flipOutX {
+ animation-duration: 0.75s;
+ animation-duration: calc(var(--animate-duration) * 0.75);
+ animation-name: flipOutX;
+ backface-visibility: visible !important;
+}
+@keyframes flipOutY {
+ 0% {
+ transform: perspective(400px);
+ }
+ 30% {
+ transform: perspective(400px) rotateY(-15deg);
+ opacity: 1;
+ }
+ to {
+ transform: perspective(400px) rotateY(90deg);
+ opacity: 0;
+ }
+}
+.animate__flipOutY {
+ animation-duration: 0.75s;
+ animation-duration: calc(var(--animate-duration) * 0.75);
+ backface-visibility: visible !important;
+ animation-name: flipOutY;
+}
+@keyframes lightSpeedInRight {
+ 0% {
+ transform: translate3d(100%, 0, 0) skewX(-30deg);
+ opacity: 0;
+ }
+ 60% {
+ transform: skewX(20deg);
+ opacity: 1;
+ }
+ 80% {
+ transform: skewX(-5deg);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__lightSpeedInRight {
+ animation-name: lightSpeedInRight;
+ animation-timing-function: ease-out;
+}
+@keyframes lightSpeedInLeft {
+ 0% {
+ transform: translate3d(-100%, 0, 0) skewX(30deg);
+ opacity: 0;
+ }
+ 60% {
+ transform: skewX(-20deg);
+ opacity: 1;
+ }
+ 80% {
+ transform: skewX(5deg);
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__lightSpeedInLeft {
+ animation-name: lightSpeedInLeft;
+ animation-timing-function: ease-out;
+}
+@keyframes lightSpeedOutRight {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: translate3d(100%, 0, 0) skewX(30deg);
+ opacity: 0;
+ }
+}
+.animate__lightSpeedOutRight {
+ animation-name: lightSpeedOutRight;
+ animation-timing-function: ease-in;
+}
+@keyframes lightSpeedOutLeft {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: translate3d(-100%, 0, 0) skewX(-30deg);
+ opacity: 0;
+ }
+}
+.animate__lightSpeedOutLeft {
+ animation-name: lightSpeedOutLeft;
+ animation-timing-function: ease-in;
+}
+@keyframes rotateIn {
+ 0% {
+ transform: rotate(-200deg);
+ opacity: 0;
+ }
+ to {
+ transform: translateZ(0);
+ opacity: 1;
+ }
+}
+.animate__rotateIn {
+ animation-name: rotateIn;
+ transform-origin: center;
+}
+@keyframes rotateInDownLeft {
+ 0% {
+ transform: rotate(-45deg);
+ opacity: 0;
+ }
+ to {
+ transform: translateZ(0);
+ opacity: 1;
+ }
+}
+.animate__rotateInDownLeft {
+ animation-name: rotateInDownLeft;
+ transform-origin: left bottom;
+}
+@keyframes rotateInDownRight {
+ 0% {
+ transform: rotate(45deg);
+ opacity: 0;
+ }
+ to {
+ transform: translateZ(0);
+ opacity: 1;
+ }
+}
+.animate__rotateInDownRight {
+ animation-name: rotateInDownRight;
+ transform-origin: right bottom;
+}
+@keyframes rotateInUpLeft {
+ 0% {
+ transform: rotate(45deg);
+ opacity: 0;
+ }
+ to {
+ transform: translateZ(0);
+ opacity: 1;
+ }
+}
+.animate__rotateInUpLeft {
+ animation-name: rotateInUpLeft;
+ transform-origin: left bottom;
+}
+@keyframes rotateInUpRight {
+ 0% {
+ transform: rotate(-90deg);
+ opacity: 0;
+ }
+ to {
+ transform: translateZ(0);
+ opacity: 1;
+ }
+}
+.animate__rotateInUpRight {
+ animation-name: rotateInUpRight;
+ transform-origin: right bottom;
+}
+@keyframes rotateOut {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: rotate(200deg);
+ opacity: 0;
+ }
+}
+.animate__rotateOut {
+ animation-name: rotateOut;
+ transform-origin: center;
+}
+@keyframes rotateOutDownLeft {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: rotate(45deg);
+ opacity: 0;
+ }
+}
+.animate__rotateOutDownLeft {
+ animation-name: rotateOutDownLeft;
+ transform-origin: left bottom;
+}
+@keyframes rotateOutDownRight {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: rotate(-45deg);
+ opacity: 0;
+ }
+}
+.animate__rotateOutDownRight {
+ animation-name: rotateOutDownRight;
+ transform-origin: right bottom;
+}
+@keyframes rotateOutUpLeft {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: rotate(-45deg);
+ opacity: 0;
+ }
+}
+.animate__rotateOutUpLeft {
+ animation-name: rotateOutUpLeft;
+ transform-origin: left bottom;
+}
+@keyframes rotateOutUpRight {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ transform: rotate(90deg);
+ opacity: 0;
+ }
+}
+.animate__rotateOutUpRight {
+ animation-name: rotateOutUpRight;
+ transform-origin: right bottom;
+}
+@keyframes hinge {
+ 0% {
+ animation-timing-function: ease-in-out;
+ }
+ 20%,
+ 60% {
+ transform: rotate(80deg);
+ animation-timing-function: ease-in-out;
+ }
+ 40%,
+ 80% {
+ transform: rotate(60deg);
+ animation-timing-function: ease-in-out;
+ opacity: 1;
+ }
+ to {
+ transform: translate3d(0, 700px, 0);
+ opacity: 0;
+ }
+}
+.animate__hinge {
+ animation-duration: 2s;
+ animation-duration: calc(var(--animate-duration) * 2);
+ animation-name: hinge;
+ transform-origin: top left;
+}
+@keyframes jackInTheBox {
+ 0% {
+ opacity: 0;
+ transform: scale(0.1) rotate(30deg);
+ transform-origin: center bottom;
+ }
+ 50% {
+ transform: rotate(-10deg);
+ }
+ 70% {
+ transform: rotate(3deg);
+ }
+ to {
+ opacity: 1;
+ transform: scale(1);
+ }
+}
+.animate__jackInTheBox {
+ animation-name: jackInTheBox;
+}
+@keyframes rollIn {
+ 0% {
+ opacity: 0;
+ transform: translate3d(-100%, 0, 0) rotate(-120deg);
+ }
+ to {
+ opacity: 1;
+ transform: translateZ(0);
+ }
+}
+.animate__rollIn {
+ animation-name: rollIn;
+}
+@keyframes rollOut {
+ 0% {
+ opacity: 1;
+ }
+ to {
+ opacity: 0;
+ transform: translate3d(100%, 0, 0) rotate(120deg);
+ }
+}
+.animate__rollOut {
+ animation-name: rollOut;
+}
+@keyframes zoomIn {
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.3, 0.3, 0.3);
+ }
+ 50% {
+ opacity: 1;
+ }
+}
+.animate__zoomIn {
+ animation-name: zoomIn;
+}
+@keyframes zoomInDown {
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -1000px, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ 60% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomInDown {
+ animation-name: zoomInDown;
+}
+@keyframes zoomInLeft {
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(-1000px, 0, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ 60% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(10px, 0, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomInLeft {
+ animation-name: zoomInLeft;
+}
+@keyframes zoomInRight {
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(1000px, 0, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ 60% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(-10px, 0, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomInRight {
+ animation-name: zoomInRight;
+}
+@keyframes zoomInUp {
+ 0% {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 1000px, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ 60% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomInUp {
+ animation-name: zoomInUp;
+}
+@keyframes zoomOut {
+ 0% {
+ opacity: 1;
+ }
+ 50% {
+ opacity: 0;
+ transform: scale3d(0.3, 0.3, 0.3);
+ }
+ to {
+ opacity: 0;
+ }
+}
+.animate__zoomOut {
+ animation-name: zoomOut;
+}
+@keyframes zoomOutDown {
+ 40% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(0, -60px, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ to {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(0, 2000px, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomOutDown {
+ animation-name: zoomOutDown;
+ transform-origin: center bottom;
+}
+@keyframes zoomOutLeft {
+ 40% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(42px, 0, 0);
+ }
+ to {
+ opacity: 0;
+ transform: scale(0.1) translate3d(-2000px, 0, 0);
+ }
+}
+.animate__zoomOutLeft {
+ animation-name: zoomOutLeft;
+ transform-origin: left center;
+}
+@keyframes zoomOutRight {
+ 40% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(-42px, 0, 0);
+ }
+ to {
+ opacity: 0;
+ transform: scale(0.1) translate3d(2000px, 0, 0);
+ }
+}
+.animate__zoomOutRight {
+ animation-name: zoomOutRight;
+ transform-origin: right center;
+}
+@keyframes zoomOutUp {
+ 40% {
+ opacity: 1;
+ transform: scale3d(0.475, 0.475, 0.475) translate3d(0, 60px, 0);
+ animation-timing-function: cubic-bezier(0.55, 0.055, 0.675, 0.19);
+ }
+ to {
+ opacity: 0;
+ transform: scale3d(0.1, 0.1, 0.1) translate3d(0, -2000px, 0);
+ animation-timing-function: cubic-bezier(0.175, 0.885, 0.32, 1);
+ }
+}
+.animate__zoomOutUp {
+ animation-name: zoomOutUp;
+ transform-origin: center bottom;
+}
+@keyframes slideInDown {
+ 0% {
+ transform: translate3d(0, -100%, 0);
+ visibility: visible;
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__slideInDown {
+ animation-name: slideInDown;
+}
+@keyframes slideInLeft {
+ 0% {
+ transform: translate3d(-100%, 0, 0);
+ visibility: visible;
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__slideInLeft {
+ animation-name: slideInLeft;
+}
+@keyframes slideInRight {
+ 0% {
+ transform: translate3d(100%, 0, 0);
+ visibility: visible;
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__slideInRight {
+ animation-name: slideInRight;
+}
+@keyframes slideInUp {
+ 0% {
+ transform: translate3d(0, 100%, 0);
+ visibility: visible;
+ }
+ to {
+ transform: translateZ(0);
+ }
+}
+.animate__slideInUp {
+ animation-name: slideInUp;
+}
+@keyframes slideOutDown {
+ 0% {
+ transform: translateZ(0);
+ }
+ to {
+ visibility: hidden;
+ transform: translate3d(0, 100%, 0);
+ }
+}
+.animate__slideOutDown {
+ animation-name: slideOutDown;
+}
+@keyframes slideOutLeft {
+ 0% {
+ transform: translateZ(0);
+ }
+ to {
+ visibility: hidden;
+ transform: translate3d(-100%, 0, 0);
+ }
+}
+.animate__slideOutLeft {
+ animation-name: slideOutLeft;
+}
+@keyframes slideOutRight {
+ 0% {
+ transform: translateZ(0);
+ }
+ to {
+ visibility: hidden;
+ transform: translate3d(100%, 0, 0);
+ }
+}
+.animate__slideOutRight {
+ animation-name: slideOutRight;
+}
+@keyframes slideOutUp {
+ 0% {
+ transform: translateZ(0);
+ }
+ to {
+ visibility: hidden;
+ transform: translate3d(0, -100%, 0);
+ }
+}
+.animate__slideOutUp {
+ animation-name: slideOutUp;
+}
+body {
+ /* background-color: #000; */
+}
+
+.n-popover:has(.music-play) {
+ border-radius: 1.5rem !important;
+}
+@font-face {
+ font-family: "v-sans";
+ font-weight: 400;
+ src: url("./LatoLatin-Regular-Dmlz1U0B.woff2");
+}
+
+@font-face {
+ font-family: "v-sans";
+ font-weight: 600;
+ src: url("./LatoLatin-Semibold-Dbk81p2D.woff2");
+}@font-face {
+ font-family: "v-mono";
+ font-weight: 400;
+ src: url("./FiraCode-Regular-CRwVj4V2.woff2");
+}/* ./src/index.css */
+
+/*! @import */
+
+*, ::before, ::after {
+ --tw-border-spacing-x: 0;
+ --tw-border-spacing-y: 0;
+ --tw-translate-x: 0;
+ --tw-translate-y: 0;
+ --tw-rotate: 0;
+ --tw-skew-x: 0;
+ --tw-skew-y: 0;
+ --tw-scale-x: 1;
+ --tw-scale-y: 1;
+ --tw-pan-x: ;
+ --tw-pan-y: ;
+ --tw-pinch-zoom: ;
+ --tw-scroll-snap-strictness: proximity;
+ --tw-gradient-from-position: ;
+ --tw-gradient-via-position: ;
+ --tw-gradient-to-position: ;
+ --tw-ordinal: ;
+ --tw-slashed-zero: ;
+ --tw-numeric-figure: ;
+ --tw-numeric-spacing: ;
+ --tw-numeric-fraction: ;
+ --tw-ring-inset: ;
+ --tw-ring-offset-width: 0px;
+ --tw-ring-offset-color: #fff;
+ --tw-ring-color: rgb(59 130 246 / 0.5);
+ --tw-ring-offset-shadow: 0 0 #0000;
+ --tw-ring-shadow: 0 0 #0000;
+ --tw-shadow: 0 0 #0000;
+ --tw-shadow-colored: 0 0 #0000;
+ --tw-blur: ;
+ --tw-brightness: ;
+ --tw-contrast: ;
+ --tw-grayscale: ;
+ --tw-hue-rotate: ;
+ --tw-invert: ;
+ --tw-saturate: ;
+ --tw-sepia: ;
+ --tw-drop-shadow: ;
+ --tw-backdrop-blur: ;
+ --tw-backdrop-brightness: ;
+ --tw-backdrop-contrast: ;
+ --tw-backdrop-grayscale: ;
+ --tw-backdrop-hue-rotate: ;
+ --tw-backdrop-invert: ;
+ --tw-backdrop-opacity: ;
+ --tw-backdrop-saturate: ;
+ --tw-backdrop-sepia: ;
+ --tw-contain-size: ;
+ --tw-contain-layout: ;
+ --tw-contain-paint: ;
+ --tw-contain-style: ;
+}
+
+::backdrop {
+ --tw-border-spacing-x: 0;
+ --tw-border-spacing-y: 0;
+ --tw-translate-x: 0;
+ --tw-translate-y: 0;
+ --tw-rotate: 0;
+ --tw-skew-x: 0;
+ --tw-skew-y: 0;
+ --tw-scale-x: 1;
+ --tw-scale-y: 1;
+ --tw-pan-x: ;
+ --tw-pan-y: ;
+ --tw-pinch-zoom: ;
+ --tw-scroll-snap-strictness: proximity;
+ --tw-gradient-from-position: ;
+ --tw-gradient-via-position: ;
+ --tw-gradient-to-position: ;
+ --tw-ordinal: ;
+ --tw-slashed-zero: ;
+ --tw-numeric-figure: ;
+ --tw-numeric-spacing: ;
+ --tw-numeric-fraction: ;
+ --tw-ring-inset: ;
+ --tw-ring-offset-width: 0px;
+ --tw-ring-offset-color: #fff;
+ --tw-ring-color: rgb(59 130 246 / 0.5);
+ --tw-ring-offset-shadow: 0 0 #0000;
+ --tw-ring-shadow: 0 0 #0000;
+ --tw-shadow: 0 0 #0000;
+ --tw-shadow-colored: 0 0 #0000;
+ --tw-blur: ;
+ --tw-brightness: ;
+ --tw-contrast: ;
+ --tw-grayscale: ;
+ --tw-hue-rotate: ;
+ --tw-invert: ;
+ --tw-saturate: ;
+ --tw-sepia: ;
+ --tw-drop-shadow: ;
+ --tw-backdrop-blur: ;
+ --tw-backdrop-brightness: ;
+ --tw-backdrop-contrast: ;
+ --tw-backdrop-grayscale: ;
+ --tw-backdrop-hue-rotate: ;
+ --tw-backdrop-invert: ;
+ --tw-backdrop-opacity: ;
+ --tw-backdrop-saturate: ;
+ --tw-backdrop-sepia: ;
+ --tw-contain-size: ;
+ --tw-contain-layout: ;
+ --tw-contain-paint: ;
+ --tw-contain-style: ;
+}
+
+/* ! tailwindcss v3.4.17 | MIT License | https://tailwindcss.com */
+
+/*
+1. Prevent padding and border from affecting element width. (https://github.com/mozdevs/cssremedy/issues/4)
+2. Allow adding a border to an element by just adding a border-width. (https://github.com/tailwindcss/tailwindcss/pull/116)
+*/
+
+*,
+::before,
+::after {
+ box-sizing: border-box; /* 1 */
+ border-width: 0; /* 2 */
+ border-style: solid; /* 2 */
+ border-color: #e5e7eb; /* 2 */
+}
+
+::before,
+::after {
+ --tw-content: '';
+}
+
+/*
+1. Use a consistent sensible line-height in all browsers.
+2. Prevent adjustments of font size after orientation changes in iOS.
+3. Use a more readable tab size.
+4. Use the user's configured `sans` font-family by default.
+5. Use the user's configured `sans` font-feature-settings by default.
+6. Use the user's configured `sans` font-variation-settings by default.
+7. Disable tap highlights on iOS
+*/
+
+html,
+:host {
+ line-height: 1.5; /* 1 */
+ -webkit-text-size-adjust: 100%; /* 2 */
+ -moz-tab-size: 4; /* 3 */
+ -o-tab-size: 4;
+ tab-size: 4; /* 3 */
+ font-family: ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 4 */
+ font-feature-settings: normal; /* 5 */
+ font-variation-settings: normal; /* 6 */
+ -webkit-tap-highlight-color: transparent; /* 7 */
+}
+
+/*
+1. Remove the margin in all browsers.
+2. Inherit line-height from `html` so users can set them as a class directly on the `html` element.
+*/
+
+body {
+ margin: 0; /* 1 */
+ line-height: inherit; /* 2 */
+}
+
+/*
+1. Add the correct height in Firefox.
+2. Correct the inheritance of border color in Firefox. (https://bugzilla.mozilla.org/show_bug.cgi?id=190655)
+3. Ensure horizontal rules are visible by default.
+*/
+
+hr {
+ height: 0; /* 1 */
+ color: inherit; /* 2 */
+ border-top-width: 1px; /* 3 */
+}
+
+/*
+Add the correct text decoration in Chrome, Edge, and Safari.
+*/
+
+abbr:where([title]) {
+ -webkit-text-decoration: underline dotted;
+ text-decoration: underline dotted;
+}
+
+/*
+Remove the default font size and weight for headings.
+*/
+
+h1,
+h2,
+h3,
+h4,
+h5,
+h6 {
+ font-size: inherit;
+ font-weight: inherit;
+}
+
+/*
+Reset links to optimize for opt-in styling instead of opt-out.
+*/
+
+a {
+ color: inherit;
+ text-decoration: inherit;
+}
+
+/*
+Add the correct font weight in Edge and Safari.
+*/
+
+b,
+strong {
+ font-weight: bolder;
+}
+
+/*
+1. Use the user's configured `mono` font-family by default.
+2. Use the user's configured `mono` font-feature-settings by default.
+3. Use the user's configured `mono` font-variation-settings by default.
+4. Correct the odd `em` font sizing in all browsers.
+*/
+
+code,
+kbd,
+samp,
+pre {
+ font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; /* 1 */
+ font-feature-settings: normal; /* 2 */
+ font-variation-settings: normal; /* 3 */
+ font-size: 1em; /* 4 */
+}
+
+/*
+Add the correct font size in all browsers.
+*/
+
+small {
+ font-size: 80%;
+}
+
+/*
+Prevent `sub` and `sup` elements from affecting the line height in all browsers.
+*/
+
+sub,
+sup {
+ font-size: 75%;
+ line-height: 0;
+ position: relative;
+ vertical-align: baseline;
+}
+
+sub {
+ bottom: -0.25em;
+}
+
+sup {
+ top: -0.5em;
+}
+
+/*
+1. Remove text indentation from table contents in Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=999088, https://bugs.webkit.org/show_bug.cgi?id=201297)
+2. Correct table border color inheritance in all Chrome and Safari. (https://bugs.chromium.org/p/chromium/issues/detail?id=935729, https://bugs.webkit.org/show_bug.cgi?id=195016)
+3. Remove gaps between table borders by default.
+*/
+
+table {
+ text-indent: 0; /* 1 */
+ border-color: inherit; /* 2 */
+ border-collapse: collapse; /* 3 */
+}
+
+/*
+1. Change the font styles in all browsers.
+2. Remove the margin in Firefox and Safari.
+3. Remove default padding in all browsers.
+*/
+
+button,
+input,
+optgroup,
+select,
+textarea {
+ font-family: inherit; /* 1 */
+ font-feature-settings: inherit; /* 1 */
+ font-variation-settings: inherit; /* 1 */
+ font-size: 100%; /* 1 */
+ font-weight: inherit; /* 1 */
+ line-height: inherit; /* 1 */
+ letter-spacing: inherit; /* 1 */
+ color: inherit; /* 1 */
+ margin: 0; /* 2 */
+ padding: 0; /* 3 */
+}
+
+/*
+Remove the inheritance of text transform in Edge and Firefox.
+*/
+
+button,
+select {
+ text-transform: none;
+}
+
+/*
+1. Correct the inability to style clickable types in iOS and Safari.
+2. Remove default button styles.
+*/
+
+button,
+input:where([type='button']),
+input:where([type='reset']),
+input:where([type='submit']) {
+ -webkit-appearance: button; /* 1 */
+ background-color: transparent; /* 2 */
+ background-image: none; /* 2 */
+}
+
+/*
+Use the modern Firefox focus style for all focusable elements.
+*/
+
+:-moz-focusring {
+ outline: auto;
+}
+
+/*
+Remove the additional `:invalid` styles in Firefox. (https://github.com/mozilla/gecko-dev/blob/2f9eacd9d3d995c937b4251a5557d95d494c9be1/layout/style/res/forms.css#L728-L737)
+*/
+
+:-moz-ui-invalid {
+ box-shadow: none;
+}
+
+/*
+Add the correct vertical alignment in Chrome and Firefox.
+*/
+
+progress {
+ vertical-align: baseline;
+}
+
+/*
+Correct the cursor style of increment and decrement buttons in Safari.
+*/
+
+::-webkit-inner-spin-button,
+::-webkit-outer-spin-button {
+ height: auto;
+}
+
+/*
+1. Correct the odd appearance in Chrome and Safari.
+2. Correct the outline style in Safari.
+*/
+
+[type='search'] {
+ -webkit-appearance: textfield; /* 1 */
+ outline-offset: -2px; /* 2 */
+}
+
+/*
+Remove the inner padding in Chrome and Safari on macOS.
+*/
+
+::-webkit-search-decoration {
+ -webkit-appearance: none;
+}
+
+/*
+1. Correct the inability to style clickable types in iOS and Safari.
+2. Change font properties to `inherit` in Safari.
+*/
+
+::-webkit-file-upload-button {
+ -webkit-appearance: button; /* 1 */
+ font: inherit; /* 2 */
+}
+
+/*
+Add the correct display in Chrome and Safari.
+*/
+
+summary {
+ display: list-item;
+}
+
+/*
+Removes the default spacing and border for appropriate elements.
+*/
+
+blockquote,
+dl,
+dd,
+h1,
+h2,
+h3,
+h4,
+h5,
+h6,
+hr,
+figure,
+p,
+pre {
+ margin: 0;
+}
+
+fieldset {
+ margin: 0;
+ padding: 0;
+}
+
+legend {
+ padding: 0;
+}
+
+ol,
+ul,
+menu {
+ list-style: none;
+ margin: 0;
+ padding: 0;
+}
+
+/*
+Reset default styling for dialogs.
+*/
+
+dialog {
+ padding: 0;
+}
+
+/*
+Prevent resizing textareas horizontally by default.
+*/
+
+textarea {
+ resize: vertical;
+}
+
+/*
+1. Reset the default placeholder opacity in Firefox. (https://github.com/tailwindlabs/tailwindcss/issues/3300)
+2. Set the default placeholder color to the user's configured gray 400 color.
+*/
+
+input::-moz-placeholder, textarea::-moz-placeholder {
+ opacity: 1; /* 1 */
+ color: #9ca3af; /* 2 */
+}
+
+input::placeholder,
+textarea::placeholder {
+ opacity: 1; /* 1 */
+ color: #9ca3af; /* 2 */
+}
+
+/*
+Set the default cursor for buttons.
+*/
+
+button,
+[role="button"] {
+ cursor: pointer;
+}
+
+/*
+Make sure disabled buttons don't get the pointer cursor.
+*/
+
+:disabled {
+ cursor: default;
+}
+
+/*
+1. Make replaced elements `display: block` by default. (https://github.com/mozdevs/cssremedy/issues/14)
+2. Add `vertical-align: middle` to align replaced elements more sensibly by default. (https://github.com/jensimmons/cssremedy/issues/14#issuecomment-634934210)
+ This can trigger a poorly considered lint error in some tools but is included by design.
+*/
+
+img,
+svg,
+video,
+canvas,
+audio,
+iframe,
+embed,
+object {
+ display: block; /* 1 */
+ vertical-align: middle; /* 2 */
+}
+
+/*
+Constrain images and videos to the parent width and preserve their intrinsic aspect ratio. (https://github.com/mozdevs/cssremedy/issues/14)
+*/
+
+img,
+video {
+ max-width: 100%;
+ height: auto;
+}
+
+/* Make elements with the HTML hidden attribute stay hidden by default */
+
+[hidden]:where(:not([hidden="until-found"])) {
+ display: none;
+}
+
+.container {
+ width: 100%;
+}
+
+@media (min-width: 640px) {
+
+ .container {
+ max-width: 640px;
+ }
+}
+
+@media (min-width: 768px) {
+
+ .container {
+ max-width: 768px;
+ }
+}
+
+@media (min-width: 1024px) {
+
+ .container {
+ max-width: 1024px;
+ }
+}
+
+@media (min-width: 1280px) {
+
+ .container {
+ max-width: 1280px;
+ }
+}
+
+@media (min-width: 1536px) {
+
+ .container {
+ max-width: 1536px;
+ }
+}
+
+.visible {
+ visibility: visible;
+}
+
+.invisible {
+ visibility: hidden;
+}
+
+.fixed {
+ position: fixed;
+}
+
+.absolute {
+ position: absolute;
+}
+
+.relative {
+ position: relative;
+}
+
+.inset-0 {
+ inset: 0px;
+}
+
+.bottom-0 {
+ bottom: 0px;
+}
+
+.bottom-\[30px\] {
+ bottom: 30px;
+}
+
+.left-0 {
+ left: 0px;
+}
+
+.left-1\/2 {
+ left: 50%;
+}
+
+.left-2 {
+ left: 0.5rem;
+}
+
+.right-0 {
+ right: 0px;
+}
+
+.right-2 {
+ right: 0.5rem;
+}
+
+.right-4 {
+ right: 1rem;
+}
+
+.top-0 {
+ top: 0px;
+}
+
+.top-1\/2 {
+ top: 50%;
+}
+
+.top-2 {
+ top: 0.5rem;
+}
+
+.top-4 {
+ top: 1rem;
+}
+
+.z-10 {
+ z-index: 10;
+}
+
+.mx-0 {
+ margin-left: 0px;
+ margin-right: 0px;
+}
+
+.mx-2 {
+ margin-left: 0.5rem;
+ margin-right: 0.5rem;
+}
+
+.mx-4 {
+ margin-left: 1rem;
+ margin-right: 1rem;
+}
+
+.mx-6 {
+ margin-left: 1.5rem;
+ margin-right: 1.5rem;
+}
+
+.my-2 {
+ margin-top: 0.5rem;
+ margin-bottom: 0.5rem;
+}
+
+.my-4 {
+ margin-top: 1rem;
+ margin-bottom: 1rem;
+}
+
+.mb-0 {
+ margin-bottom: 0px;
+}
+
+.mb-2 {
+ margin-bottom: 0.5rem;
+}
+
+.mb-3 {
+ margin-bottom: 0.75rem;
+}
+
+.mb-4 {
+ margin-bottom: 1rem;
+}
+
+.mb-6 {
+ margin-bottom: 1.5rem;
+}
+
+.ml-1 {
+ margin-left: 0.25rem;
+}
+
+.ml-2 {
+ margin-left: 0.5rem;
+}
+
+.ml-3 {
+ margin-left: 0.75rem;
+}
+
+.ml-4 {
+ margin-left: 1rem;
+}
+
+.ml-auto {
+ margin-left: auto;
+}
+
+.mr-0 {
+ margin-right: 0px;
+}
+
+.mr-1 {
+ margin-right: 0.25rem;
+}
+
+.mr-16 {
+ margin-right: 4rem;
+}
+
+.mr-2 {
+ margin-right: 0.5rem;
+}
+
+.mr-3 {
+ margin-right: 0.75rem;
+}
+
+.mr-4 {
+ margin-right: 1rem;
+}
+
+.mr-5 {
+ margin-right: 1.25rem;
+}
+
+.mr-6 {
+ margin-right: 1.5rem;
+}
+
+.mt-1 {
+ margin-top: 0.25rem;
+}
+
+.mt-10 {
+ margin-top: 2.5rem;
+}
+
+.mt-2 {
+ margin-top: 0.5rem;
+}
+
+.mt-4 {
+ margin-top: 1rem;
+}
+
+.mt-40 {
+ margin-top: 10rem;
+}
+
+.mt-6 {
+ margin-top: 1.5rem;
+}
+
+.box-border {
+ box-sizing: border-box;
+}
+
+.block {
+ display: block;
+}
+
+.inline-block {
+ display: inline-block;
+}
+
+.flex {
+ display: flex;
+}
+
+.inline-flex {
+ display: inline-flex;
+}
+
+.table {
+ display: table;
+}
+
+.grid {
+ display: grid;
+}
+
+.hidden {
+ display: none;
+}
+
+.aspect-square {
+ aspect-ratio: 1 / 1;
+}
+
+.h-1 {
+ height: 0.25rem;
+}
+
+.h-10 {
+ height: 2.5rem;
+}
+
+.h-12 {
+ height: 3rem;
+}
+
+.h-14 {
+ height: 3.5rem;
+}
+
+.h-20 {
+ height: 5rem;
+}
+
+.h-24 {
+ height: 6rem;
+}
+
+.h-32 {
+ height: 8rem;
+}
+
+.h-7 {
+ height: 1.75rem;
+}
+
+.h-8 {
+ height: 2rem;
+}
+
+.h-9 {
+ height: 2.25rem;
+}
+
+.h-\[100px\] {
+ height: 100px;
+}
+
+.h-\[180px\] {
+ height: 180px;
+}
+
+.h-\[300px\] {
+ height: 300px;
+}
+
+.h-\[calc\(100\%-60px\)\] {
+ height: calc(100% - 60px);
+}
+
+.h-full {
+ height: 100%;
+}
+
+.h-screen {
+ height: 100vh;
+}
+
+.min-h-0 {
+ min-height: 0px;
+}
+
+.min-h-\[250px\] {
+ min-height: 250px;
+}
+
+.min-h-\[calc\(80vh-60px\)\] {
+ min-height: calc(80vh - 60px);
+}
+
+.w-10 {
+ width: 2.5rem;
+}
+
+.w-12 {
+ width: 3rem;
+}
+
+.w-14 {
+ width: 3.5rem;
+}
+
+.w-2\/5 {
+ width: 40%;
+}
+
+.w-20 {
+ width: 5rem;
+}
+
+.w-24 {
+ width: 6rem;
+}
+
+.w-32 {
+ width: 8rem;
+}
+
+.w-40 {
+ width: 10rem;
+}
+
+.w-7 {
+ width: 1.75rem;
+}
+
+.w-8 {
+ width: 2rem;
+}
+
+.w-9 {
+ width: 2.25rem;
+}
+
+.w-\[100px\] {
+ width: 100px;
+}
+
+.w-\[160px\] {
+ width: 160px;
+}
+
+.w-\[200px\] {
+ width: 200px;
+}
+
+.w-\[25\%\] {
+ width: 25%;
+}
+
+.w-full {
+ width: 100%;
+}
+
+.w-screen {
+ width: 100vw;
+}
+
+.min-w-0 {
+ min-width: 0px;
+}
+
+.min-w-\[280px\] {
+ min-width: 280px;
+}
+
+.min-w-\[60px\] {
+ min-width: 60px;
+}
+
+.max-w-\[45\%\] {
+ max-width: 45%;
+}
+
+.flex-1 {
+ flex: 1 1 0%;
+}
+
+.flex-shrink-0 {
+ flex-shrink: 0;
+}
+
+.flex-grow {
+ flex-grow: 1;
+}
+
+.-translate-x-1\/2 {
+ --tw-translate-x: -50%;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.-translate-y-1\/2 {
+ --tw-translate-y: -50%;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.scale-105 {
+ --tw-scale-x: 1.05;
+ --tw-scale-y: 1.05;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.scale-150 {
+ --tw-scale-x: 1.5;
+ --tw-scale-y: 1.5;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.transform {
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.cursor-none {
+ cursor: none;
+}
+
+.cursor-pointer {
+ cursor: pointer;
+}
+
+.select-none {
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+}
+
+.resize {
+ resize: both;
+}
+
+.list-inside {
+ list-style-position: inside;
+}
+
+.list-decimal {
+ list-style-type: decimal;
+}
+
+.list-disc {
+ list-style-type: disc;
+}
+
+.grid-cols-2 {
+ grid-template-columns: repeat(2, minmax(0, 1fr));
+}
+
+.grid-rows-3 {
+ grid-template-rows: repeat(3, minmax(0, 1fr));
+}
+
+.flex-col {
+ flex-direction: column;
+}
+
+.items-center {
+ align-items: center;
+}
+
+.justify-center {
+ justify-content: center;
+}
+
+.justify-between {
+ justify-content: space-between;
+}
+
+.justify-around {
+ justify-content: space-around;
+}
+
+.gap-10 {
+ gap: 2.5rem;
+}
+
+.gap-2 {
+ gap: 0.5rem;
+}
+
+.gap-3 {
+ gap: 0.75rem;
+}
+
+.gap-4 {
+ gap: 1rem;
+}
+
+.gap-x-8 {
+ -moz-column-gap: 2rem;
+ column-gap: 2rem;
+}
+
+.gap-y-6 {
+ row-gap: 1.5rem;
+}
+
+.space-y-2 > :not([hidden]) ~ :not([hidden]) {
+ --tw-space-y-reverse: 0;
+ margin-top: calc(0.5rem * calc(1 - var(--tw-space-y-reverse)));
+ margin-bottom: calc(0.5rem * var(--tw-space-y-reverse));
+}
+
+.overflow-hidden {
+ overflow: hidden;
+}
+
+.overflow-x-auto {
+ overflow-x: auto;
+}
+
+.text-ellipsis {
+ text-overflow: ellipsis;
+}
+
+.rounded {
+ border-radius: 0.25rem;
+}
+
+.rounded-2xl {
+ border-radius: 1rem;
+}
+
+.rounded-3xl {
+ border-radius: 1.5rem;
+}
+
+.rounded-full {
+ border-radius: 9999px;
+}
+
+.rounded-lg {
+ border-radius: 0.5rem;
+}
+
+.rounded-xl {
+ border-radius: 0.75rem;
+}
+
+.rounded-b-none {
+ border-bottom-right-radius: 0px;
+ border-bottom-left-radius: 0px;
+}
+
+.border {
+ border-width: 1px;
+}
+
+.border-2 {
+ border-width: 2px;
+}
+
+.border-b {
+ border-bottom-width: 1px;
+}
+
+.border-l-4 {
+ border-left-width: 4px;
+}
+
+.border-t {
+ border-top-width: 1px;
+}
+
+.border-gray-100 {
+ --tw-border-opacity: 1;
+ border-color: rgb(243 244 246 / var(--tw-border-opacity, 1));
+}
+
+.border-gray-200 {
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}
+
+.border-gray-400 {
+ --tw-border-opacity: 1;
+ border-color: rgb(156 163 175 / var(--tw-border-opacity, 1));
+}
+
+.border-green-500 {
+ --tw-border-opacity: 1;
+ border-color: rgb(34 197 94 / var(--tw-border-opacity, 1));
+}
+
+.bg-black {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-100 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-300 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(209 213 219 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-50 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-500 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(107 114 128 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-800 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+
+.bg-gray-900 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(17 24 39 / var(--tw-bg-opacity, 1));
+}
+
+.bg-green-50 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(240 253 244 / var(--tw-bg-opacity, 1));
+}
+
+.bg-green-500 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1));
+}
+
+.bg-green-600 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1));
+}
+
+.bg-light {
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+
+.bg-light-100 {
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+}
+
+.bg-transparent {
+ background-color: transparent;
+}
+
+.bg-opacity-10 {
+ --tw-bg-opacity: 0.1;
+}
+
+.bg-opacity-20 {
+ --tw-bg-opacity: 0.2;
+}
+
+.bg-opacity-50 {
+ --tw-bg-opacity: 0.5;
+}
+
+.bg-opacity-60 {
+ --tw-bg-opacity: 0.6;
+}
+
+.bg-opacity-75 {
+ --tw-bg-opacity: 0.75;
+}
+
+.bg-opacity-90 {
+ --tw-bg-opacity: 0.9;
+}
+
+.bg-cover {
+ background-size: cover;
+}
+
+.bg-center {
+ background-position: center;
+}
+
+.bg-no-repeat {
+ background-repeat: no-repeat;
+}
+
+.object-contain {
+ -o-object-fit: contain;
+ object-fit: contain;
+}
+
+.object-cover {
+ -o-object-fit: cover;
+ object-fit: cover;
+}
+
+.p-0 {
+ padding: 0px;
+}
+
+.p-2 {
+ padding: 0.5rem;
+}
+
+.p-20 {
+ padding: 5rem;
+}
+
+.p-3 {
+ padding: 0.75rem;
+}
+
+.p-4 {
+ padding: 1rem;
+}
+
+.p-5 {
+ padding: 1.25rem;
+}
+
+.p-6 {
+ padding: 1.5rem;
+}
+
+.px-0 {
+ padding-left: 0px;
+ padding-right: 0px;
+}
+
+.px-1\.5 {
+ padding-left: 0.375rem;
+ padding-right: 0.375rem;
+}
+
+.px-2 {
+ padding-left: 0.5rem;
+ padding-right: 0.5rem;
+}
+
+.px-24 {
+ padding-left: 6rem;
+ padding-right: 6rem;
+}
+
+.px-3 {
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+}
+
+.px-4 {
+ padding-left: 1rem;
+ padding-right: 1rem;
+}
+
+.px-6 {
+ padding-left: 1.5rem;
+ padding-right: 1.5rem;
+}
+
+.px-8 {
+ padding-left: 2rem;
+ padding-right: 2rem;
+}
+
+.py-0\.5 {
+ padding-top: 0.125rem;
+ padding-bottom: 0.125rem;
+}
+
+.py-1 {
+ padding-top: 0.25rem;
+ padding-bottom: 0.25rem;
+}
+
+.py-2 {
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+}
+
+.py-3 {
+ padding-top: 0.75rem;
+ padding-bottom: 0.75rem;
+}
+
+.py-4 {
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+}
+
+.pb-1 {
+ padding-bottom: 0.25rem;
+}
+
+.pb-2 {
+ padding-bottom: 0.5rem;
+}
+
+.pb-20 {
+ padding-bottom: 5rem;
+}
+
+.pb-28 {
+ padding-bottom: 7rem;
+}
+
+.pb-4 {
+ padding-bottom: 1rem;
+}
+
+.pl-4 {
+ padding-left: 1rem;
+}
+
+.pr-0 {
+ padding-right: 0px;
+}
+
+.pr-3 {
+ padding-right: 0.75rem;
+}
+
+.pr-8 {
+ padding-right: 2rem;
+}
+
+.pt-2 {
+ padding-top: 0.5rem;
+}
+
+.pt-6 {
+ padding-top: 1.5rem;
+}
+
+.pt-8 {
+ padding-top: 2rem;
+}
+
+.text-center {
+ text-align: center;
+}
+
+.text-2xl {
+ font-size: 1.5rem;
+ line-height: 2rem;
+}
+
+.text-3xl {
+ font-size: 1.875rem;
+ line-height: 2.25rem;
+}
+
+.text-4xl {
+ font-size: 2.25rem;
+ line-height: 2.5rem;
+}
+
+.text-5xl {
+ font-size: 3rem;
+ line-height: 1;
+}
+
+.text-base {
+ font-size: 1rem;
+ line-height: 1.5rem;
+}
+
+.text-lg {
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+}
+
+.text-sm {
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+}
+
+.text-xl {
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+}
+
+.text-xs {
+ font-size: 0.75rem;
+ line-height: 1rem;
+}
+
+.font-bold {
+ font-weight: 700;
+}
+
+.font-medium {
+ font-weight: 500;
+}
+
+.leading-relaxed {
+ line-height: 1.625;
+}
+
+.text-dark {
+ --tw-text-opacity: 1;
+ color: rgb(0 0 0 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-100 {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-200 {
+ --tw-text-opacity: 1;
+ color: rgb(229 231 235 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-300 {
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-400 {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-500 {
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-600 {
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-700 {
+ --tw-text-opacity: 1;
+ color: rgb(55 65 81 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-800 {
+ --tw-text-opacity: 1;
+ color: rgb(31 41 55 / var(--tw-text-opacity, 1));
+}
+
+.text-gray-900 {
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+
+.text-green-500 {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+
+.text-red-500 {
+ --tw-text-opacity: 1;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1));
+}
+
+.text-white {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+
+.placeholder-gray-500::-moz-placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-placeholder-opacity, 1));
+}
+
+.placeholder-gray-500::placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-placeholder-opacity, 1));
+}
+
+.opacity-0 {
+ opacity: 0;
+}
+
+.opacity-100 {
+ opacity: 1;
+}
+
+.shadow-2xl {
+ --tw-shadow: 0 25px 50px -12px rgb(0 0 0 / 0.25);
+ --tw-shadow-colored: 0 25px 50px -12px var(--tw-shadow-color);
+ box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
+}
+
+.shadow-lg {
+ --tw-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
+ --tw-shadow-colored: 0 10px 15px -3px var(--tw-shadow-color), 0 4px 6px -4px var(--tw-shadow-color);
+ box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);
+}
+
+.blur {
+ --tw-blur: blur(8px);
+ filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
+}
+
+.filter {
+ filter: var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);
+}
+
+.backdrop-filter {
+ -webkit-backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);
+ backdrop-filter: var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);
+}
+
+.transition {
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+
+.transition-all {
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+
+.transition-colors {
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+
+.transition-opacity {
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+
+.duration-200 {
+ transition-duration: 200ms;
+}
+
+.duration-300 {
+ transition-duration: 300ms;
+}
+
+.duration-500 {
+ transition-duration: 500ms;
+}
+
+.ease-in-out {
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+}
+
+.n-image img {
+ background-color: #111111;
+ width: 100%;
+}
+
+.n-slider-handle-indicator--top {
+ margin-bottom: 0px !important;
+ background-color: transparent !important;
+ padding-left: 0.5rem !important;
+ padding-right: 0.5rem !important;
+ padding-top: 0.25rem !important;
+ padding-bottom: 0.25rem !important;
+ font-size: 1.5rem !important;
+ line-height: 2rem !important;
+ color: #000000dd !important;
+ --tw-shadow: 0 0 #0000 !important;
+ --tw-shadow-colored: 0 0 #0000 !important;
+ box-shadow: var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow) !important;
+}
+
+.n-slider-handle-indicator--top:is(.dark *) {
+ color: #ffffffdd !important;
+}
+
+.text-el {
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
+
+.theme-dark {
+ --bg-color: #000;
+ --text-color: #fff;
+ --bg-color-100: #161616;
+ --bg-color-200: #2d2d2d;
+ --bg-color-300: #3d3d3d;
+ --text-color: #f8f9fa;
+ --text-color-100: #e9ecef;
+ --text-color-200: #dee2e6;
+ --text-color-300: #dde0e3;
+ --primary-color: #22c55e;
+}
+
+.theme-light {
+ --bg-color: #fff;
+ --bg-color-100: #f8f9fa;
+ --bg-color-200: #e9ecef;
+ --bg-color-300: #dee2e6;
+ --text-color: #000;
+ --text-color-100: #161616;
+ --text-color-200: #2d2d2d;
+ --text-color-300: #3d3d3d;
+ --primary-color: #22c55e;
+}
+
+.theme-gray {
+ --bg-color: #f8f9fa;
+ --bg-color-100: #e9ecef;
+ --bg-color-200: #dee2e6;
+ --bg-color-300: #dde0e3;
+ --text-color: #000;
+ --text-color-100: #161616;
+ --text-color-200: #2d2d2d;
+ --text-color-300: #3d3d3d;
+ --primary-color: #22c55e;
+}
+
+.hover\:-translate-y-0\.5:hover {
+ --tw-translate-y: -0.125rem;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.hover\:scale-110:hover {
+ --tw-scale-x: 1.1;
+ --tw-scale-y: 1.1;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+
+.hover\:border-gray-400:hover {
+ --tw-border-opacity: 1;
+ border-color: rgb(156 163 175 / var(--tw-border-opacity, 1));
+}
+
+.hover\:border-red-500:hover {
+ --tw-border-opacity: 1;
+ border-color: rgb(239 68 68 / var(--tw-border-opacity, 1));
+}
+
+.hover\:bg-gray-100:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+}
+
+.hover\:bg-green-600:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1));
+}
+
+.hover\:bg-green-700:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(21 128 61 / var(--tw-bg-opacity, 1));
+}
+
+.hover\:bg-green-950:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(5 46 22 / var(--tw-bg-opacity, 1));
+}
+
+.hover\:bg-light-200:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(233 236 239 / var(--tw-bg-opacity, 1));
+}
+
+.hover\:text-gray-600:hover {
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1));
+}
+
+.hover\:text-gray-800:hover {
+ --tw-text-opacity: 1;
+ color: rgb(31 41 55 / var(--tw-text-opacity, 1));
+}
+
+.hover\:text-green-500:hover {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+
+.hover\:text-green-600:hover {
+ --tw-text-opacity: 1;
+ color: rgb(22 163 74 / var(--tw-text-opacity, 1));
+}
+
+.hover\:text-red-600:hover {
+ --tw-text-opacity: 1;
+ color: rgb(220 38 38 / var(--tw-text-opacity, 1));
+}
+
+.hover\:text-white:hover {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+
+.dark\:border-gray-600:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1));
+}
+
+.dark\:border-gray-700:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+
+.dark\:border-gray-800:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(31 41 55 / var(--tw-border-opacity, 1));
+}
+
+.dark\:bg-black:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-dark:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-dark-100:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-dark-300:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(61 61 61 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-gray-700:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-gray-800:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:bg-opacity-20:is(.dark *) {
+ --tw-bg-opacity: 0.2;
+}
+
+.dark\:bg-opacity-60:is(.dark *) {
+ --tw-bg-opacity: 0.6;
+}
+
+.dark\:bg-opacity-75:is(.dark *) {
+ --tw-bg-opacity: 0.75;
+}
+
+.dark\:text-gray-100:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(243 244 246 / var(--tw-text-opacity, 1));
+}
+
+.dark\:text-gray-200:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(229 231 235 / var(--tw-text-opacity, 1));
+}
+
+.dark\:text-gray-400:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+
+.dark\:text-white:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+
+.dark\:hover\:bg-gray-800:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}
+
+.dark\:hover\:text-gray-400:hover:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+
+.hover\:dark\:text-white:is(.dark *):hover {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+/*
+* Remix Icon v4.6.0
+* https://remixicon.com
+* https://github.com/Remix-Design/RemixIcon
+*
+* Copyright RemixIcon.com
+* Released under the Apache License Version 2.0
+*
+* Date: 2024-12-17
+*/
+@font-face {
+ font-family: "remixicon";
+ src: url('./remixicon-BVJ9S1ev.eot?t=1734404658139'); /* IE9*/
+ src: url('./remixicon-BVJ9S1ev.eot?t=1734404658139#iefix') format('embedded-opentype'),
+ url("./remixicon-BVvFtaex.woff2?t=1734404658139") format("woff2"),
+ url("./remixicon-BBpe-Xu7.woff?t=1734404658139") format("woff"),
+ url('./remixicon-CfJD46dY.ttf?t=1734404658139') format('truetype'),
+ url('./remixicon-C2wQ2gtc.svg?t=1734404658139#remixicon') format('svg'); /* iOS 4.1- */
+ font-display: swap;
+}
+
+[class^="ri-"], [class*=" ri-"] {
+ font-family: 'remixicon' !important;
+ font-style: normal;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+}
+
+.ri-lg { font-size: 1.3333em; line-height: 0.75em; vertical-align: -.0667em; }
+.ri-xl { font-size: 1.5em; line-height: 0.6666em; vertical-align: -.075em; }
+.ri-xxs { font-size: .5em; }
+.ri-xs { font-size: .75em; }
+.ri-sm { font-size: .875em }
+.ri-1x { font-size: 1em; }
+.ri-2x { font-size: 2em; }
+.ri-3x { font-size: 3em; }
+.ri-4x { font-size: 4em; }
+.ri-5x { font-size: 5em; }
+.ri-6x { font-size: 6em; }
+.ri-7x { font-size: 7em; }
+.ri-8x { font-size: 8em; }
+.ri-9x { font-size: 9em; }
+.ri-10x { font-size: 10em; }
+.ri-fw { text-align: center; width: 1.25em; }
+
+.ri-24-hours-fill:before { content: "\ea01"; }
+.ri-24-hours-line:before { content: "\ea02"; }
+.ri-4k-fill:before { content: "\ea03"; }
+.ri-4k-line:before { content: "\ea04"; }
+.ri-a-b:before { content: "\ea05"; }
+.ri-account-box-fill:before { content: "\ea06"; }
+.ri-account-box-line:before { content: "\ea07"; }
+.ri-account-circle-fill:before { content: "\ea08"; }
+.ri-account-circle-line:before { content: "\ea09"; }
+.ri-account-pin-box-fill:before { content: "\ea0a"; }
+.ri-account-pin-box-line:before { content: "\ea0b"; }
+.ri-account-pin-circle-fill:before { content: "\ea0c"; }
+.ri-account-pin-circle-line:before { content: "\ea0d"; }
+.ri-add-box-fill:before { content: "\ea0e"; }
+.ri-add-box-line:before { content: "\ea0f"; }
+.ri-add-circle-fill:before { content: "\ea10"; }
+.ri-add-circle-line:before { content: "\ea11"; }
+.ri-add-fill:before { content: "\ea12"; }
+.ri-add-line:before { content: "\ea13"; }
+.ri-admin-fill:before { content: "\ea14"; }
+.ri-admin-line:before { content: "\ea15"; }
+.ri-advertisement-fill:before { content: "\ea16"; }
+.ri-advertisement-line:before { content: "\ea17"; }
+.ri-airplay-fill:before { content: "\ea18"; }
+.ri-airplay-line:before { content: "\ea19"; }
+.ri-alarm-fill:before { content: "\ea1a"; }
+.ri-alarm-line:before { content: "\ea1b"; }
+.ri-alarm-warning-fill:before { content: "\ea1c"; }
+.ri-alarm-warning-line:before { content: "\ea1d"; }
+.ri-album-fill:before { content: "\ea1e"; }
+.ri-album-line:before { content: "\ea1f"; }
+.ri-alert-fill:before { content: "\ea20"; }
+.ri-alert-line:before { content: "\ea21"; }
+.ri-aliens-fill:before { content: "\ea22"; }
+.ri-aliens-line:before { content: "\ea23"; }
+.ri-align-bottom:before { content: "\ea24"; }
+.ri-align-center:before { content: "\ea25"; }
+.ri-align-justify:before { content: "\ea26"; }
+.ri-align-left:before { content: "\ea27"; }
+.ri-align-right:before { content: "\ea28"; }
+.ri-align-top:before { content: "\ea29"; }
+.ri-align-vertically:before { content: "\ea2a"; }
+.ri-alipay-fill:before { content: "\ea2b"; }
+.ri-alipay-line:before { content: "\ea2c"; }
+.ri-amazon-fill:before { content: "\ea2d"; }
+.ri-amazon-line:before { content: "\ea2e"; }
+.ri-anchor-fill:before { content: "\ea2f"; }
+.ri-anchor-line:before { content: "\ea30"; }
+.ri-ancient-gate-fill:before { content: "\ea31"; }
+.ri-ancient-gate-line:before { content: "\ea32"; }
+.ri-ancient-pavilion-fill:before { content: "\ea33"; }
+.ri-ancient-pavilion-line:before { content: "\ea34"; }
+.ri-android-fill:before { content: "\ea35"; }
+.ri-android-line:before { content: "\ea36"; }
+.ri-angularjs-fill:before { content: "\ea37"; }
+.ri-angularjs-line:before { content: "\ea38"; }
+.ri-anticlockwise-2-fill:before { content: "\ea39"; }
+.ri-anticlockwise-2-line:before { content: "\ea3a"; }
+.ri-anticlockwise-fill:before { content: "\ea3b"; }
+.ri-anticlockwise-line:before { content: "\ea3c"; }
+.ri-app-store-fill:before { content: "\ea3d"; }
+.ri-app-store-line:before { content: "\ea3e"; }
+.ri-apple-fill:before { content: "\ea3f"; }
+.ri-apple-line:before { content: "\ea40"; }
+.ri-apps-2-fill:before { content: "\ea41"; }
+.ri-apps-2-line:before { content: "\ea42"; }
+.ri-apps-fill:before { content: "\ea43"; }
+.ri-apps-line:before { content: "\ea44"; }
+.ri-archive-drawer-fill:before { content: "\ea45"; }
+.ri-archive-drawer-line:before { content: "\ea46"; }
+.ri-archive-fill:before { content: "\ea47"; }
+.ri-archive-line:before { content: "\ea48"; }
+.ri-arrow-down-circle-fill:before { content: "\ea49"; }
+.ri-arrow-down-circle-line:before { content: "\ea4a"; }
+.ri-arrow-down-fill:before { content: "\ea4b"; }
+.ri-arrow-down-line:before { content: "\ea4c"; }
+.ri-arrow-down-s-fill:before { content: "\ea4d"; }
+.ri-arrow-down-s-line:before { content: "\ea4e"; }
+.ri-arrow-drop-down-fill:before { content: "\ea4f"; }
+.ri-arrow-drop-down-line:before { content: "\ea50"; }
+.ri-arrow-drop-left-fill:before { content: "\ea51"; }
+.ri-arrow-drop-left-line:before { content: "\ea52"; }
+.ri-arrow-drop-right-fill:before { content: "\ea53"; }
+.ri-arrow-drop-right-line:before { content: "\ea54"; }
+.ri-arrow-drop-up-fill:before { content: "\ea55"; }
+.ri-arrow-drop-up-line:before { content: "\ea56"; }
+.ri-arrow-go-back-fill:before { content: "\ea57"; }
+.ri-arrow-go-back-line:before { content: "\ea58"; }
+.ri-arrow-go-forward-fill:before { content: "\ea59"; }
+.ri-arrow-go-forward-line:before { content: "\ea5a"; }
+.ri-arrow-left-circle-fill:before { content: "\ea5b"; }
+.ri-arrow-left-circle-line:before { content: "\ea5c"; }
+.ri-arrow-left-down-fill:before { content: "\ea5d"; }
+.ri-arrow-left-down-line:before { content: "\ea5e"; }
+.ri-arrow-left-fill:before { content: "\ea5f"; }
+.ri-arrow-left-line:before { content: "\ea60"; }
+.ri-arrow-left-right-fill:before { content: "\ea61"; }
+.ri-arrow-left-right-line:before { content: "\ea62"; }
+.ri-arrow-left-s-fill:before { content: "\ea63"; }
+.ri-arrow-left-s-line:before { content: "\ea64"; }
+.ri-arrow-left-up-fill:before { content: "\ea65"; }
+.ri-arrow-left-up-line:before { content: "\ea66"; }
+.ri-arrow-right-circle-fill:before { content: "\ea67"; }
+.ri-arrow-right-circle-line:before { content: "\ea68"; }
+.ri-arrow-right-down-fill:before { content: "\ea69"; }
+.ri-arrow-right-down-line:before { content: "\ea6a"; }
+.ri-arrow-right-fill:before { content: "\ea6b"; }
+.ri-arrow-right-line:before { content: "\ea6c"; }
+.ri-arrow-right-s-fill:before { content: "\ea6d"; }
+.ri-arrow-right-s-line:before { content: "\ea6e"; }
+.ri-arrow-right-up-fill:before { content: "\ea6f"; }
+.ri-arrow-right-up-line:before { content: "\ea70"; }
+.ri-arrow-up-circle-fill:before { content: "\ea71"; }
+.ri-arrow-up-circle-line:before { content: "\ea72"; }
+.ri-arrow-up-down-fill:before { content: "\ea73"; }
+.ri-arrow-up-down-line:before { content: "\ea74"; }
+.ri-arrow-up-fill:before { content: "\ea75"; }
+.ri-arrow-up-line:before { content: "\ea76"; }
+.ri-arrow-up-s-fill:before { content: "\ea77"; }
+.ri-arrow-up-s-line:before { content: "\ea78"; }
+.ri-artboard-2-fill:before { content: "\ea79"; }
+.ri-artboard-2-line:before { content: "\ea7a"; }
+.ri-artboard-fill:before { content: "\ea7b"; }
+.ri-artboard-line:before { content: "\ea7c"; }
+.ri-article-fill:before { content: "\ea7d"; }
+.ri-article-line:before { content: "\ea7e"; }
+.ri-aspect-ratio-fill:before { content: "\ea7f"; }
+.ri-aspect-ratio-line:before { content: "\ea80"; }
+.ri-asterisk:before { content: "\ea81"; }
+.ri-at-fill:before { content: "\ea82"; }
+.ri-at-line:before { content: "\ea83"; }
+.ri-attachment-2:before { content: "\ea84"; }
+.ri-attachment-fill:before { content: "\ea85"; }
+.ri-attachment-line:before { content: "\ea86"; }
+.ri-auction-fill:before { content: "\ea87"; }
+.ri-auction-line:before { content: "\ea88"; }
+.ri-award-fill:before { content: "\ea89"; }
+.ri-award-line:before { content: "\ea8a"; }
+.ri-baidu-fill:before { content: "\ea8b"; }
+.ri-baidu-line:before { content: "\ea8c"; }
+.ri-ball-pen-fill:before { content: "\ea8d"; }
+.ri-ball-pen-line:before { content: "\ea8e"; }
+.ri-bank-card-2-fill:before { content: "\ea8f"; }
+.ri-bank-card-2-line:before { content: "\ea90"; }
+.ri-bank-card-fill:before { content: "\ea91"; }
+.ri-bank-card-line:before { content: "\ea92"; }
+.ri-bank-fill:before { content: "\ea93"; }
+.ri-bank-line:before { content: "\ea94"; }
+.ri-bar-chart-2-fill:before { content: "\ea95"; }
+.ri-bar-chart-2-line:before { content: "\ea96"; }
+.ri-bar-chart-box-fill:before { content: "\ea97"; }
+.ri-bar-chart-box-line:before { content: "\ea98"; }
+.ri-bar-chart-fill:before { content: "\ea99"; }
+.ri-bar-chart-grouped-fill:before { content: "\ea9a"; }
+.ri-bar-chart-grouped-line:before { content: "\ea9b"; }
+.ri-bar-chart-horizontal-fill:before { content: "\ea9c"; }
+.ri-bar-chart-horizontal-line:before { content: "\ea9d"; }
+.ri-bar-chart-line:before { content: "\ea9e"; }
+.ri-barcode-box-fill:before { content: "\ea9f"; }
+.ri-barcode-box-line:before { content: "\eaa0"; }
+.ri-barcode-fill:before { content: "\eaa1"; }
+.ri-barcode-line:before { content: "\eaa2"; }
+.ri-barricade-fill:before { content: "\eaa3"; }
+.ri-barricade-line:before { content: "\eaa4"; }
+.ri-base-station-fill:before { content: "\eaa5"; }
+.ri-base-station-line:before { content: "\eaa6"; }
+.ri-basketball-fill:before { content: "\eaa7"; }
+.ri-basketball-line:before { content: "\eaa8"; }
+.ri-battery-2-charge-fill:before { content: "\eaa9"; }
+.ri-battery-2-charge-line:before { content: "\eaaa"; }
+.ri-battery-2-fill:before { content: "\eaab"; }
+.ri-battery-2-line:before { content: "\eaac"; }
+.ri-battery-charge-fill:before { content: "\eaad"; }
+.ri-battery-charge-line:before { content: "\eaae"; }
+.ri-battery-fill:before { content: "\eaaf"; }
+.ri-battery-line:before { content: "\eab0"; }
+.ri-battery-low-fill:before { content: "\eab1"; }
+.ri-battery-low-line:before { content: "\eab2"; }
+.ri-battery-saver-fill:before { content: "\eab3"; }
+.ri-battery-saver-line:before { content: "\eab4"; }
+.ri-battery-share-fill:before { content: "\eab5"; }
+.ri-battery-share-line:before { content: "\eab6"; }
+.ri-bear-smile-fill:before { content: "\eab7"; }
+.ri-bear-smile-line:before { content: "\eab8"; }
+.ri-behance-fill:before { content: "\eab9"; }
+.ri-behance-line:before { content: "\eaba"; }
+.ri-bell-fill:before { content: "\eabb"; }
+.ri-bell-line:before { content: "\eabc"; }
+.ri-bike-fill:before { content: "\eabd"; }
+.ri-bike-line:before { content: "\eabe"; }
+.ri-bilibili-fill:before { content: "\eabf"; }
+.ri-bilibili-line:before { content: "\eac0"; }
+.ri-bill-fill:before { content: "\eac1"; }
+.ri-bill-line:before { content: "\eac2"; }
+.ri-billiards-fill:before { content: "\eac3"; }
+.ri-billiards-line:before { content: "\eac4"; }
+.ri-bit-coin-fill:before { content: "\eac5"; }
+.ri-bit-coin-line:before { content: "\eac6"; }
+.ri-blaze-fill:before { content: "\eac7"; }
+.ri-blaze-line:before { content: "\eac8"; }
+.ri-bluetooth-connect-fill:before { content: "\eac9"; }
+.ri-bluetooth-connect-line:before { content: "\eaca"; }
+.ri-bluetooth-fill:before { content: "\eacb"; }
+.ri-bluetooth-line:before { content: "\eacc"; }
+.ri-blur-off-fill:before { content: "\eacd"; }
+.ri-blur-off-line:before { content: "\eace"; }
+.ri-body-scan-fill:before { content: "\eacf"; }
+.ri-body-scan-line:before { content: "\ead0"; }
+.ri-bold:before { content: "\ead1"; }
+.ri-book-2-fill:before { content: "\ead2"; }
+.ri-book-2-line:before { content: "\ead3"; }
+.ri-book-3-fill:before { content: "\ead4"; }
+.ri-book-3-line:before { content: "\ead5"; }
+.ri-book-fill:before { content: "\ead6"; }
+.ri-book-line:before { content: "\ead7"; }
+.ri-book-marked-fill:before { content: "\ead8"; }
+.ri-book-marked-line:before { content: "\ead9"; }
+.ri-book-open-fill:before { content: "\eada"; }
+.ri-book-open-line:before { content: "\eadb"; }
+.ri-book-read-fill:before { content: "\eadc"; }
+.ri-book-read-line:before { content: "\eadd"; }
+.ri-booklet-fill:before { content: "\eade"; }
+.ri-booklet-line:before { content: "\eadf"; }
+.ri-bookmark-2-fill:before { content: "\eae0"; }
+.ri-bookmark-2-line:before { content: "\eae1"; }
+.ri-bookmark-3-fill:before { content: "\eae2"; }
+.ri-bookmark-3-line:before { content: "\eae3"; }
+.ri-bookmark-fill:before { content: "\eae4"; }
+.ri-bookmark-line:before { content: "\eae5"; }
+.ri-boxing-fill:before { content: "\eae6"; }
+.ri-boxing-line:before { content: "\eae7"; }
+.ri-braces-fill:before { content: "\eae8"; }
+.ri-braces-line:before { content: "\eae9"; }
+.ri-brackets-fill:before { content: "\eaea"; }
+.ri-brackets-line:before { content: "\eaeb"; }
+.ri-briefcase-2-fill:before { content: "\eaec"; }
+.ri-briefcase-2-line:before { content: "\eaed"; }
+.ri-briefcase-3-fill:before { content: "\eaee"; }
+.ri-briefcase-3-line:before { content: "\eaef"; }
+.ri-briefcase-4-fill:before { content: "\eaf0"; }
+.ri-briefcase-4-line:before { content: "\eaf1"; }
+.ri-briefcase-5-fill:before { content: "\eaf2"; }
+.ri-briefcase-5-line:before { content: "\eaf3"; }
+.ri-briefcase-fill:before { content: "\eaf4"; }
+.ri-briefcase-line:before { content: "\eaf5"; }
+.ri-bring-forward:before { content: "\eaf6"; }
+.ri-bring-to-front:before { content: "\eaf7"; }
+.ri-broadcast-fill:before { content: "\eaf8"; }
+.ri-broadcast-line:before { content: "\eaf9"; }
+.ri-brush-2-fill:before { content: "\eafa"; }
+.ri-brush-2-line:before { content: "\eafb"; }
+.ri-brush-3-fill:before { content: "\eafc"; }
+.ri-brush-3-line:before { content: "\eafd"; }
+.ri-brush-4-fill:before { content: "\eafe"; }
+.ri-brush-4-line:before { content: "\eaff"; }
+.ri-brush-fill:before { content: "\eb00"; }
+.ri-brush-line:before { content: "\eb01"; }
+.ri-bubble-chart-fill:before { content: "\eb02"; }
+.ri-bubble-chart-line:before { content: "\eb03"; }
+.ri-bug-2-fill:before { content: "\eb04"; }
+.ri-bug-2-line:before { content: "\eb05"; }
+.ri-bug-fill:before { content: "\eb06"; }
+.ri-bug-line:before { content: "\eb07"; }
+.ri-building-2-fill:before { content: "\eb08"; }
+.ri-building-2-line:before { content: "\eb09"; }
+.ri-building-3-fill:before { content: "\eb0a"; }
+.ri-building-3-line:before { content: "\eb0b"; }
+.ri-building-4-fill:before { content: "\eb0c"; }
+.ri-building-4-line:before { content: "\eb0d"; }
+.ri-building-fill:before { content: "\eb0e"; }
+.ri-building-line:before { content: "\eb0f"; }
+.ri-bus-2-fill:before { content: "\eb10"; }
+.ri-bus-2-line:before { content: "\eb11"; }
+.ri-bus-fill:before { content: "\eb12"; }
+.ri-bus-line:before { content: "\eb13"; }
+.ri-bus-wifi-fill:before { content: "\eb14"; }
+.ri-bus-wifi-line:before { content: "\eb15"; }
+.ri-cactus-fill:before { content: "\eb16"; }
+.ri-cactus-line:before { content: "\eb17"; }
+.ri-cake-2-fill:before { content: "\eb18"; }
+.ri-cake-2-line:before { content: "\eb19"; }
+.ri-cake-3-fill:before { content: "\eb1a"; }
+.ri-cake-3-line:before { content: "\eb1b"; }
+.ri-cake-fill:before { content: "\eb1c"; }
+.ri-cake-line:before { content: "\eb1d"; }
+.ri-calculator-fill:before { content: "\eb1e"; }
+.ri-calculator-line:before { content: "\eb1f"; }
+.ri-calendar-2-fill:before { content: "\eb20"; }
+.ri-calendar-2-line:before { content: "\eb21"; }
+.ri-calendar-check-fill:before { content: "\eb22"; }
+.ri-calendar-check-line:before { content: "\eb23"; }
+.ri-calendar-event-fill:before { content: "\eb24"; }
+.ri-calendar-event-line:before { content: "\eb25"; }
+.ri-calendar-fill:before { content: "\eb26"; }
+.ri-calendar-line:before { content: "\eb27"; }
+.ri-calendar-todo-fill:before { content: "\eb28"; }
+.ri-calendar-todo-line:before { content: "\eb29"; }
+.ri-camera-2-fill:before { content: "\eb2a"; }
+.ri-camera-2-line:before { content: "\eb2b"; }
+.ri-camera-3-fill:before { content: "\eb2c"; }
+.ri-camera-3-line:before { content: "\eb2d"; }
+.ri-camera-fill:before { content: "\eb2e"; }
+.ri-camera-lens-fill:before { content: "\eb2f"; }
+.ri-camera-lens-line:before { content: "\eb30"; }
+.ri-camera-line:before { content: "\eb31"; }
+.ri-camera-off-fill:before { content: "\eb32"; }
+.ri-camera-off-line:before { content: "\eb33"; }
+.ri-camera-switch-fill:before { content: "\eb34"; }
+.ri-camera-switch-line:before { content: "\eb35"; }
+.ri-capsule-fill:before { content: "\eb36"; }
+.ri-capsule-line:before { content: "\eb37"; }
+.ri-car-fill:before { content: "\eb38"; }
+.ri-car-line:before { content: "\eb39"; }
+.ri-car-washing-fill:before { content: "\eb3a"; }
+.ri-car-washing-line:before { content: "\eb3b"; }
+.ri-caravan-fill:before { content: "\eb3c"; }
+.ri-caravan-line:before { content: "\eb3d"; }
+.ri-cast-fill:before { content: "\eb3e"; }
+.ri-cast-line:before { content: "\eb3f"; }
+.ri-cellphone-fill:before { content: "\eb40"; }
+.ri-cellphone-line:before { content: "\eb41"; }
+.ri-celsius-fill:before { content: "\eb42"; }
+.ri-celsius-line:before { content: "\eb43"; }
+.ri-centos-fill:before { content: "\eb44"; }
+.ri-centos-line:before { content: "\eb45"; }
+.ri-character-recognition-fill:before { content: "\eb46"; }
+.ri-character-recognition-line:before { content: "\eb47"; }
+.ri-charging-pile-2-fill:before { content: "\eb48"; }
+.ri-charging-pile-2-line:before { content: "\eb49"; }
+.ri-charging-pile-fill:before { content: "\eb4a"; }
+.ri-charging-pile-line:before { content: "\eb4b"; }
+.ri-chat-1-fill:before { content: "\eb4c"; }
+.ri-chat-1-line:before { content: "\eb4d"; }
+.ri-chat-2-fill:before { content: "\eb4e"; }
+.ri-chat-2-line:before { content: "\eb4f"; }
+.ri-chat-3-fill:before { content: "\eb50"; }
+.ri-chat-3-line:before { content: "\eb51"; }
+.ri-chat-4-fill:before { content: "\eb52"; }
+.ri-chat-4-line:before { content: "\eb53"; }
+.ri-chat-check-fill:before { content: "\eb54"; }
+.ri-chat-check-line:before { content: "\eb55"; }
+.ri-chat-delete-fill:before { content: "\eb56"; }
+.ri-chat-delete-line:before { content: "\eb57"; }
+.ri-chat-download-fill:before { content: "\eb58"; }
+.ri-chat-download-line:before { content: "\eb59"; }
+.ri-chat-follow-up-fill:before { content: "\eb5a"; }
+.ri-chat-follow-up-line:before { content: "\eb5b"; }
+.ri-chat-forward-fill:before { content: "\eb5c"; }
+.ri-chat-forward-line:before { content: "\eb5d"; }
+.ri-chat-heart-fill:before { content: "\eb5e"; }
+.ri-chat-heart-line:before { content: "\eb5f"; }
+.ri-chat-history-fill:before { content: "\eb60"; }
+.ri-chat-history-line:before { content: "\eb61"; }
+.ri-chat-new-fill:before { content: "\eb62"; }
+.ri-chat-new-line:before { content: "\eb63"; }
+.ri-chat-off-fill:before { content: "\eb64"; }
+.ri-chat-off-line:before { content: "\eb65"; }
+.ri-chat-poll-fill:before { content: "\eb66"; }
+.ri-chat-poll-line:before { content: "\eb67"; }
+.ri-chat-private-fill:before { content: "\eb68"; }
+.ri-chat-private-line:before { content: "\eb69"; }
+.ri-chat-quote-fill:before { content: "\eb6a"; }
+.ri-chat-quote-line:before { content: "\eb6b"; }
+.ri-chat-settings-fill:before { content: "\eb6c"; }
+.ri-chat-settings-line:before { content: "\eb6d"; }
+.ri-chat-smile-2-fill:before { content: "\eb6e"; }
+.ri-chat-smile-2-line:before { content: "\eb6f"; }
+.ri-chat-smile-3-fill:before { content: "\eb70"; }
+.ri-chat-smile-3-line:before { content: "\eb71"; }
+.ri-chat-smile-fill:before { content: "\eb72"; }
+.ri-chat-smile-line:before { content: "\eb73"; }
+.ri-chat-upload-fill:before { content: "\eb74"; }
+.ri-chat-upload-line:before { content: "\eb75"; }
+.ri-chat-voice-fill:before { content: "\eb76"; }
+.ri-chat-voice-line:before { content: "\eb77"; }
+.ri-check-double-fill:before { content: "\eb78"; }
+.ri-check-double-line:before { content: "\eb79"; }
+.ri-check-fill:before { content: "\eb7a"; }
+.ri-check-line:before { content: "\eb7b"; }
+.ri-checkbox-blank-circle-fill:before { content: "\eb7c"; }
+.ri-checkbox-blank-circle-line:before { content: "\eb7d"; }
+.ri-checkbox-blank-fill:before { content: "\eb7e"; }
+.ri-checkbox-blank-line:before { content: "\eb7f"; }
+.ri-checkbox-circle-fill:before { content: "\eb80"; }
+.ri-checkbox-circle-line:before { content: "\eb81"; }
+.ri-checkbox-fill:before { content: "\eb82"; }
+.ri-checkbox-indeterminate-fill:before { content: "\eb83"; }
+.ri-checkbox-indeterminate-line:before { content: "\eb84"; }
+.ri-checkbox-line:before { content: "\eb85"; }
+.ri-checkbox-multiple-blank-fill:before { content: "\eb86"; }
+.ri-checkbox-multiple-blank-line:before { content: "\eb87"; }
+.ri-checkbox-multiple-fill:before { content: "\eb88"; }
+.ri-checkbox-multiple-line:before { content: "\eb89"; }
+.ri-china-railway-fill:before { content: "\eb8a"; }
+.ri-china-railway-line:before { content: "\eb8b"; }
+.ri-chrome-fill:before { content: "\eb8c"; }
+.ri-chrome-line:before { content: "\eb8d"; }
+.ri-clapperboard-fill:before { content: "\eb8e"; }
+.ri-clapperboard-line:before { content: "\eb8f"; }
+.ri-clipboard-fill:before { content: "\eb90"; }
+.ri-clipboard-line:before { content: "\eb91"; }
+.ri-clockwise-2-fill:before { content: "\eb92"; }
+.ri-clockwise-2-line:before { content: "\eb93"; }
+.ri-clockwise-fill:before { content: "\eb94"; }
+.ri-clockwise-line:before { content: "\eb95"; }
+.ri-close-circle-fill:before { content: "\eb96"; }
+.ri-close-circle-line:before { content: "\eb97"; }
+.ri-close-fill:before { content: "\eb98"; }
+.ri-close-line:before { content: "\eb99"; }
+.ri-closed-captioning-fill:before { content: "\eb9a"; }
+.ri-closed-captioning-line:before { content: "\eb9b"; }
+.ri-cloud-fill:before { content: "\eb9c"; }
+.ri-cloud-line:before { content: "\eb9d"; }
+.ri-cloud-off-fill:before { content: "\eb9e"; }
+.ri-cloud-off-line:before { content: "\eb9f"; }
+.ri-cloud-windy-fill:before { content: "\eba0"; }
+.ri-cloud-windy-line:before { content: "\eba1"; }
+.ri-cloudy-2-fill:before { content: "\eba2"; }
+.ri-cloudy-2-line:before { content: "\eba3"; }
+.ri-cloudy-fill:before { content: "\eba4"; }
+.ri-cloudy-line:before { content: "\eba5"; }
+.ri-code-box-fill:before { content: "\eba6"; }
+.ri-code-box-line:before { content: "\eba7"; }
+.ri-code-fill:before { content: "\eba8"; }
+.ri-code-line:before { content: "\eba9"; }
+.ri-code-s-fill:before { content: "\ebaa"; }
+.ri-code-s-line:before { content: "\ebab"; }
+.ri-code-s-slash-fill:before { content: "\ebac"; }
+.ri-code-s-slash-line:before { content: "\ebad"; }
+.ri-code-view:before { content: "\ebae"; }
+.ri-codepen-fill:before { content: "\ebaf"; }
+.ri-codepen-line:before { content: "\ebb0"; }
+.ri-coin-fill:before { content: "\ebb1"; }
+.ri-coin-line:before { content: "\ebb2"; }
+.ri-coins-fill:before { content: "\ebb3"; }
+.ri-coins-line:before { content: "\ebb4"; }
+.ri-collage-fill:before { content: "\ebb5"; }
+.ri-collage-line:before { content: "\ebb6"; }
+.ri-command-fill:before { content: "\ebb7"; }
+.ri-command-line:before { content: "\ebb8"; }
+.ri-community-fill:before { content: "\ebb9"; }
+.ri-community-line:before { content: "\ebba"; }
+.ri-compass-2-fill:before { content: "\ebbb"; }
+.ri-compass-2-line:before { content: "\ebbc"; }
+.ri-compass-3-fill:before { content: "\ebbd"; }
+.ri-compass-3-line:before { content: "\ebbe"; }
+.ri-compass-4-fill:before { content: "\ebbf"; }
+.ri-compass-4-line:before { content: "\ebc0"; }
+.ri-compass-discover-fill:before { content: "\ebc1"; }
+.ri-compass-discover-line:before { content: "\ebc2"; }
+.ri-compass-fill:before { content: "\ebc3"; }
+.ri-compass-line:before { content: "\ebc4"; }
+.ri-compasses-2-fill:before { content: "\ebc5"; }
+.ri-compasses-2-line:before { content: "\ebc6"; }
+.ri-compasses-fill:before { content: "\ebc7"; }
+.ri-compasses-line:before { content: "\ebc8"; }
+.ri-computer-fill:before { content: "\ebc9"; }
+.ri-computer-line:before { content: "\ebca"; }
+.ri-contacts-book-2-fill:before { content: "\ebcb"; }
+.ri-contacts-book-2-line:before { content: "\ebcc"; }
+.ri-contacts-book-fill:before { content: "\ebcd"; }
+.ri-contacts-book-line:before { content: "\ebce"; }
+.ri-contacts-book-upload-fill:before { content: "\ebcf"; }
+.ri-contacts-book-upload-line:before { content: "\ebd0"; }
+.ri-contacts-fill:before { content: "\ebd1"; }
+.ri-contacts-line:before { content: "\ebd2"; }
+.ri-contrast-2-fill:before { content: "\ebd3"; }
+.ri-contrast-2-line:before { content: "\ebd4"; }
+.ri-contrast-drop-2-fill:before { content: "\ebd5"; }
+.ri-contrast-drop-2-line:before { content: "\ebd6"; }
+.ri-contrast-drop-fill:before { content: "\ebd7"; }
+.ri-contrast-drop-line:before { content: "\ebd8"; }
+.ri-contrast-fill:before { content: "\ebd9"; }
+.ri-contrast-line:before { content: "\ebda"; }
+.ri-copper-coin-fill:before { content: "\ebdb"; }
+.ri-copper-coin-line:before { content: "\ebdc"; }
+.ri-copper-diamond-fill:before { content: "\ebdd"; }
+.ri-copper-diamond-line:before { content: "\ebde"; }
+.ri-copyleft-fill:before { content: "\ebdf"; }
+.ri-copyleft-line:before { content: "\ebe0"; }
+.ri-copyright-fill:before { content: "\ebe1"; }
+.ri-copyright-line:before { content: "\ebe2"; }
+.ri-coreos-fill:before { content: "\ebe3"; }
+.ri-coreos-line:before { content: "\ebe4"; }
+.ri-coupon-2-fill:before { content: "\ebe5"; }
+.ri-coupon-2-line:before { content: "\ebe6"; }
+.ri-coupon-3-fill:before { content: "\ebe7"; }
+.ri-coupon-3-line:before { content: "\ebe8"; }
+.ri-coupon-4-fill:before { content: "\ebe9"; }
+.ri-coupon-4-line:before { content: "\ebea"; }
+.ri-coupon-5-fill:before { content: "\ebeb"; }
+.ri-coupon-5-line:before { content: "\ebec"; }
+.ri-coupon-fill:before { content: "\ebed"; }
+.ri-coupon-line:before { content: "\ebee"; }
+.ri-cpu-fill:before { content: "\ebef"; }
+.ri-cpu-line:before { content: "\ebf0"; }
+.ri-creative-commons-by-fill:before { content: "\ebf1"; }
+.ri-creative-commons-by-line:before { content: "\ebf2"; }
+.ri-creative-commons-fill:before { content: "\ebf3"; }
+.ri-creative-commons-line:before { content: "\ebf4"; }
+.ri-creative-commons-nc-fill:before { content: "\ebf5"; }
+.ri-creative-commons-nc-line:before { content: "\ebf6"; }
+.ri-creative-commons-nd-fill:before { content: "\ebf7"; }
+.ri-creative-commons-nd-line:before { content: "\ebf8"; }
+.ri-creative-commons-sa-fill:before { content: "\ebf9"; }
+.ri-creative-commons-sa-line:before { content: "\ebfa"; }
+.ri-creative-commons-zero-fill:before { content: "\ebfb"; }
+.ri-creative-commons-zero-line:before { content: "\ebfc"; }
+.ri-criminal-fill:before { content: "\ebfd"; }
+.ri-criminal-line:before { content: "\ebfe"; }
+.ri-crop-2-fill:before { content: "\ebff"; }
+.ri-crop-2-line:before { content: "\ec00"; }
+.ri-crop-fill:before { content: "\ec01"; }
+.ri-crop-line:before { content: "\ec02"; }
+.ri-css3-fill:before { content: "\ec03"; }
+.ri-css3-line:before { content: "\ec04"; }
+.ri-cup-fill:before { content: "\ec05"; }
+.ri-cup-line:before { content: "\ec06"; }
+.ri-currency-fill:before { content: "\ec07"; }
+.ri-currency-line:before { content: "\ec08"; }
+.ri-cursor-fill:before { content: "\ec09"; }
+.ri-cursor-line:before { content: "\ec0a"; }
+.ri-customer-service-2-fill:before { content: "\ec0b"; }
+.ri-customer-service-2-line:before { content: "\ec0c"; }
+.ri-customer-service-fill:before { content: "\ec0d"; }
+.ri-customer-service-line:before { content: "\ec0e"; }
+.ri-dashboard-2-fill:before { content: "\ec0f"; }
+.ri-dashboard-2-line:before { content: "\ec10"; }
+.ri-dashboard-3-fill:before { content: "\ec11"; }
+.ri-dashboard-3-line:before { content: "\ec12"; }
+.ri-dashboard-fill:before { content: "\ec13"; }
+.ri-dashboard-line:before { content: "\ec14"; }
+.ri-database-2-fill:before { content: "\ec15"; }
+.ri-database-2-line:before { content: "\ec16"; }
+.ri-database-fill:before { content: "\ec17"; }
+.ri-database-line:before { content: "\ec18"; }
+.ri-delete-back-2-fill:before { content: "\ec19"; }
+.ri-delete-back-2-line:before { content: "\ec1a"; }
+.ri-delete-back-fill:before { content: "\ec1b"; }
+.ri-delete-back-line:before { content: "\ec1c"; }
+.ri-delete-bin-2-fill:before { content: "\ec1d"; }
+.ri-delete-bin-2-line:before { content: "\ec1e"; }
+.ri-delete-bin-3-fill:before { content: "\ec1f"; }
+.ri-delete-bin-3-line:before { content: "\ec20"; }
+.ri-delete-bin-4-fill:before { content: "\ec21"; }
+.ri-delete-bin-4-line:before { content: "\ec22"; }
+.ri-delete-bin-5-fill:before { content: "\ec23"; }
+.ri-delete-bin-5-line:before { content: "\ec24"; }
+.ri-delete-bin-6-fill:before { content: "\ec25"; }
+.ri-delete-bin-6-line:before { content: "\ec26"; }
+.ri-delete-bin-7-fill:before { content: "\ec27"; }
+.ri-delete-bin-7-line:before { content: "\ec28"; }
+.ri-delete-bin-fill:before { content: "\ec29"; }
+.ri-delete-bin-line:before { content: "\ec2a"; }
+.ri-delete-column:before { content: "\ec2b"; }
+.ri-delete-row:before { content: "\ec2c"; }
+.ri-device-fill:before { content: "\ec2d"; }
+.ri-device-line:before { content: "\ec2e"; }
+.ri-device-recover-fill:before { content: "\ec2f"; }
+.ri-device-recover-line:before { content: "\ec30"; }
+.ri-dingding-fill:before { content: "\ec31"; }
+.ri-dingding-line:before { content: "\ec32"; }
+.ri-direction-fill:before { content: "\ec33"; }
+.ri-direction-line:before { content: "\ec34"; }
+.ri-disc-fill:before { content: "\ec35"; }
+.ri-disc-line:before { content: "\ec36"; }
+.ri-discord-fill:before { content: "\ec37"; }
+.ri-discord-line:before { content: "\ec38"; }
+.ri-discuss-fill:before { content: "\ec39"; }
+.ri-discuss-line:before { content: "\ec3a"; }
+.ri-dislike-fill:before { content: "\ec3b"; }
+.ri-dislike-line:before { content: "\ec3c"; }
+.ri-disqus-fill:before { content: "\ec3d"; }
+.ri-disqus-line:before { content: "\ec3e"; }
+.ri-divide-fill:before { content: "\ec3f"; }
+.ri-divide-line:before { content: "\ec40"; }
+.ri-donut-chart-fill:before { content: "\ec41"; }
+.ri-donut-chart-line:before { content: "\ec42"; }
+.ri-door-closed-fill:before { content: "\ec43"; }
+.ri-door-closed-line:before { content: "\ec44"; }
+.ri-door-fill:before { content: "\ec45"; }
+.ri-door-line:before { content: "\ec46"; }
+.ri-door-lock-box-fill:before { content: "\ec47"; }
+.ri-door-lock-box-line:before { content: "\ec48"; }
+.ri-door-lock-fill:before { content: "\ec49"; }
+.ri-door-lock-line:before { content: "\ec4a"; }
+.ri-door-open-fill:before { content: "\ec4b"; }
+.ri-door-open-line:before { content: "\ec4c"; }
+.ri-dossier-fill:before { content: "\ec4d"; }
+.ri-dossier-line:before { content: "\ec4e"; }
+.ri-douban-fill:before { content: "\ec4f"; }
+.ri-douban-line:before { content: "\ec50"; }
+.ri-double-quotes-l:before { content: "\ec51"; }
+.ri-double-quotes-r:before { content: "\ec52"; }
+.ri-download-2-fill:before { content: "\ec53"; }
+.ri-download-2-line:before { content: "\ec54"; }
+.ri-download-cloud-2-fill:before { content: "\ec55"; }
+.ri-download-cloud-2-line:before { content: "\ec56"; }
+.ri-download-cloud-fill:before { content: "\ec57"; }
+.ri-download-cloud-line:before { content: "\ec58"; }
+.ri-download-fill:before { content: "\ec59"; }
+.ri-download-line:before { content: "\ec5a"; }
+.ri-draft-fill:before { content: "\ec5b"; }
+.ri-draft-line:before { content: "\ec5c"; }
+.ri-drag-drop-fill:before { content: "\ec5d"; }
+.ri-drag-drop-line:before { content: "\ec5e"; }
+.ri-drag-move-2-fill:before { content: "\ec5f"; }
+.ri-drag-move-2-line:before { content: "\ec60"; }
+.ri-drag-move-fill:before { content: "\ec61"; }
+.ri-drag-move-line:before { content: "\ec62"; }
+.ri-dribbble-fill:before { content: "\ec63"; }
+.ri-dribbble-line:before { content: "\ec64"; }
+.ri-drive-fill:before { content: "\ec65"; }
+.ri-drive-line:before { content: "\ec66"; }
+.ri-drizzle-fill:before { content: "\ec67"; }
+.ri-drizzle-line:before { content: "\ec68"; }
+.ri-drop-fill:before { content: "\ec69"; }
+.ri-drop-line:before { content: "\ec6a"; }
+.ri-dropbox-fill:before { content: "\ec6b"; }
+.ri-dropbox-line:before { content: "\ec6c"; }
+.ri-dual-sim-1-fill:before { content: "\ec6d"; }
+.ri-dual-sim-1-line:before { content: "\ec6e"; }
+.ri-dual-sim-2-fill:before { content: "\ec6f"; }
+.ri-dual-sim-2-line:before { content: "\ec70"; }
+.ri-dv-fill:before { content: "\ec71"; }
+.ri-dv-line:before { content: "\ec72"; }
+.ri-dvd-fill:before { content: "\ec73"; }
+.ri-dvd-line:before { content: "\ec74"; }
+.ri-e-bike-2-fill:before { content: "\ec75"; }
+.ri-e-bike-2-line:before { content: "\ec76"; }
+.ri-e-bike-fill:before { content: "\ec77"; }
+.ri-e-bike-line:before { content: "\ec78"; }
+.ri-earth-fill:before { content: "\ec79"; }
+.ri-earth-line:before { content: "\ec7a"; }
+.ri-earthquake-fill:before { content: "\ec7b"; }
+.ri-earthquake-line:before { content: "\ec7c"; }
+.ri-edge-fill:before { content: "\ec7d"; }
+.ri-edge-line:before { content: "\ec7e"; }
+.ri-edit-2-fill:before { content: "\ec7f"; }
+.ri-edit-2-line:before { content: "\ec80"; }
+.ri-edit-box-fill:before { content: "\ec81"; }
+.ri-edit-box-line:before { content: "\ec82"; }
+.ri-edit-circle-fill:before { content: "\ec83"; }
+.ri-edit-circle-line:before { content: "\ec84"; }
+.ri-edit-fill:before { content: "\ec85"; }
+.ri-edit-line:before { content: "\ec86"; }
+.ri-eject-fill:before { content: "\ec87"; }
+.ri-eject-line:before { content: "\ec88"; }
+.ri-emotion-2-fill:before { content: "\ec89"; }
+.ri-emotion-2-line:before { content: "\ec8a"; }
+.ri-emotion-fill:before { content: "\ec8b"; }
+.ri-emotion-happy-fill:before { content: "\ec8c"; }
+.ri-emotion-happy-line:before { content: "\ec8d"; }
+.ri-emotion-laugh-fill:before { content: "\ec8e"; }
+.ri-emotion-laugh-line:before { content: "\ec8f"; }
+.ri-emotion-line:before { content: "\ec90"; }
+.ri-emotion-normal-fill:before { content: "\ec91"; }
+.ri-emotion-normal-line:before { content: "\ec92"; }
+.ri-emotion-sad-fill:before { content: "\ec93"; }
+.ri-emotion-sad-line:before { content: "\ec94"; }
+.ri-emotion-unhappy-fill:before { content: "\ec95"; }
+.ri-emotion-unhappy-line:before { content: "\ec96"; }
+.ri-empathize-fill:before { content: "\ec97"; }
+.ri-empathize-line:before { content: "\ec98"; }
+.ri-emphasis-cn:before { content: "\ec99"; }
+.ri-emphasis:before { content: "\ec9a"; }
+.ri-english-input:before { content: "\ec9b"; }
+.ri-equalizer-fill:before { content: "\ec9c"; }
+.ri-equalizer-line:before { content: "\ec9d"; }
+.ri-eraser-fill:before { content: "\ec9e"; }
+.ri-eraser-line:before { content: "\ec9f"; }
+.ri-error-warning-fill:before { content: "\eca0"; }
+.ri-error-warning-line:before { content: "\eca1"; }
+.ri-evernote-fill:before { content: "\eca2"; }
+.ri-evernote-line:before { content: "\eca3"; }
+.ri-exchange-box-fill:before { content: "\eca4"; }
+.ri-exchange-box-line:before { content: "\eca5"; }
+.ri-exchange-cny-fill:before { content: "\eca6"; }
+.ri-exchange-cny-line:before { content: "\eca7"; }
+.ri-exchange-dollar-fill:before { content: "\eca8"; }
+.ri-exchange-dollar-line:before { content: "\eca9"; }
+.ri-exchange-fill:before { content: "\ecaa"; }
+.ri-exchange-funds-fill:before { content: "\ecab"; }
+.ri-exchange-funds-line:before { content: "\ecac"; }
+.ri-exchange-line:before { content: "\ecad"; }
+.ri-external-link-fill:before { content: "\ecae"; }
+.ri-external-link-line:before { content: "\ecaf"; }
+.ri-eye-2-fill:before { content: "\ecb0"; }
+.ri-eye-2-line:before { content: "\ecb1"; }
+.ri-eye-close-fill:before { content: "\ecb2"; }
+.ri-eye-close-line:before { content: "\ecb3"; }
+.ri-eye-fill:before { content: "\ecb4"; }
+.ri-eye-line:before { content: "\ecb5"; }
+.ri-eye-off-fill:before { content: "\ecb6"; }
+.ri-eye-off-line:before { content: "\ecb7"; }
+.ri-facebook-box-fill:before { content: "\ecb8"; }
+.ri-facebook-box-line:before { content: "\ecb9"; }
+.ri-facebook-circle-fill:before { content: "\ecba"; }
+.ri-facebook-circle-line:before { content: "\ecbb"; }
+.ri-facebook-fill:before { content: "\ecbc"; }
+.ri-facebook-line:before { content: "\ecbd"; }
+.ri-fahrenheit-fill:before { content: "\ecbe"; }
+.ri-fahrenheit-line:before { content: "\ecbf"; }
+.ri-feedback-fill:before { content: "\ecc0"; }
+.ri-feedback-line:before { content: "\ecc1"; }
+.ri-file-2-fill:before { content: "\ecc2"; }
+.ri-file-2-line:before { content: "\ecc3"; }
+.ri-file-3-fill:before { content: "\ecc4"; }
+.ri-file-3-line:before { content: "\ecc5"; }
+.ri-file-4-fill:before { content: "\ecc6"; }
+.ri-file-4-line:before { content: "\ecc7"; }
+.ri-file-add-fill:before { content: "\ecc8"; }
+.ri-file-add-line:before { content: "\ecc9"; }
+.ri-file-chart-2-fill:before { content: "\ecca"; }
+.ri-file-chart-2-line:before { content: "\eccb"; }
+.ri-file-chart-fill:before { content: "\eccc"; }
+.ri-file-chart-line:before { content: "\eccd"; }
+.ri-file-cloud-fill:before { content: "\ecce"; }
+.ri-file-cloud-line:before { content: "\eccf"; }
+.ri-file-code-fill:before { content: "\ecd0"; }
+.ri-file-code-line:before { content: "\ecd1"; }
+.ri-file-copy-2-fill:before { content: "\ecd2"; }
+.ri-file-copy-2-line:before { content: "\ecd3"; }
+.ri-file-copy-fill:before { content: "\ecd4"; }
+.ri-file-copy-line:before { content: "\ecd5"; }
+.ri-file-damage-fill:before { content: "\ecd6"; }
+.ri-file-damage-line:before { content: "\ecd7"; }
+.ri-file-download-fill:before { content: "\ecd8"; }
+.ri-file-download-line:before { content: "\ecd9"; }
+.ri-file-edit-fill:before { content: "\ecda"; }
+.ri-file-edit-line:before { content: "\ecdb"; }
+.ri-file-excel-2-fill:before { content: "\ecdc"; }
+.ri-file-excel-2-line:before { content: "\ecdd"; }
+.ri-file-excel-fill:before { content: "\ecde"; }
+.ri-file-excel-line:before { content: "\ecdf"; }
+.ri-file-fill:before { content: "\ece0"; }
+.ri-file-forbid-fill:before { content: "\ece1"; }
+.ri-file-forbid-line:before { content: "\ece2"; }
+.ri-file-gif-fill:before { content: "\ece3"; }
+.ri-file-gif-line:before { content: "\ece4"; }
+.ri-file-history-fill:before { content: "\ece5"; }
+.ri-file-history-line:before { content: "\ece6"; }
+.ri-file-hwp-fill:before { content: "\ece7"; }
+.ri-file-hwp-line:before { content: "\ece8"; }
+.ri-file-info-fill:before { content: "\ece9"; }
+.ri-file-info-line:before { content: "\ecea"; }
+.ri-file-line:before { content: "\eceb"; }
+.ri-file-list-2-fill:before { content: "\ecec"; }
+.ri-file-list-2-line:before { content: "\eced"; }
+.ri-file-list-3-fill:before { content: "\ecee"; }
+.ri-file-list-3-line:before { content: "\ecef"; }
+.ri-file-list-fill:before { content: "\ecf0"; }
+.ri-file-list-line:before { content: "\ecf1"; }
+.ri-file-lock-fill:before { content: "\ecf2"; }
+.ri-file-lock-line:before { content: "\ecf3"; }
+.ri-file-marked-fill:before { content: "\ecf4"; }
+.ri-file-marked-line:before { content: "\ecf5"; }
+.ri-file-music-fill:before { content: "\ecf6"; }
+.ri-file-music-line:before { content: "\ecf7"; }
+.ri-file-paper-2-fill:before { content: "\ecf8"; }
+.ri-file-paper-2-line:before { content: "\ecf9"; }
+.ri-file-paper-fill:before { content: "\ecfa"; }
+.ri-file-paper-line:before { content: "\ecfb"; }
+.ri-file-pdf-fill:before { content: "\ecfc"; }
+.ri-file-pdf-line:before { content: "\ecfd"; }
+.ri-file-ppt-2-fill:before { content: "\ecfe"; }
+.ri-file-ppt-2-line:before { content: "\ecff"; }
+.ri-file-ppt-fill:before { content: "\ed00"; }
+.ri-file-ppt-line:before { content: "\ed01"; }
+.ri-file-reduce-fill:before { content: "\ed02"; }
+.ri-file-reduce-line:before { content: "\ed03"; }
+.ri-file-search-fill:before { content: "\ed04"; }
+.ri-file-search-line:before { content: "\ed05"; }
+.ri-file-settings-fill:before { content: "\ed06"; }
+.ri-file-settings-line:before { content: "\ed07"; }
+.ri-file-shield-2-fill:before { content: "\ed08"; }
+.ri-file-shield-2-line:before { content: "\ed09"; }
+.ri-file-shield-fill:before { content: "\ed0a"; }
+.ri-file-shield-line:before { content: "\ed0b"; }
+.ri-file-shred-fill:before { content: "\ed0c"; }
+.ri-file-shred-line:before { content: "\ed0d"; }
+.ri-file-text-fill:before { content: "\ed0e"; }
+.ri-file-text-line:before { content: "\ed0f"; }
+.ri-file-transfer-fill:before { content: "\ed10"; }
+.ri-file-transfer-line:before { content: "\ed11"; }
+.ri-file-unknow-fill:before { content: "\ed12"; }
+.ri-file-unknow-line:before { content: "\ed13"; }
+.ri-file-upload-fill:before { content: "\ed14"; }
+.ri-file-upload-line:before { content: "\ed15"; }
+.ri-file-user-fill:before { content: "\ed16"; }
+.ri-file-user-line:before { content: "\ed17"; }
+.ri-file-warning-fill:before { content: "\ed18"; }
+.ri-file-warning-line:before { content: "\ed19"; }
+.ri-file-word-2-fill:before { content: "\ed1a"; }
+.ri-file-word-2-line:before { content: "\ed1b"; }
+.ri-file-word-fill:before { content: "\ed1c"; }
+.ri-file-word-line:before { content: "\ed1d"; }
+.ri-file-zip-fill:before { content: "\ed1e"; }
+.ri-file-zip-line:before { content: "\ed1f"; }
+.ri-film-fill:before { content: "\ed20"; }
+.ri-film-line:before { content: "\ed21"; }
+.ri-filter-2-fill:before { content: "\ed22"; }
+.ri-filter-2-line:before { content: "\ed23"; }
+.ri-filter-3-fill:before { content: "\ed24"; }
+.ri-filter-3-line:before { content: "\ed25"; }
+.ri-filter-fill:before { content: "\ed26"; }
+.ri-filter-line:before { content: "\ed27"; }
+.ri-filter-off-fill:before { content: "\ed28"; }
+.ri-filter-off-line:before { content: "\ed29"; }
+.ri-find-replace-fill:before { content: "\ed2a"; }
+.ri-find-replace-line:before { content: "\ed2b"; }
+.ri-finder-fill:before { content: "\ed2c"; }
+.ri-finder-line:before { content: "\ed2d"; }
+.ri-fingerprint-2-fill:before { content: "\ed2e"; }
+.ri-fingerprint-2-line:before { content: "\ed2f"; }
+.ri-fingerprint-fill:before { content: "\ed30"; }
+.ri-fingerprint-line:before { content: "\ed31"; }
+.ri-fire-fill:before { content: "\ed32"; }
+.ri-fire-line:before { content: "\ed33"; }
+.ri-firefox-fill:before { content: "\ed34"; }
+.ri-firefox-line:before { content: "\ed35"; }
+.ri-first-aid-kit-fill:before { content: "\ed36"; }
+.ri-first-aid-kit-line:before { content: "\ed37"; }
+.ri-flag-2-fill:before { content: "\ed38"; }
+.ri-flag-2-line:before { content: "\ed39"; }
+.ri-flag-fill:before { content: "\ed3a"; }
+.ri-flag-line:before { content: "\ed3b"; }
+.ri-flashlight-fill:before { content: "\ed3c"; }
+.ri-flashlight-line:before { content: "\ed3d"; }
+.ri-flask-fill:before { content: "\ed3e"; }
+.ri-flask-line:before { content: "\ed3f"; }
+.ri-flight-land-fill:before { content: "\ed40"; }
+.ri-flight-land-line:before { content: "\ed41"; }
+.ri-flight-takeoff-fill:before { content: "\ed42"; }
+.ri-flight-takeoff-line:before { content: "\ed43"; }
+.ri-flood-fill:before { content: "\ed44"; }
+.ri-flood-line:before { content: "\ed45"; }
+.ri-flow-chart:before { content: "\ed46"; }
+.ri-flutter-fill:before { content: "\ed47"; }
+.ri-flutter-line:before { content: "\ed48"; }
+.ri-focus-2-fill:before { content: "\ed49"; }
+.ri-focus-2-line:before { content: "\ed4a"; }
+.ri-focus-3-fill:before { content: "\ed4b"; }
+.ri-focus-3-line:before { content: "\ed4c"; }
+.ri-focus-fill:before { content: "\ed4d"; }
+.ri-focus-line:before { content: "\ed4e"; }
+.ri-foggy-fill:before { content: "\ed4f"; }
+.ri-foggy-line:before { content: "\ed50"; }
+.ri-folder-2-fill:before { content: "\ed51"; }
+.ri-folder-2-line:before { content: "\ed52"; }
+.ri-folder-3-fill:before { content: "\ed53"; }
+.ri-folder-3-line:before { content: "\ed54"; }
+.ri-folder-4-fill:before { content: "\ed55"; }
+.ri-folder-4-line:before { content: "\ed56"; }
+.ri-folder-5-fill:before { content: "\ed57"; }
+.ri-folder-5-line:before { content: "\ed58"; }
+.ri-folder-add-fill:before { content: "\ed59"; }
+.ri-folder-add-line:before { content: "\ed5a"; }
+.ri-folder-chart-2-fill:before { content: "\ed5b"; }
+.ri-folder-chart-2-line:before { content: "\ed5c"; }
+.ri-folder-chart-fill:before { content: "\ed5d"; }
+.ri-folder-chart-line:before { content: "\ed5e"; }
+.ri-folder-download-fill:before { content: "\ed5f"; }
+.ri-folder-download-line:before { content: "\ed60"; }
+.ri-folder-fill:before { content: "\ed61"; }
+.ri-folder-forbid-fill:before { content: "\ed62"; }
+.ri-folder-forbid-line:before { content: "\ed63"; }
+.ri-folder-history-fill:before { content: "\ed64"; }
+.ri-folder-history-line:before { content: "\ed65"; }
+.ri-folder-info-fill:before { content: "\ed66"; }
+.ri-folder-info-line:before { content: "\ed67"; }
+.ri-folder-keyhole-fill:before { content: "\ed68"; }
+.ri-folder-keyhole-line:before { content: "\ed69"; }
+.ri-folder-line:before { content: "\ed6a"; }
+.ri-folder-lock-fill:before { content: "\ed6b"; }
+.ri-folder-lock-line:before { content: "\ed6c"; }
+.ri-folder-music-fill:before { content: "\ed6d"; }
+.ri-folder-music-line:before { content: "\ed6e"; }
+.ri-folder-open-fill:before { content: "\ed6f"; }
+.ri-folder-open-line:before { content: "\ed70"; }
+.ri-folder-received-fill:before { content: "\ed71"; }
+.ri-folder-received-line:before { content: "\ed72"; }
+.ri-folder-reduce-fill:before { content: "\ed73"; }
+.ri-folder-reduce-line:before { content: "\ed74"; }
+.ri-folder-settings-fill:before { content: "\ed75"; }
+.ri-folder-settings-line:before { content: "\ed76"; }
+.ri-folder-shared-fill:before { content: "\ed77"; }
+.ri-folder-shared-line:before { content: "\ed78"; }
+.ri-folder-shield-2-fill:before { content: "\ed79"; }
+.ri-folder-shield-2-line:before { content: "\ed7a"; }
+.ri-folder-shield-fill:before { content: "\ed7b"; }
+.ri-folder-shield-line:before { content: "\ed7c"; }
+.ri-folder-transfer-fill:before { content: "\ed7d"; }
+.ri-folder-transfer-line:before { content: "\ed7e"; }
+.ri-folder-unknow-fill:before { content: "\ed7f"; }
+.ri-folder-unknow-line:before { content: "\ed80"; }
+.ri-folder-upload-fill:before { content: "\ed81"; }
+.ri-folder-upload-line:before { content: "\ed82"; }
+.ri-folder-user-fill:before { content: "\ed83"; }
+.ri-folder-user-line:before { content: "\ed84"; }
+.ri-folder-warning-fill:before { content: "\ed85"; }
+.ri-folder-warning-line:before { content: "\ed86"; }
+.ri-folder-zip-fill:before { content: "\ed87"; }
+.ri-folder-zip-line:before { content: "\ed88"; }
+.ri-folders-fill:before { content: "\ed89"; }
+.ri-folders-line:before { content: "\ed8a"; }
+.ri-font-color:before { content: "\ed8b"; }
+.ri-font-size-2:before { content: "\ed8c"; }
+.ri-font-size:before { content: "\ed8d"; }
+.ri-football-fill:before { content: "\ed8e"; }
+.ri-football-line:before { content: "\ed8f"; }
+.ri-footprint-fill:before { content: "\ed90"; }
+.ri-footprint-line:before { content: "\ed91"; }
+.ri-forbid-2-fill:before { content: "\ed92"; }
+.ri-forbid-2-line:before { content: "\ed93"; }
+.ri-forbid-fill:before { content: "\ed94"; }
+.ri-forbid-line:before { content: "\ed95"; }
+.ri-format-clear:before { content: "\ed96"; }
+.ri-fridge-fill:before { content: "\ed97"; }
+.ri-fridge-line:before { content: "\ed98"; }
+.ri-fullscreen-exit-fill:before { content: "\ed99"; }
+.ri-fullscreen-exit-line:before { content: "\ed9a"; }
+.ri-fullscreen-fill:before { content: "\ed9b"; }
+.ri-fullscreen-line:before { content: "\ed9c"; }
+.ri-function-fill:before { content: "\ed9d"; }
+.ri-function-line:before { content: "\ed9e"; }
+.ri-functions:before { content: "\ed9f"; }
+.ri-funds-box-fill:before { content: "\eda0"; }
+.ri-funds-box-line:before { content: "\eda1"; }
+.ri-funds-fill:before { content: "\eda2"; }
+.ri-funds-line:before { content: "\eda3"; }
+.ri-gallery-fill:before { content: "\eda4"; }
+.ri-gallery-line:before { content: "\eda5"; }
+.ri-gallery-upload-fill:before { content: "\eda6"; }
+.ri-gallery-upload-line:before { content: "\eda7"; }
+.ri-game-fill:before { content: "\eda8"; }
+.ri-game-line:before { content: "\eda9"; }
+.ri-gamepad-fill:before { content: "\edaa"; }
+.ri-gamepad-line:before { content: "\edab"; }
+.ri-gas-station-fill:before { content: "\edac"; }
+.ri-gas-station-line:before { content: "\edad"; }
+.ri-gatsby-fill:before { content: "\edae"; }
+.ri-gatsby-line:before { content: "\edaf"; }
+.ri-genderless-fill:before { content: "\edb0"; }
+.ri-genderless-line:before { content: "\edb1"; }
+.ri-ghost-2-fill:before { content: "\edb2"; }
+.ri-ghost-2-line:before { content: "\edb3"; }
+.ri-ghost-fill:before { content: "\edb4"; }
+.ri-ghost-line:before { content: "\edb5"; }
+.ri-ghost-smile-fill:before { content: "\edb6"; }
+.ri-ghost-smile-line:before { content: "\edb7"; }
+.ri-gift-2-fill:before { content: "\edb8"; }
+.ri-gift-2-line:before { content: "\edb9"; }
+.ri-gift-fill:before { content: "\edba"; }
+.ri-gift-line:before { content: "\edbb"; }
+.ri-git-branch-fill:before { content: "\edbc"; }
+.ri-git-branch-line:before { content: "\edbd"; }
+.ri-git-commit-fill:before { content: "\edbe"; }
+.ri-git-commit-line:before { content: "\edbf"; }
+.ri-git-merge-fill:before { content: "\edc0"; }
+.ri-git-merge-line:before { content: "\edc1"; }
+.ri-git-pull-request-fill:before { content: "\edc2"; }
+.ri-git-pull-request-line:before { content: "\edc3"; }
+.ri-git-repository-commits-fill:before { content: "\edc4"; }
+.ri-git-repository-commits-line:before { content: "\edc5"; }
+.ri-git-repository-fill:before { content: "\edc6"; }
+.ri-git-repository-line:before { content: "\edc7"; }
+.ri-git-repository-private-fill:before { content: "\edc8"; }
+.ri-git-repository-private-line:before { content: "\edc9"; }
+.ri-github-fill:before { content: "\edca"; }
+.ri-github-line:before { content: "\edcb"; }
+.ri-gitlab-fill:before { content: "\edcc"; }
+.ri-gitlab-line:before { content: "\edcd"; }
+.ri-global-fill:before { content: "\edce"; }
+.ri-global-line:before { content: "\edcf"; }
+.ri-globe-fill:before { content: "\edd0"; }
+.ri-globe-line:before { content: "\edd1"; }
+.ri-goblet-fill:before { content: "\edd2"; }
+.ri-goblet-line:before { content: "\edd3"; }
+.ri-google-fill:before { content: "\edd4"; }
+.ri-google-line:before { content: "\edd5"; }
+.ri-google-play-fill:before { content: "\edd6"; }
+.ri-google-play-line:before { content: "\edd7"; }
+.ri-government-fill:before { content: "\edd8"; }
+.ri-government-line:before { content: "\edd9"; }
+.ri-gps-fill:before { content: "\edda"; }
+.ri-gps-line:before { content: "\eddb"; }
+.ri-gradienter-fill:before { content: "\eddc"; }
+.ri-gradienter-line:before { content: "\eddd"; }
+.ri-grid-fill:before { content: "\edde"; }
+.ri-grid-line:before { content: "\eddf"; }
+.ri-group-2-fill:before { content: "\ede0"; }
+.ri-group-2-line:before { content: "\ede1"; }
+.ri-group-fill:before { content: "\ede2"; }
+.ri-group-line:before { content: "\ede3"; }
+.ri-guide-fill:before { content: "\ede4"; }
+.ri-guide-line:before { content: "\ede5"; }
+.ri-h-1:before { content: "\ede6"; }
+.ri-h-2:before { content: "\ede7"; }
+.ri-h-3:before { content: "\ede8"; }
+.ri-h-4:before { content: "\ede9"; }
+.ri-h-5:before { content: "\edea"; }
+.ri-h-6:before { content: "\edeb"; }
+.ri-hail-fill:before { content: "\edec"; }
+.ri-hail-line:before { content: "\eded"; }
+.ri-hammer-fill:before { content: "\edee"; }
+.ri-hammer-line:before { content: "\edef"; }
+.ri-hand-coin-fill:before { content: "\edf0"; }
+.ri-hand-coin-line:before { content: "\edf1"; }
+.ri-hand-heart-fill:before { content: "\edf2"; }
+.ri-hand-heart-line:before { content: "\edf3"; }
+.ri-hand-sanitizer-fill:before { content: "\edf4"; }
+.ri-hand-sanitizer-line:before { content: "\edf5"; }
+.ri-handbag-fill:before { content: "\edf6"; }
+.ri-handbag-line:before { content: "\edf7"; }
+.ri-hard-drive-2-fill:before { content: "\edf8"; }
+.ri-hard-drive-2-line:before { content: "\edf9"; }
+.ri-hard-drive-fill:before { content: "\edfa"; }
+.ri-hard-drive-line:before { content: "\edfb"; }
+.ri-hashtag:before { content: "\edfc"; }
+.ri-haze-2-fill:before { content: "\edfd"; }
+.ri-haze-2-line:before { content: "\edfe"; }
+.ri-haze-fill:before { content: "\edff"; }
+.ri-haze-line:before { content: "\ee00"; }
+.ri-hd-fill:before { content: "\ee01"; }
+.ri-hd-line:before { content: "\ee02"; }
+.ri-heading:before { content: "\ee03"; }
+.ri-headphone-fill:before { content: "\ee04"; }
+.ri-headphone-line:before { content: "\ee05"; }
+.ri-health-book-fill:before { content: "\ee06"; }
+.ri-health-book-line:before { content: "\ee07"; }
+.ri-heart-2-fill:before { content: "\ee08"; }
+.ri-heart-2-line:before { content: "\ee09"; }
+.ri-heart-3-fill:before { content: "\ee0a"; }
+.ri-heart-3-line:before { content: "\ee0b"; }
+.ri-heart-add-fill:before { content: "\ee0c"; }
+.ri-heart-add-line:before { content: "\ee0d"; }
+.ri-heart-fill:before { content: "\ee0e"; }
+.ri-heart-line:before { content: "\ee0f"; }
+.ri-heart-pulse-fill:before { content: "\ee10"; }
+.ri-heart-pulse-line:before { content: "\ee11"; }
+.ri-hearts-fill:before { content: "\ee12"; }
+.ri-hearts-line:before { content: "\ee13"; }
+.ri-heavy-showers-fill:before { content: "\ee14"; }
+.ri-heavy-showers-line:before { content: "\ee15"; }
+.ri-history-fill:before { content: "\ee16"; }
+.ri-history-line:before { content: "\ee17"; }
+.ri-home-2-fill:before { content: "\ee18"; }
+.ri-home-2-line:before { content: "\ee19"; }
+.ri-home-3-fill:before { content: "\ee1a"; }
+.ri-home-3-line:before { content: "\ee1b"; }
+.ri-home-4-fill:before { content: "\ee1c"; }
+.ri-home-4-line:before { content: "\ee1d"; }
+.ri-home-5-fill:before { content: "\ee1e"; }
+.ri-home-5-line:before { content: "\ee1f"; }
+.ri-home-6-fill:before { content: "\ee20"; }
+.ri-home-6-line:before { content: "\ee21"; }
+.ri-home-7-fill:before { content: "\ee22"; }
+.ri-home-7-line:before { content: "\ee23"; }
+.ri-home-8-fill:before { content: "\ee24"; }
+.ri-home-8-line:before { content: "\ee25"; }
+.ri-home-fill:before { content: "\ee26"; }
+.ri-home-gear-fill:before { content: "\ee27"; }
+.ri-home-gear-line:before { content: "\ee28"; }
+.ri-home-heart-fill:before { content: "\ee29"; }
+.ri-home-heart-line:before { content: "\ee2a"; }
+.ri-home-line:before { content: "\ee2b"; }
+.ri-home-smile-2-fill:before { content: "\ee2c"; }
+.ri-home-smile-2-line:before { content: "\ee2d"; }
+.ri-home-smile-fill:before { content: "\ee2e"; }
+.ri-home-smile-line:before { content: "\ee2f"; }
+.ri-home-wifi-fill:before { content: "\ee30"; }
+.ri-home-wifi-line:before { content: "\ee31"; }
+.ri-honor-of-kings-fill:before { content: "\ee32"; }
+.ri-honor-of-kings-line:before { content: "\ee33"; }
+.ri-honour-fill:before { content: "\ee34"; }
+.ri-honour-line:before { content: "\ee35"; }
+.ri-hospital-fill:before { content: "\ee36"; }
+.ri-hospital-line:before { content: "\ee37"; }
+.ri-hotel-bed-fill:before { content: "\ee38"; }
+.ri-hotel-bed-line:before { content: "\ee39"; }
+.ri-hotel-fill:before { content: "\ee3a"; }
+.ri-hotel-line:before { content: "\ee3b"; }
+.ri-hotspot-fill:before { content: "\ee3c"; }
+.ri-hotspot-line:before { content: "\ee3d"; }
+.ri-hq-fill:before { content: "\ee3e"; }
+.ri-hq-line:before { content: "\ee3f"; }
+.ri-html5-fill:before { content: "\ee40"; }
+.ri-html5-line:before { content: "\ee41"; }
+.ri-ie-fill:before { content: "\ee42"; }
+.ri-ie-line:before { content: "\ee43"; }
+.ri-image-2-fill:before { content: "\ee44"; }
+.ri-image-2-line:before { content: "\ee45"; }
+.ri-image-add-fill:before { content: "\ee46"; }
+.ri-image-add-line:before { content: "\ee47"; }
+.ri-image-edit-fill:before { content: "\ee48"; }
+.ri-image-edit-line:before { content: "\ee49"; }
+.ri-image-fill:before { content: "\ee4a"; }
+.ri-image-line:before { content: "\ee4b"; }
+.ri-inbox-archive-fill:before { content: "\ee4c"; }
+.ri-inbox-archive-line:before { content: "\ee4d"; }
+.ri-inbox-fill:before { content: "\ee4e"; }
+.ri-inbox-line:before { content: "\ee4f"; }
+.ri-inbox-unarchive-fill:before { content: "\ee50"; }
+.ri-inbox-unarchive-line:before { content: "\ee51"; }
+.ri-increase-decrease-fill:before { content: "\ee52"; }
+.ri-increase-decrease-line:before { content: "\ee53"; }
+.ri-indent-decrease:before { content: "\ee54"; }
+.ri-indent-increase:before { content: "\ee55"; }
+.ri-indeterminate-circle-fill:before { content: "\ee56"; }
+.ri-indeterminate-circle-line:before { content: "\ee57"; }
+.ri-information-fill:before { content: "\ee58"; }
+.ri-information-line:before { content: "\ee59"; }
+.ri-infrared-thermometer-fill:before { content: "\ee5a"; }
+.ri-infrared-thermometer-line:before { content: "\ee5b"; }
+.ri-ink-bottle-fill:before { content: "\ee5c"; }
+.ri-ink-bottle-line:before { content: "\ee5d"; }
+.ri-input-cursor-move:before { content: "\ee5e"; }
+.ri-input-method-fill:before { content: "\ee5f"; }
+.ri-input-method-line:before { content: "\ee60"; }
+.ri-insert-column-left:before { content: "\ee61"; }
+.ri-insert-column-right:before { content: "\ee62"; }
+.ri-insert-row-bottom:before { content: "\ee63"; }
+.ri-insert-row-top:before { content: "\ee64"; }
+.ri-instagram-fill:before { content: "\ee65"; }
+.ri-instagram-line:before { content: "\ee66"; }
+.ri-install-fill:before { content: "\ee67"; }
+.ri-install-line:before { content: "\ee68"; }
+.ri-invision-fill:before { content: "\ee69"; }
+.ri-invision-line:before { content: "\ee6a"; }
+.ri-italic:before { content: "\ee6b"; }
+.ri-kakao-talk-fill:before { content: "\ee6c"; }
+.ri-kakao-talk-line:before { content: "\ee6d"; }
+.ri-key-2-fill:before { content: "\ee6e"; }
+.ri-key-2-line:before { content: "\ee6f"; }
+.ri-key-fill:before { content: "\ee70"; }
+.ri-key-line:before { content: "\ee71"; }
+.ri-keyboard-box-fill:before { content: "\ee72"; }
+.ri-keyboard-box-line:before { content: "\ee73"; }
+.ri-keyboard-fill:before { content: "\ee74"; }
+.ri-keyboard-line:before { content: "\ee75"; }
+.ri-keynote-fill:before { content: "\ee76"; }
+.ri-keynote-line:before { content: "\ee77"; }
+.ri-knife-blood-fill:before { content: "\ee78"; }
+.ri-knife-blood-line:before { content: "\ee79"; }
+.ri-knife-fill:before { content: "\ee7a"; }
+.ri-knife-line:before { content: "\ee7b"; }
+.ri-landscape-fill:before { content: "\ee7c"; }
+.ri-landscape-line:before { content: "\ee7d"; }
+.ri-layout-2-fill:before { content: "\ee7e"; }
+.ri-layout-2-line:before { content: "\ee7f"; }
+.ri-layout-3-fill:before { content: "\ee80"; }
+.ri-layout-3-line:before { content: "\ee81"; }
+.ri-layout-4-fill:before { content: "\ee82"; }
+.ri-layout-4-line:before { content: "\ee83"; }
+.ri-layout-5-fill:before { content: "\ee84"; }
+.ri-layout-5-line:before { content: "\ee85"; }
+.ri-layout-6-fill:before { content: "\ee86"; }
+.ri-layout-6-line:before { content: "\ee87"; }
+.ri-layout-bottom-2-fill:before { content: "\ee88"; }
+.ri-layout-bottom-2-line:before { content: "\ee89"; }
+.ri-layout-bottom-fill:before { content: "\ee8a"; }
+.ri-layout-bottom-line:before { content: "\ee8b"; }
+.ri-layout-column-fill:before { content: "\ee8c"; }
+.ri-layout-column-line:before { content: "\ee8d"; }
+.ri-layout-fill:before { content: "\ee8e"; }
+.ri-layout-grid-fill:before { content: "\ee8f"; }
+.ri-layout-grid-line:before { content: "\ee90"; }
+.ri-layout-left-2-fill:before { content: "\ee91"; }
+.ri-layout-left-2-line:before { content: "\ee92"; }
+.ri-layout-left-fill:before { content: "\ee93"; }
+.ri-layout-left-line:before { content: "\ee94"; }
+.ri-layout-line:before { content: "\ee95"; }
+.ri-layout-masonry-fill:before { content: "\ee96"; }
+.ri-layout-masonry-line:before { content: "\ee97"; }
+.ri-layout-right-2-fill:before { content: "\ee98"; }
+.ri-layout-right-2-line:before { content: "\ee99"; }
+.ri-layout-right-fill:before { content: "\ee9a"; }
+.ri-layout-right-line:before { content: "\ee9b"; }
+.ri-layout-row-fill:before { content: "\ee9c"; }
+.ri-layout-row-line:before { content: "\ee9d"; }
+.ri-layout-top-2-fill:before { content: "\ee9e"; }
+.ri-layout-top-2-line:before { content: "\ee9f"; }
+.ri-layout-top-fill:before { content: "\eea0"; }
+.ri-layout-top-line:before { content: "\eea1"; }
+.ri-leaf-fill:before { content: "\eea2"; }
+.ri-leaf-line:before { content: "\eea3"; }
+.ri-lifebuoy-fill:before { content: "\eea4"; }
+.ri-lifebuoy-line:before { content: "\eea5"; }
+.ri-lightbulb-fill:before { content: "\eea6"; }
+.ri-lightbulb-flash-fill:before { content: "\eea7"; }
+.ri-lightbulb-flash-line:before { content: "\eea8"; }
+.ri-lightbulb-line:before { content: "\eea9"; }
+.ri-line-chart-fill:before { content: "\eeaa"; }
+.ri-line-chart-line:before { content: "\eeab"; }
+.ri-line-fill:before { content: "\eeac"; }
+.ri-line-height:before { content: "\eead"; }
+.ri-line-line:before { content: "\eeae"; }
+.ri-link-m:before { content: "\eeaf"; }
+.ri-link-unlink-m:before { content: "\eeb0"; }
+.ri-link-unlink:before { content: "\eeb1"; }
+.ri-link:before { content: "\eeb2"; }
+.ri-linkedin-box-fill:before { content: "\eeb3"; }
+.ri-linkedin-box-line:before { content: "\eeb4"; }
+.ri-linkedin-fill:before { content: "\eeb5"; }
+.ri-linkedin-line:before { content: "\eeb6"; }
+.ri-links-fill:before { content: "\eeb7"; }
+.ri-links-line:before { content: "\eeb8"; }
+.ri-list-check-2:before { content: "\eeb9"; }
+.ri-list-check:before { content: "\eeba"; }
+.ri-list-ordered:before { content: "\eebb"; }
+.ri-list-settings-fill:before { content: "\eebc"; }
+.ri-list-settings-line:before { content: "\eebd"; }
+.ri-list-unordered:before { content: "\eebe"; }
+.ri-live-fill:before { content: "\eebf"; }
+.ri-live-line:before { content: "\eec0"; }
+.ri-loader-2-fill:before { content: "\eec1"; }
+.ri-loader-2-line:before { content: "\eec2"; }
+.ri-loader-3-fill:before { content: "\eec3"; }
+.ri-loader-3-line:before { content: "\eec4"; }
+.ri-loader-4-fill:before { content: "\eec5"; }
+.ri-loader-4-line:before { content: "\eec6"; }
+.ri-loader-5-fill:before { content: "\eec7"; }
+.ri-loader-5-line:before { content: "\eec8"; }
+.ri-loader-fill:before { content: "\eec9"; }
+.ri-loader-line:before { content: "\eeca"; }
+.ri-lock-2-fill:before { content: "\eecb"; }
+.ri-lock-2-line:before { content: "\eecc"; }
+.ri-lock-fill:before { content: "\eecd"; }
+.ri-lock-line:before { content: "\eece"; }
+.ri-lock-password-fill:before { content: "\eecf"; }
+.ri-lock-password-line:before { content: "\eed0"; }
+.ri-lock-unlock-fill:before { content: "\eed1"; }
+.ri-lock-unlock-line:before { content: "\eed2"; }
+.ri-login-box-fill:before { content: "\eed3"; }
+.ri-login-box-line:before { content: "\eed4"; }
+.ri-login-circle-fill:before { content: "\eed5"; }
+.ri-login-circle-line:before { content: "\eed6"; }
+.ri-logout-box-fill:before { content: "\eed7"; }
+.ri-logout-box-line:before { content: "\eed8"; }
+.ri-logout-box-r-fill:before { content: "\eed9"; }
+.ri-logout-box-r-line:before { content: "\eeda"; }
+.ri-logout-circle-fill:before { content: "\eedb"; }
+.ri-logout-circle-line:before { content: "\eedc"; }
+.ri-logout-circle-r-fill:before { content: "\eedd"; }
+.ri-logout-circle-r-line:before { content: "\eede"; }
+.ri-luggage-cart-fill:before { content: "\eedf"; }
+.ri-luggage-cart-line:before { content: "\eee0"; }
+.ri-luggage-deposit-fill:before { content: "\eee1"; }
+.ri-luggage-deposit-line:before { content: "\eee2"; }
+.ri-lungs-fill:before { content: "\eee3"; }
+.ri-lungs-line:before { content: "\eee4"; }
+.ri-mac-fill:before { content: "\eee5"; }
+.ri-mac-line:before { content: "\eee6"; }
+.ri-macbook-fill:before { content: "\eee7"; }
+.ri-macbook-line:before { content: "\eee8"; }
+.ri-magic-fill:before { content: "\eee9"; }
+.ri-magic-line:before { content: "\eeea"; }
+.ri-mail-add-fill:before { content: "\eeeb"; }
+.ri-mail-add-line:before { content: "\eeec"; }
+.ri-mail-check-fill:before { content: "\eeed"; }
+.ri-mail-check-line:before { content: "\eeee"; }
+.ri-mail-close-fill:before { content: "\eeef"; }
+.ri-mail-close-line:before { content: "\eef0"; }
+.ri-mail-download-fill:before { content: "\eef1"; }
+.ri-mail-download-line:before { content: "\eef2"; }
+.ri-mail-fill:before { content: "\eef3"; }
+.ri-mail-forbid-fill:before { content: "\eef4"; }
+.ri-mail-forbid-line:before { content: "\eef5"; }
+.ri-mail-line:before { content: "\eef6"; }
+.ri-mail-lock-fill:before { content: "\eef7"; }
+.ri-mail-lock-line:before { content: "\eef8"; }
+.ri-mail-open-fill:before { content: "\eef9"; }
+.ri-mail-open-line:before { content: "\eefa"; }
+.ri-mail-send-fill:before { content: "\eefb"; }
+.ri-mail-send-line:before { content: "\eefc"; }
+.ri-mail-settings-fill:before { content: "\eefd"; }
+.ri-mail-settings-line:before { content: "\eefe"; }
+.ri-mail-star-fill:before { content: "\eeff"; }
+.ri-mail-star-line:before { content: "\ef00"; }
+.ri-mail-unread-fill:before { content: "\ef01"; }
+.ri-mail-unread-line:before { content: "\ef02"; }
+.ri-mail-volume-fill:before { content: "\ef03"; }
+.ri-mail-volume-line:before { content: "\ef04"; }
+.ri-map-2-fill:before { content: "\ef05"; }
+.ri-map-2-line:before { content: "\ef06"; }
+.ri-map-fill:before { content: "\ef07"; }
+.ri-map-line:before { content: "\ef08"; }
+.ri-map-pin-2-fill:before { content: "\ef09"; }
+.ri-map-pin-2-line:before { content: "\ef0a"; }
+.ri-map-pin-3-fill:before { content: "\ef0b"; }
+.ri-map-pin-3-line:before { content: "\ef0c"; }
+.ri-map-pin-4-fill:before { content: "\ef0d"; }
+.ri-map-pin-4-line:before { content: "\ef0e"; }
+.ri-map-pin-5-fill:before { content: "\ef0f"; }
+.ri-map-pin-5-line:before { content: "\ef10"; }
+.ri-map-pin-add-fill:before { content: "\ef11"; }
+.ri-map-pin-add-line:before { content: "\ef12"; }
+.ri-map-pin-fill:before { content: "\ef13"; }
+.ri-map-pin-line:before { content: "\ef14"; }
+.ri-map-pin-range-fill:before { content: "\ef15"; }
+.ri-map-pin-range-line:before { content: "\ef16"; }
+.ri-map-pin-time-fill:before { content: "\ef17"; }
+.ri-map-pin-time-line:before { content: "\ef18"; }
+.ri-map-pin-user-fill:before { content: "\ef19"; }
+.ri-map-pin-user-line:before { content: "\ef1a"; }
+.ri-mark-pen-fill:before { content: "\ef1b"; }
+.ri-mark-pen-line:before { content: "\ef1c"; }
+.ri-markdown-fill:before { content: "\ef1d"; }
+.ri-markdown-line:before { content: "\ef1e"; }
+.ri-markup-fill:before { content: "\ef1f"; }
+.ri-markup-line:before { content: "\ef20"; }
+.ri-mastercard-fill:before { content: "\ef21"; }
+.ri-mastercard-line:before { content: "\ef22"; }
+.ri-mastodon-fill:before { content: "\ef23"; }
+.ri-mastodon-line:before { content: "\ef24"; }
+.ri-medal-2-fill:before { content: "\ef25"; }
+.ri-medal-2-line:before { content: "\ef26"; }
+.ri-medal-fill:before { content: "\ef27"; }
+.ri-medal-line:before { content: "\ef28"; }
+.ri-medicine-bottle-fill:before { content: "\ef29"; }
+.ri-medicine-bottle-line:before { content: "\ef2a"; }
+.ri-medium-fill:before { content: "\ef2b"; }
+.ri-medium-line:before { content: "\ef2c"; }
+.ri-men-fill:before { content: "\ef2d"; }
+.ri-men-line:before { content: "\ef2e"; }
+.ri-mental-health-fill:before { content: "\ef2f"; }
+.ri-mental-health-line:before { content: "\ef30"; }
+.ri-menu-2-fill:before { content: "\ef31"; }
+.ri-menu-2-line:before { content: "\ef32"; }
+.ri-menu-3-fill:before { content: "\ef33"; }
+.ri-menu-3-line:before { content: "\ef34"; }
+.ri-menu-4-fill:before { content: "\ef35"; }
+.ri-menu-4-line:before { content: "\ef36"; }
+.ri-menu-5-fill:before { content: "\ef37"; }
+.ri-menu-5-line:before { content: "\ef38"; }
+.ri-menu-add-fill:before { content: "\ef39"; }
+.ri-menu-add-line:before { content: "\ef3a"; }
+.ri-menu-fill:before { content: "\ef3b"; }
+.ri-menu-fold-fill:before { content: "\ef3c"; }
+.ri-menu-fold-line:before { content: "\ef3d"; }
+.ri-menu-line:before { content: "\ef3e"; }
+.ri-menu-unfold-fill:before { content: "\ef3f"; }
+.ri-menu-unfold-line:before { content: "\ef40"; }
+.ri-merge-cells-horizontal:before { content: "\ef41"; }
+.ri-merge-cells-vertical:before { content: "\ef42"; }
+.ri-message-2-fill:before { content: "\ef43"; }
+.ri-message-2-line:before { content: "\ef44"; }
+.ri-message-3-fill:before { content: "\ef45"; }
+.ri-message-3-line:before { content: "\ef46"; }
+.ri-message-fill:before { content: "\ef47"; }
+.ri-message-line:before { content: "\ef48"; }
+.ri-messenger-fill:before { content: "\ef49"; }
+.ri-messenger-line:before { content: "\ef4a"; }
+.ri-meteor-fill:before { content: "\ef4b"; }
+.ri-meteor-line:before { content: "\ef4c"; }
+.ri-mic-2-fill:before { content: "\ef4d"; }
+.ri-mic-2-line:before { content: "\ef4e"; }
+.ri-mic-fill:before { content: "\ef4f"; }
+.ri-mic-line:before { content: "\ef50"; }
+.ri-mic-off-fill:before { content: "\ef51"; }
+.ri-mic-off-line:before { content: "\ef52"; }
+.ri-mickey-fill:before { content: "\ef53"; }
+.ri-mickey-line:before { content: "\ef54"; }
+.ri-microscope-fill:before { content: "\ef55"; }
+.ri-microscope-line:before { content: "\ef56"; }
+.ri-microsoft-fill:before { content: "\ef57"; }
+.ri-microsoft-line:before { content: "\ef58"; }
+.ri-mind-map:before { content: "\ef59"; }
+.ri-mini-program-fill:before { content: "\ef5a"; }
+.ri-mini-program-line:before { content: "\ef5b"; }
+.ri-mist-fill:before { content: "\ef5c"; }
+.ri-mist-line:before { content: "\ef5d"; }
+.ri-money-cny-box-fill:before { content: "\ef5e"; }
+.ri-money-cny-box-line:before { content: "\ef5f"; }
+.ri-money-cny-circle-fill:before { content: "\ef60"; }
+.ri-money-cny-circle-line:before { content: "\ef61"; }
+.ri-money-dollar-box-fill:before { content: "\ef62"; }
+.ri-money-dollar-box-line:before { content: "\ef63"; }
+.ri-money-dollar-circle-fill:before { content: "\ef64"; }
+.ri-money-dollar-circle-line:before { content: "\ef65"; }
+.ri-money-euro-box-fill:before { content: "\ef66"; }
+.ri-money-euro-box-line:before { content: "\ef67"; }
+.ri-money-euro-circle-fill:before { content: "\ef68"; }
+.ri-money-euro-circle-line:before { content: "\ef69"; }
+.ri-money-pound-box-fill:before { content: "\ef6a"; }
+.ri-money-pound-box-line:before { content: "\ef6b"; }
+.ri-money-pound-circle-fill:before { content: "\ef6c"; }
+.ri-money-pound-circle-line:before { content: "\ef6d"; }
+.ri-moon-clear-fill:before { content: "\ef6e"; }
+.ri-moon-clear-line:before { content: "\ef6f"; }
+.ri-moon-cloudy-fill:before { content: "\ef70"; }
+.ri-moon-cloudy-line:before { content: "\ef71"; }
+.ri-moon-fill:before { content: "\ef72"; }
+.ri-moon-foggy-fill:before { content: "\ef73"; }
+.ri-moon-foggy-line:before { content: "\ef74"; }
+.ri-moon-line:before { content: "\ef75"; }
+.ri-more-2-fill:before { content: "\ef76"; }
+.ri-more-2-line:before { content: "\ef77"; }
+.ri-more-fill:before { content: "\ef78"; }
+.ri-more-line:before { content: "\ef79"; }
+.ri-motorbike-fill:before { content: "\ef7a"; }
+.ri-motorbike-line:before { content: "\ef7b"; }
+.ri-mouse-fill:before { content: "\ef7c"; }
+.ri-mouse-line:before { content: "\ef7d"; }
+.ri-movie-2-fill:before { content: "\ef7e"; }
+.ri-movie-2-line:before { content: "\ef7f"; }
+.ri-movie-fill:before { content: "\ef80"; }
+.ri-movie-line:before { content: "\ef81"; }
+.ri-music-2-fill:before { content: "\ef82"; }
+.ri-music-2-line:before { content: "\ef83"; }
+.ri-music-fill:before { content: "\ef84"; }
+.ri-music-line:before { content: "\ef85"; }
+.ri-mv-fill:before { content: "\ef86"; }
+.ri-mv-line:before { content: "\ef87"; }
+.ri-navigation-fill:before { content: "\ef88"; }
+.ri-navigation-line:before { content: "\ef89"; }
+.ri-netease-cloud-music-fill:before { content: "\ef8a"; }
+.ri-netease-cloud-music-line:before { content: "\ef8b"; }
+.ri-netflix-fill:before { content: "\ef8c"; }
+.ri-netflix-line:before { content: "\ef8d"; }
+.ri-newspaper-fill:before { content: "\ef8e"; }
+.ri-newspaper-line:before { content: "\ef8f"; }
+.ri-node-tree:before { content: "\ef90"; }
+.ri-notification-2-fill:before { content: "\ef91"; }
+.ri-notification-2-line:before { content: "\ef92"; }
+.ri-notification-3-fill:before { content: "\ef93"; }
+.ri-notification-3-line:before { content: "\ef94"; }
+.ri-notification-4-fill:before { content: "\ef95"; }
+.ri-notification-4-line:before { content: "\ef96"; }
+.ri-notification-badge-fill:before { content: "\ef97"; }
+.ri-notification-badge-line:before { content: "\ef98"; }
+.ri-notification-fill:before { content: "\ef99"; }
+.ri-notification-line:before { content: "\ef9a"; }
+.ri-notification-off-fill:before { content: "\ef9b"; }
+.ri-notification-off-line:before { content: "\ef9c"; }
+.ri-npmjs-fill:before { content: "\ef9d"; }
+.ri-npmjs-line:before { content: "\ef9e"; }
+.ri-number-0:before { content: "\ef9f"; }
+.ri-number-1:before { content: "\efa0"; }
+.ri-number-2:before { content: "\efa1"; }
+.ri-number-3:before { content: "\efa2"; }
+.ri-number-4:before { content: "\efa3"; }
+.ri-number-5:before { content: "\efa4"; }
+.ri-number-6:before { content: "\efa5"; }
+.ri-number-7:before { content: "\efa6"; }
+.ri-number-8:before { content: "\efa7"; }
+.ri-number-9:before { content: "\efa8"; }
+.ri-numbers-fill:before { content: "\efa9"; }
+.ri-numbers-line:before { content: "\efaa"; }
+.ri-nurse-fill:before { content: "\efab"; }
+.ri-nurse-line:before { content: "\efac"; }
+.ri-oil-fill:before { content: "\efad"; }
+.ri-oil-line:before { content: "\efae"; }
+.ri-omega:before { content: "\efaf"; }
+.ri-open-arm-fill:before { content: "\efb0"; }
+.ri-open-arm-line:before { content: "\efb1"; }
+.ri-open-source-fill:before { content: "\efb2"; }
+.ri-open-source-line:before { content: "\efb3"; }
+.ri-opera-fill:before { content: "\efb4"; }
+.ri-opera-line:before { content: "\efb5"; }
+.ri-order-play-fill:before { content: "\efb6"; }
+.ri-order-play-line:before { content: "\efb7"; }
+.ri-organization-chart:before { content: "\efb8"; }
+.ri-outlet-2-fill:before { content: "\efb9"; }
+.ri-outlet-2-line:before { content: "\efba"; }
+.ri-outlet-fill:before { content: "\efbb"; }
+.ri-outlet-line:before { content: "\efbc"; }
+.ri-page-separator:before { content: "\efbd"; }
+.ri-pages-fill:before { content: "\efbe"; }
+.ri-pages-line:before { content: "\efbf"; }
+.ri-paint-brush-fill:before { content: "\efc0"; }
+.ri-paint-brush-line:before { content: "\efc1"; }
+.ri-paint-fill:before { content: "\efc2"; }
+.ri-paint-line:before { content: "\efc3"; }
+.ri-palette-fill:before { content: "\efc4"; }
+.ri-palette-line:before { content: "\efc5"; }
+.ri-pantone-fill:before { content: "\efc6"; }
+.ri-pantone-line:before { content: "\efc7"; }
+.ri-paragraph:before { content: "\efc8"; }
+.ri-parent-fill:before { content: "\efc9"; }
+.ri-parent-line:before { content: "\efca"; }
+.ri-parentheses-fill:before { content: "\efcb"; }
+.ri-parentheses-line:before { content: "\efcc"; }
+.ri-parking-box-fill:before { content: "\efcd"; }
+.ri-parking-box-line:before { content: "\efce"; }
+.ri-parking-fill:before { content: "\efcf"; }
+.ri-parking-line:before { content: "\efd0"; }
+.ri-passport-fill:before { content: "\efd1"; }
+.ri-passport-line:before { content: "\efd2"; }
+.ri-patreon-fill:before { content: "\efd3"; }
+.ri-patreon-line:before { content: "\efd4"; }
+.ri-pause-circle-fill:before { content: "\efd5"; }
+.ri-pause-circle-line:before { content: "\efd6"; }
+.ri-pause-fill:before { content: "\efd7"; }
+.ri-pause-line:before { content: "\efd8"; }
+.ri-pause-mini-fill:before { content: "\efd9"; }
+.ri-pause-mini-line:before { content: "\efda"; }
+.ri-paypal-fill:before { content: "\efdb"; }
+.ri-paypal-line:before { content: "\efdc"; }
+.ri-pen-nib-fill:before { content: "\efdd"; }
+.ri-pen-nib-line:before { content: "\efde"; }
+.ri-pencil-fill:before { content: "\efdf"; }
+.ri-pencil-line:before { content: "\efe0"; }
+.ri-pencil-ruler-2-fill:before { content: "\efe1"; }
+.ri-pencil-ruler-2-line:before { content: "\efe2"; }
+.ri-pencil-ruler-fill:before { content: "\efe3"; }
+.ri-pencil-ruler-line:before { content: "\efe4"; }
+.ri-percent-fill:before { content: "\efe5"; }
+.ri-percent-line:before { content: "\efe6"; }
+.ri-phone-camera-fill:before { content: "\efe7"; }
+.ri-phone-camera-line:before { content: "\efe8"; }
+.ri-phone-fill:before { content: "\efe9"; }
+.ri-phone-find-fill:before { content: "\efea"; }
+.ri-phone-find-line:before { content: "\efeb"; }
+.ri-phone-line:before { content: "\efec"; }
+.ri-phone-lock-fill:before { content: "\efed"; }
+.ri-phone-lock-line:before { content: "\efee"; }
+.ri-picture-in-picture-2-fill:before { content: "\efef"; }
+.ri-picture-in-picture-2-line:before { content: "\eff0"; }
+.ri-picture-in-picture-exit-fill:before { content: "\eff1"; }
+.ri-picture-in-picture-exit-line:before { content: "\eff2"; }
+.ri-picture-in-picture-fill:before { content: "\eff3"; }
+.ri-picture-in-picture-line:before { content: "\eff4"; }
+.ri-pie-chart-2-fill:before { content: "\eff5"; }
+.ri-pie-chart-2-line:before { content: "\eff6"; }
+.ri-pie-chart-box-fill:before { content: "\eff7"; }
+.ri-pie-chart-box-line:before { content: "\eff8"; }
+.ri-pie-chart-fill:before { content: "\eff9"; }
+.ri-pie-chart-line:before { content: "\effa"; }
+.ri-pin-distance-fill:before { content: "\effb"; }
+.ri-pin-distance-line:before { content: "\effc"; }
+.ri-ping-pong-fill:before { content: "\effd"; }
+.ri-ping-pong-line:before { content: "\effe"; }
+.ri-pinterest-fill:before { content: "\efff"; }
+.ri-pinterest-line:before { content: "\f000"; }
+.ri-pinyin-input:before { content: "\f001"; }
+.ri-pixelfed-fill:before { content: "\f002"; }
+.ri-pixelfed-line:before { content: "\f003"; }
+.ri-plane-fill:before { content: "\f004"; }
+.ri-plane-line:before { content: "\f005"; }
+.ri-plant-fill:before { content: "\f006"; }
+.ri-plant-line:before { content: "\f007"; }
+.ri-play-circle-fill:before { content: "\f008"; }
+.ri-play-circle-line:before { content: "\f009"; }
+.ri-play-fill:before { content: "\f00a"; }
+.ri-play-line:before { content: "\f00b"; }
+.ri-play-list-2-fill:before { content: "\f00c"; }
+.ri-play-list-2-line:before { content: "\f00d"; }
+.ri-play-list-add-fill:before { content: "\f00e"; }
+.ri-play-list-add-line:before { content: "\f00f"; }
+.ri-play-list-fill:before { content: "\f010"; }
+.ri-play-list-line:before { content: "\f011"; }
+.ri-play-mini-fill:before { content: "\f012"; }
+.ri-play-mini-line:before { content: "\f013"; }
+.ri-playstation-fill:before { content: "\f014"; }
+.ri-playstation-line:before { content: "\f015"; }
+.ri-plug-2-fill:before { content: "\f016"; }
+.ri-plug-2-line:before { content: "\f017"; }
+.ri-plug-fill:before { content: "\f018"; }
+.ri-plug-line:before { content: "\f019"; }
+.ri-polaroid-2-fill:before { content: "\f01a"; }
+.ri-polaroid-2-line:before { content: "\f01b"; }
+.ri-polaroid-fill:before { content: "\f01c"; }
+.ri-polaroid-line:before { content: "\f01d"; }
+.ri-police-car-fill:before { content: "\f01e"; }
+.ri-police-car-line:before { content: "\f01f"; }
+.ri-price-tag-2-fill:before { content: "\f020"; }
+.ri-price-tag-2-line:before { content: "\f021"; }
+.ri-price-tag-3-fill:before { content: "\f022"; }
+.ri-price-tag-3-line:before { content: "\f023"; }
+.ri-price-tag-fill:before { content: "\f024"; }
+.ri-price-tag-line:before { content: "\f025"; }
+.ri-printer-cloud-fill:before { content: "\f026"; }
+.ri-printer-cloud-line:before { content: "\f027"; }
+.ri-printer-fill:before { content: "\f028"; }
+.ri-printer-line:before { content: "\f029"; }
+.ri-product-hunt-fill:before { content: "\f02a"; }
+.ri-product-hunt-line:before { content: "\f02b"; }
+.ri-profile-fill:before { content: "\f02c"; }
+.ri-profile-line:before { content: "\f02d"; }
+.ri-projector-2-fill:before { content: "\f02e"; }
+.ri-projector-2-line:before { content: "\f02f"; }
+.ri-projector-fill:before { content: "\f030"; }
+.ri-projector-line:before { content: "\f031"; }
+.ri-psychotherapy-fill:before { content: "\f032"; }
+.ri-psychotherapy-line:before { content: "\f033"; }
+.ri-pulse-fill:before { content: "\f034"; }
+.ri-pulse-line:before { content: "\f035"; }
+.ri-pushpin-2-fill:before { content: "\f036"; }
+.ri-pushpin-2-line:before { content: "\f037"; }
+.ri-pushpin-fill:before { content: "\f038"; }
+.ri-pushpin-line:before { content: "\f039"; }
+.ri-qq-fill:before { content: "\f03a"; }
+.ri-qq-line:before { content: "\f03b"; }
+.ri-qr-code-fill:before { content: "\f03c"; }
+.ri-qr-code-line:before { content: "\f03d"; }
+.ri-qr-scan-2-fill:before { content: "\f03e"; }
+.ri-qr-scan-2-line:before { content: "\f03f"; }
+.ri-qr-scan-fill:before { content: "\f040"; }
+.ri-qr-scan-line:before { content: "\f041"; }
+.ri-question-answer-fill:before { content: "\f042"; }
+.ri-question-answer-line:before { content: "\f043"; }
+.ri-question-fill:before { content: "\f044"; }
+.ri-question-line:before { content: "\f045"; }
+.ri-question-mark:before { content: "\f046"; }
+.ri-questionnaire-fill:before { content: "\f047"; }
+.ri-questionnaire-line:before { content: "\f048"; }
+.ri-quill-pen-fill:before { content: "\f049"; }
+.ri-quill-pen-line:before { content: "\f04a"; }
+.ri-radar-fill:before { content: "\f04b"; }
+.ri-radar-line:before { content: "\f04c"; }
+.ri-radio-2-fill:before { content: "\f04d"; }
+.ri-radio-2-line:before { content: "\f04e"; }
+.ri-radio-button-fill:before { content: "\f04f"; }
+.ri-radio-button-line:before { content: "\f050"; }
+.ri-radio-fill:before { content: "\f051"; }
+.ri-radio-line:before { content: "\f052"; }
+.ri-rainbow-fill:before { content: "\f053"; }
+.ri-rainbow-line:before { content: "\f054"; }
+.ri-rainy-fill:before { content: "\f055"; }
+.ri-rainy-line:before { content: "\f056"; }
+.ri-reactjs-fill:before { content: "\f057"; }
+.ri-reactjs-line:before { content: "\f058"; }
+.ri-record-circle-fill:before { content: "\f059"; }
+.ri-record-circle-line:before { content: "\f05a"; }
+.ri-record-mail-fill:before { content: "\f05b"; }
+.ri-record-mail-line:before { content: "\f05c"; }
+.ri-recycle-fill:before { content: "\f05d"; }
+.ri-recycle-line:before { content: "\f05e"; }
+.ri-red-packet-fill:before { content: "\f05f"; }
+.ri-red-packet-line:before { content: "\f060"; }
+.ri-reddit-fill:before { content: "\f061"; }
+.ri-reddit-line:before { content: "\f062"; }
+.ri-refresh-fill:before { content: "\f063"; }
+.ri-refresh-line:before { content: "\f064"; }
+.ri-refund-2-fill:before { content: "\f065"; }
+.ri-refund-2-line:before { content: "\f066"; }
+.ri-refund-fill:before { content: "\f067"; }
+.ri-refund-line:before { content: "\f068"; }
+.ri-registered-fill:before { content: "\f069"; }
+.ri-registered-line:before { content: "\f06a"; }
+.ri-remixicon-fill:before { content: "\f06b"; }
+.ri-remixicon-line:before { content: "\f06c"; }
+.ri-remote-control-2-fill:before { content: "\f06d"; }
+.ri-remote-control-2-line:before { content: "\f06e"; }
+.ri-remote-control-fill:before { content: "\f06f"; }
+.ri-remote-control-line:before { content: "\f070"; }
+.ri-repeat-2-fill:before { content: "\f071"; }
+.ri-repeat-2-line:before { content: "\f072"; }
+.ri-repeat-fill:before { content: "\f073"; }
+.ri-repeat-line:before { content: "\f074"; }
+.ri-repeat-one-fill:before { content: "\f075"; }
+.ri-repeat-one-line:before { content: "\f076"; }
+.ri-reply-all-fill:before { content: "\f077"; }
+.ri-reply-all-line:before { content: "\f078"; }
+.ri-reply-fill:before { content: "\f079"; }
+.ri-reply-line:before { content: "\f07a"; }
+.ri-reserved-fill:before { content: "\f07b"; }
+.ri-reserved-line:before { content: "\f07c"; }
+.ri-rest-time-fill:before { content: "\f07d"; }
+.ri-rest-time-line:before { content: "\f07e"; }
+.ri-restart-fill:before { content: "\f07f"; }
+.ri-restart-line:before { content: "\f080"; }
+.ri-restaurant-2-fill:before { content: "\f081"; }
+.ri-restaurant-2-line:before { content: "\f082"; }
+.ri-restaurant-fill:before { content: "\f083"; }
+.ri-restaurant-line:before { content: "\f084"; }
+.ri-rewind-fill:before { content: "\f085"; }
+.ri-rewind-line:before { content: "\f086"; }
+.ri-rewind-mini-fill:before { content: "\f087"; }
+.ri-rewind-mini-line:before { content: "\f088"; }
+.ri-rhythm-fill:before { content: "\f089"; }
+.ri-rhythm-line:before { content: "\f08a"; }
+.ri-riding-fill:before { content: "\f08b"; }
+.ri-riding-line:before { content: "\f08c"; }
+.ri-road-map-fill:before { content: "\f08d"; }
+.ri-road-map-line:before { content: "\f08e"; }
+.ri-roadster-fill:before { content: "\f08f"; }
+.ri-roadster-line:before { content: "\f090"; }
+.ri-robot-fill:before { content: "\f091"; }
+.ri-robot-line:before { content: "\f092"; }
+.ri-rocket-2-fill:before { content: "\f093"; }
+.ri-rocket-2-line:before { content: "\f094"; }
+.ri-rocket-fill:before { content: "\f095"; }
+.ri-rocket-line:before { content: "\f096"; }
+.ri-rotate-lock-fill:before { content: "\f097"; }
+.ri-rotate-lock-line:before { content: "\f098"; }
+.ri-rounded-corner:before { content: "\f099"; }
+.ri-route-fill:before { content: "\f09a"; }
+.ri-route-line:before { content: "\f09b"; }
+.ri-router-fill:before { content: "\f09c"; }
+.ri-router-line:before { content: "\f09d"; }
+.ri-rss-fill:before { content: "\f09e"; }
+.ri-rss-line:before { content: "\f09f"; }
+.ri-ruler-2-fill:before { content: "\f0a0"; }
+.ri-ruler-2-line:before { content: "\f0a1"; }
+.ri-ruler-fill:before { content: "\f0a2"; }
+.ri-ruler-line:before { content: "\f0a3"; }
+.ri-run-fill:before { content: "\f0a4"; }
+.ri-run-line:before { content: "\f0a5"; }
+.ri-safari-fill:before { content: "\f0a6"; }
+.ri-safari-line:before { content: "\f0a7"; }
+.ri-safe-2-fill:before { content: "\f0a8"; }
+.ri-safe-2-line:before { content: "\f0a9"; }
+.ri-safe-fill:before { content: "\f0aa"; }
+.ri-safe-line:before { content: "\f0ab"; }
+.ri-sailboat-fill:before { content: "\f0ac"; }
+.ri-sailboat-line:before { content: "\f0ad"; }
+.ri-save-2-fill:before { content: "\f0ae"; }
+.ri-save-2-line:before { content: "\f0af"; }
+.ri-save-3-fill:before { content: "\f0b0"; }
+.ri-save-3-line:before { content: "\f0b1"; }
+.ri-save-fill:before { content: "\f0b2"; }
+.ri-save-line:before { content: "\f0b3"; }
+.ri-scales-2-fill:before { content: "\f0b4"; }
+.ri-scales-2-line:before { content: "\f0b5"; }
+.ri-scales-3-fill:before { content: "\f0b6"; }
+.ri-scales-3-line:before { content: "\f0b7"; }
+.ri-scales-fill:before { content: "\f0b8"; }
+.ri-scales-line:before { content: "\f0b9"; }
+.ri-scan-2-fill:before { content: "\f0ba"; }
+.ri-scan-2-line:before { content: "\f0bb"; }
+.ri-scan-fill:before { content: "\f0bc"; }
+.ri-scan-line:before { content: "\f0bd"; }
+.ri-scissors-2-fill:before { content: "\f0be"; }
+.ri-scissors-2-line:before { content: "\f0bf"; }
+.ri-scissors-cut-fill:before { content: "\f0c0"; }
+.ri-scissors-cut-line:before { content: "\f0c1"; }
+.ri-scissors-fill:before { content: "\f0c2"; }
+.ri-scissors-line:before { content: "\f0c3"; }
+.ri-screenshot-2-fill:before { content: "\f0c4"; }
+.ri-screenshot-2-line:before { content: "\f0c5"; }
+.ri-screenshot-fill:before { content: "\f0c6"; }
+.ri-screenshot-line:before { content: "\f0c7"; }
+.ri-sd-card-fill:before { content: "\f0c8"; }
+.ri-sd-card-line:before { content: "\f0c9"; }
+.ri-sd-card-mini-fill:before { content: "\f0ca"; }
+.ri-sd-card-mini-line:before { content: "\f0cb"; }
+.ri-search-2-fill:before { content: "\f0cc"; }
+.ri-search-2-line:before { content: "\f0cd"; }
+.ri-search-eye-fill:before { content: "\f0ce"; }
+.ri-search-eye-line:before { content: "\f0cf"; }
+.ri-search-fill:before { content: "\f0d0"; }
+.ri-search-line:before { content: "\f0d1"; }
+.ri-secure-payment-fill:before { content: "\f0d2"; }
+.ri-secure-payment-line:before { content: "\f0d3"; }
+.ri-seedling-fill:before { content: "\f0d4"; }
+.ri-seedling-line:before { content: "\f0d5"; }
+.ri-send-backward:before { content: "\f0d6"; }
+.ri-send-plane-2-fill:before { content: "\f0d7"; }
+.ri-send-plane-2-line:before { content: "\f0d8"; }
+.ri-send-plane-fill:before { content: "\f0d9"; }
+.ri-send-plane-line:before { content: "\f0da"; }
+.ri-send-to-back:before { content: "\f0db"; }
+.ri-sensor-fill:before { content: "\f0dc"; }
+.ri-sensor-line:before { content: "\f0dd"; }
+.ri-separator:before { content: "\f0de"; }
+.ri-server-fill:before { content: "\f0df"; }
+.ri-server-line:before { content: "\f0e0"; }
+.ri-service-fill:before { content: "\f0e1"; }
+.ri-service-line:before { content: "\f0e2"; }
+.ri-settings-2-fill:before { content: "\f0e3"; }
+.ri-settings-2-line:before { content: "\f0e4"; }
+.ri-settings-3-fill:before { content: "\f0e5"; }
+.ri-settings-3-line:before { content: "\f0e6"; }
+.ri-settings-4-fill:before { content: "\f0e7"; }
+.ri-settings-4-line:before { content: "\f0e8"; }
+.ri-settings-5-fill:before { content: "\f0e9"; }
+.ri-settings-5-line:before { content: "\f0ea"; }
+.ri-settings-6-fill:before { content: "\f0eb"; }
+.ri-settings-6-line:before { content: "\f0ec"; }
+.ri-settings-fill:before { content: "\f0ed"; }
+.ri-settings-line:before { content: "\f0ee"; }
+.ri-shape-2-fill:before { content: "\f0ef"; }
+.ri-shape-2-line:before { content: "\f0f0"; }
+.ri-shape-fill:before { content: "\f0f1"; }
+.ri-shape-line:before { content: "\f0f2"; }
+.ri-share-box-fill:before { content: "\f0f3"; }
+.ri-share-box-line:before { content: "\f0f4"; }
+.ri-share-circle-fill:before { content: "\f0f5"; }
+.ri-share-circle-line:before { content: "\f0f6"; }
+.ri-share-fill:before { content: "\f0f7"; }
+.ri-share-forward-2-fill:before { content: "\f0f8"; }
+.ri-share-forward-2-line:before { content: "\f0f9"; }
+.ri-share-forward-box-fill:before { content: "\f0fa"; }
+.ri-share-forward-box-line:before { content: "\f0fb"; }
+.ri-share-forward-fill:before { content: "\f0fc"; }
+.ri-share-forward-line:before { content: "\f0fd"; }
+.ri-share-line:before { content: "\f0fe"; }
+.ri-shield-check-fill:before { content: "\f0ff"; }
+.ri-shield-check-line:before { content: "\f100"; }
+.ri-shield-cross-fill:before { content: "\f101"; }
+.ri-shield-cross-line:before { content: "\f102"; }
+.ri-shield-fill:before { content: "\f103"; }
+.ri-shield-flash-fill:before { content: "\f104"; }
+.ri-shield-flash-line:before { content: "\f105"; }
+.ri-shield-keyhole-fill:before { content: "\f106"; }
+.ri-shield-keyhole-line:before { content: "\f107"; }
+.ri-shield-line:before { content: "\f108"; }
+.ri-shield-star-fill:before { content: "\f109"; }
+.ri-shield-star-line:before { content: "\f10a"; }
+.ri-shield-user-fill:before { content: "\f10b"; }
+.ri-shield-user-line:before { content: "\f10c"; }
+.ri-ship-2-fill:before { content: "\f10d"; }
+.ri-ship-2-line:before { content: "\f10e"; }
+.ri-ship-fill:before { content: "\f10f"; }
+.ri-ship-line:before { content: "\f110"; }
+.ri-shirt-fill:before { content: "\f111"; }
+.ri-shirt-line:before { content: "\f112"; }
+.ri-shopping-bag-2-fill:before { content: "\f113"; }
+.ri-shopping-bag-2-line:before { content: "\f114"; }
+.ri-shopping-bag-3-fill:before { content: "\f115"; }
+.ri-shopping-bag-3-line:before { content: "\f116"; }
+.ri-shopping-bag-fill:before { content: "\f117"; }
+.ri-shopping-bag-line:before { content: "\f118"; }
+.ri-shopping-basket-2-fill:before { content: "\f119"; }
+.ri-shopping-basket-2-line:before { content: "\f11a"; }
+.ri-shopping-basket-fill:before { content: "\f11b"; }
+.ri-shopping-basket-line:before { content: "\f11c"; }
+.ri-shopping-cart-2-fill:before { content: "\f11d"; }
+.ri-shopping-cart-2-line:before { content: "\f11e"; }
+.ri-shopping-cart-fill:before { content: "\f11f"; }
+.ri-shopping-cart-line:before { content: "\f120"; }
+.ri-showers-fill:before { content: "\f121"; }
+.ri-showers-line:before { content: "\f122"; }
+.ri-shuffle-fill:before { content: "\f123"; }
+.ri-shuffle-line:before { content: "\f124"; }
+.ri-shut-down-fill:before { content: "\f125"; }
+.ri-shut-down-line:before { content: "\f126"; }
+.ri-side-bar-fill:before { content: "\f127"; }
+.ri-side-bar-line:before { content: "\f128"; }
+.ri-signal-tower-fill:before { content: "\f129"; }
+.ri-signal-tower-line:before { content: "\f12a"; }
+.ri-signal-wifi-1-fill:before { content: "\f12b"; }
+.ri-signal-wifi-1-line:before { content: "\f12c"; }
+.ri-signal-wifi-2-fill:before { content: "\f12d"; }
+.ri-signal-wifi-2-line:before { content: "\f12e"; }
+.ri-signal-wifi-3-fill:before { content: "\f12f"; }
+.ri-signal-wifi-3-line:before { content: "\f130"; }
+.ri-signal-wifi-error-fill:before { content: "\f131"; }
+.ri-signal-wifi-error-line:before { content: "\f132"; }
+.ri-signal-wifi-fill:before { content: "\f133"; }
+.ri-signal-wifi-line:before { content: "\f134"; }
+.ri-signal-wifi-off-fill:before { content: "\f135"; }
+.ri-signal-wifi-off-line:before { content: "\f136"; }
+.ri-sim-card-2-fill:before { content: "\f137"; }
+.ri-sim-card-2-line:before { content: "\f138"; }
+.ri-sim-card-fill:before { content: "\f139"; }
+.ri-sim-card-line:before { content: "\f13a"; }
+.ri-single-quotes-l:before { content: "\f13b"; }
+.ri-single-quotes-r:before { content: "\f13c"; }
+.ri-sip-fill:before { content: "\f13d"; }
+.ri-sip-line:before { content: "\f13e"; }
+.ri-skip-back-fill:before { content: "\f13f"; }
+.ri-skip-back-line:before { content: "\f140"; }
+.ri-skip-back-mini-fill:before { content: "\f141"; }
+.ri-skip-back-mini-line:before { content: "\f142"; }
+.ri-skip-forward-fill:before { content: "\f143"; }
+.ri-skip-forward-line:before { content: "\f144"; }
+.ri-skip-forward-mini-fill:before { content: "\f145"; }
+.ri-skip-forward-mini-line:before { content: "\f146"; }
+.ri-skull-2-fill:before { content: "\f147"; }
+.ri-skull-2-line:before { content: "\f148"; }
+.ri-skull-fill:before { content: "\f149"; }
+.ri-skull-line:before { content: "\f14a"; }
+.ri-skype-fill:before { content: "\f14b"; }
+.ri-skype-line:before { content: "\f14c"; }
+.ri-slack-fill:before { content: "\f14d"; }
+.ri-slack-line:before { content: "\f14e"; }
+.ri-slice-fill:before { content: "\f14f"; }
+.ri-slice-line:before { content: "\f150"; }
+.ri-slideshow-2-fill:before { content: "\f151"; }
+.ri-slideshow-2-line:before { content: "\f152"; }
+.ri-slideshow-3-fill:before { content: "\f153"; }
+.ri-slideshow-3-line:before { content: "\f154"; }
+.ri-slideshow-4-fill:before { content: "\f155"; }
+.ri-slideshow-4-line:before { content: "\f156"; }
+.ri-slideshow-fill:before { content: "\f157"; }
+.ri-slideshow-line:before { content: "\f158"; }
+.ri-smartphone-fill:before { content: "\f159"; }
+.ri-smartphone-line:before { content: "\f15a"; }
+.ri-snapchat-fill:before { content: "\f15b"; }
+.ri-snapchat-line:before { content: "\f15c"; }
+.ri-snowy-fill:before { content: "\f15d"; }
+.ri-snowy-line:before { content: "\f15e"; }
+.ri-sort-asc:before { content: "\f15f"; }
+.ri-sort-desc:before { content: "\f160"; }
+.ri-sound-module-fill:before { content: "\f161"; }
+.ri-sound-module-line:before { content: "\f162"; }
+.ri-soundcloud-fill:before { content: "\f163"; }
+.ri-soundcloud-line:before { content: "\f164"; }
+.ri-space-ship-fill:before { content: "\f165"; }
+.ri-space-ship-line:before { content: "\f166"; }
+.ri-space:before { content: "\f167"; }
+.ri-spam-2-fill:before { content: "\f168"; }
+.ri-spam-2-line:before { content: "\f169"; }
+.ri-spam-3-fill:before { content: "\f16a"; }
+.ri-spam-3-line:before { content: "\f16b"; }
+.ri-spam-fill:before { content: "\f16c"; }
+.ri-spam-line:before { content: "\f16d"; }
+.ri-speaker-2-fill:before { content: "\f16e"; }
+.ri-speaker-2-line:before { content: "\f16f"; }
+.ri-speaker-3-fill:before { content: "\f170"; }
+.ri-speaker-3-line:before { content: "\f171"; }
+.ri-speaker-fill:before { content: "\f172"; }
+.ri-speaker-line:before { content: "\f173"; }
+.ri-spectrum-fill:before { content: "\f174"; }
+.ri-spectrum-line:before { content: "\f175"; }
+.ri-speed-fill:before { content: "\f176"; }
+.ri-speed-line:before { content: "\f177"; }
+.ri-speed-mini-fill:before { content: "\f178"; }
+.ri-speed-mini-line:before { content: "\f179"; }
+.ri-split-cells-horizontal:before { content: "\f17a"; }
+.ri-split-cells-vertical:before { content: "\f17b"; }
+.ri-spotify-fill:before { content: "\f17c"; }
+.ri-spotify-line:before { content: "\f17d"; }
+.ri-spy-fill:before { content: "\f17e"; }
+.ri-spy-line:before { content: "\f17f"; }
+.ri-stack-fill:before { content: "\f180"; }
+.ri-stack-line:before { content: "\f181"; }
+.ri-stack-overflow-fill:before { content: "\f182"; }
+.ri-stack-overflow-line:before { content: "\f183"; }
+.ri-stackshare-fill:before { content: "\f184"; }
+.ri-stackshare-line:before { content: "\f185"; }
+.ri-star-fill:before { content: "\f186"; }
+.ri-star-half-fill:before { content: "\f187"; }
+.ri-star-half-line:before { content: "\f188"; }
+.ri-star-half-s-fill:before { content: "\f189"; }
+.ri-star-half-s-line:before { content: "\f18a"; }
+.ri-star-line:before { content: "\f18b"; }
+.ri-star-s-fill:before { content: "\f18c"; }
+.ri-star-s-line:before { content: "\f18d"; }
+.ri-star-smile-fill:before { content: "\f18e"; }
+.ri-star-smile-line:before { content: "\f18f"; }
+.ri-steam-fill:before { content: "\f190"; }
+.ri-steam-line:before { content: "\f191"; }
+.ri-steering-2-fill:before { content: "\f192"; }
+.ri-steering-2-line:before { content: "\f193"; }
+.ri-steering-fill:before { content: "\f194"; }
+.ri-steering-line:before { content: "\f195"; }
+.ri-stethoscope-fill:before { content: "\f196"; }
+.ri-stethoscope-line:before { content: "\f197"; }
+.ri-sticky-note-2-fill:before { content: "\f198"; }
+.ri-sticky-note-2-line:before { content: "\f199"; }
+.ri-sticky-note-fill:before { content: "\f19a"; }
+.ri-sticky-note-line:before { content: "\f19b"; }
+.ri-stock-fill:before { content: "\f19c"; }
+.ri-stock-line:before { content: "\f19d"; }
+.ri-stop-circle-fill:before { content: "\f19e"; }
+.ri-stop-circle-line:before { content: "\f19f"; }
+.ri-stop-fill:before { content: "\f1a0"; }
+.ri-stop-line:before { content: "\f1a1"; }
+.ri-stop-mini-fill:before { content: "\f1a2"; }
+.ri-stop-mini-line:before { content: "\f1a3"; }
+.ri-store-2-fill:before { content: "\f1a4"; }
+.ri-store-2-line:before { content: "\f1a5"; }
+.ri-store-3-fill:before { content: "\f1a6"; }
+.ri-store-3-line:before { content: "\f1a7"; }
+.ri-store-fill:before { content: "\f1a8"; }
+.ri-store-line:before { content: "\f1a9"; }
+.ri-strikethrough-2:before { content: "\f1aa"; }
+.ri-strikethrough:before { content: "\f1ab"; }
+.ri-subscript-2:before { content: "\f1ac"; }
+.ri-subscript:before { content: "\f1ad"; }
+.ri-subtract-fill:before { content: "\f1ae"; }
+.ri-subtract-line:before { content: "\f1af"; }
+.ri-subway-fill:before { content: "\f1b0"; }
+.ri-subway-line:before { content: "\f1b1"; }
+.ri-subway-wifi-fill:before { content: "\f1b2"; }
+.ri-subway-wifi-line:before { content: "\f1b3"; }
+.ri-suitcase-2-fill:before { content: "\f1b4"; }
+.ri-suitcase-2-line:before { content: "\f1b5"; }
+.ri-suitcase-3-fill:before { content: "\f1b6"; }
+.ri-suitcase-3-line:before { content: "\f1b7"; }
+.ri-suitcase-fill:before { content: "\f1b8"; }
+.ri-suitcase-line:before { content: "\f1b9"; }
+.ri-sun-cloudy-fill:before { content: "\f1ba"; }
+.ri-sun-cloudy-line:before { content: "\f1bb"; }
+.ri-sun-fill:before { content: "\f1bc"; }
+.ri-sun-foggy-fill:before { content: "\f1bd"; }
+.ri-sun-foggy-line:before { content: "\f1be"; }
+.ri-sun-line:before { content: "\f1bf"; }
+.ri-superscript-2:before { content: "\f1c0"; }
+.ri-superscript:before { content: "\f1c1"; }
+.ri-surgical-mask-fill:before { content: "\f1c2"; }
+.ri-surgical-mask-line:before { content: "\f1c3"; }
+.ri-surround-sound-fill:before { content: "\f1c4"; }
+.ri-surround-sound-line:before { content: "\f1c5"; }
+.ri-survey-fill:before { content: "\f1c6"; }
+.ri-survey-line:before { content: "\f1c7"; }
+.ri-swap-box-fill:before { content: "\f1c8"; }
+.ri-swap-box-line:before { content: "\f1c9"; }
+.ri-swap-fill:before { content: "\f1ca"; }
+.ri-swap-line:before { content: "\f1cb"; }
+.ri-switch-fill:before { content: "\f1cc"; }
+.ri-switch-line:before { content: "\f1cd"; }
+.ri-sword-fill:before { content: "\f1ce"; }
+.ri-sword-line:before { content: "\f1cf"; }
+.ri-syringe-fill:before { content: "\f1d0"; }
+.ri-syringe-line:before { content: "\f1d1"; }
+.ri-t-box-fill:before { content: "\f1d2"; }
+.ri-t-box-line:before { content: "\f1d3"; }
+.ri-t-shirt-2-fill:before { content: "\f1d4"; }
+.ri-t-shirt-2-line:before { content: "\f1d5"; }
+.ri-t-shirt-air-fill:before { content: "\f1d6"; }
+.ri-t-shirt-air-line:before { content: "\f1d7"; }
+.ri-t-shirt-fill:before { content: "\f1d8"; }
+.ri-t-shirt-line:before { content: "\f1d9"; }
+.ri-table-2:before { content: "\f1da"; }
+.ri-table-alt-fill:before { content: "\f1db"; }
+.ri-table-alt-line:before { content: "\f1dc"; }
+.ri-table-fill:before { content: "\f1dd"; }
+.ri-table-line:before { content: "\f1de"; }
+.ri-tablet-fill:before { content: "\f1df"; }
+.ri-tablet-line:before { content: "\f1e0"; }
+.ri-takeaway-fill:before { content: "\f1e1"; }
+.ri-takeaway-line:before { content: "\f1e2"; }
+.ri-taobao-fill:before { content: "\f1e3"; }
+.ri-taobao-line:before { content: "\f1e4"; }
+.ri-tape-fill:before { content: "\f1e5"; }
+.ri-tape-line:before { content: "\f1e6"; }
+.ri-task-fill:before { content: "\f1e7"; }
+.ri-task-line:before { content: "\f1e8"; }
+.ri-taxi-fill:before { content: "\f1e9"; }
+.ri-taxi-line:before { content: "\f1ea"; }
+.ri-taxi-wifi-fill:before { content: "\f1eb"; }
+.ri-taxi-wifi-line:before { content: "\f1ec"; }
+.ri-team-fill:before { content: "\f1ed"; }
+.ri-team-line:before { content: "\f1ee"; }
+.ri-telegram-fill:before { content: "\f1ef"; }
+.ri-telegram-line:before { content: "\f1f0"; }
+.ri-temp-cold-fill:before { content: "\f1f1"; }
+.ri-temp-cold-line:before { content: "\f1f2"; }
+.ri-temp-hot-fill:before { content: "\f1f3"; }
+.ri-temp-hot-line:before { content: "\f1f4"; }
+.ri-terminal-box-fill:before { content: "\f1f5"; }
+.ri-terminal-box-line:before { content: "\f1f6"; }
+.ri-terminal-fill:before { content: "\f1f7"; }
+.ri-terminal-line:before { content: "\f1f8"; }
+.ri-terminal-window-fill:before { content: "\f1f9"; }
+.ri-terminal-window-line:before { content: "\f1fa"; }
+.ri-test-tube-fill:before { content: "\f1fb"; }
+.ri-test-tube-line:before { content: "\f1fc"; }
+.ri-text-direction-l:before { content: "\f1fd"; }
+.ri-text-direction-r:before { content: "\f1fe"; }
+.ri-text-spacing:before { content: "\f1ff"; }
+.ri-text-wrap:before { content: "\f200"; }
+.ri-text:before { content: "\f201"; }
+.ri-thermometer-fill:before { content: "\f202"; }
+.ri-thermometer-line:before { content: "\f203"; }
+.ri-thumb-down-fill:before { content: "\f204"; }
+.ri-thumb-down-line:before { content: "\f205"; }
+.ri-thumb-up-fill:before { content: "\f206"; }
+.ri-thumb-up-line:before { content: "\f207"; }
+.ri-thunderstorms-fill:before { content: "\f208"; }
+.ri-thunderstorms-line:before { content: "\f209"; }
+.ri-ticket-2-fill:before { content: "\f20a"; }
+.ri-ticket-2-line:before { content: "\f20b"; }
+.ri-ticket-fill:before { content: "\f20c"; }
+.ri-ticket-line:before { content: "\f20d"; }
+.ri-time-fill:before { content: "\f20e"; }
+.ri-time-line:before { content: "\f20f"; }
+.ri-timer-2-fill:before { content: "\f210"; }
+.ri-timer-2-line:before { content: "\f211"; }
+.ri-timer-fill:before { content: "\f212"; }
+.ri-timer-flash-fill:before { content: "\f213"; }
+.ri-timer-flash-line:before { content: "\f214"; }
+.ri-timer-line:before { content: "\f215"; }
+.ri-todo-fill:before { content: "\f216"; }
+.ri-todo-line:before { content: "\f217"; }
+.ri-toggle-fill:before { content: "\f218"; }
+.ri-toggle-line:before { content: "\f219"; }
+.ri-tools-fill:before { content: "\f21a"; }
+.ri-tools-line:before { content: "\f21b"; }
+.ri-tornado-fill:before { content: "\f21c"; }
+.ri-tornado-line:before { content: "\f21d"; }
+.ri-trademark-fill:before { content: "\f21e"; }
+.ri-trademark-line:before { content: "\f21f"; }
+.ri-traffic-light-fill:before { content: "\f220"; }
+.ri-traffic-light-line:before { content: "\f221"; }
+.ri-train-fill:before { content: "\f222"; }
+.ri-train-line:before { content: "\f223"; }
+.ri-train-wifi-fill:before { content: "\f224"; }
+.ri-train-wifi-line:before { content: "\f225"; }
+.ri-translate-2:before { content: "\f226"; }
+.ri-translate:before { content: "\f227"; }
+.ri-travesti-fill:before { content: "\f228"; }
+.ri-travesti-line:before { content: "\f229"; }
+.ri-treasure-map-fill:before { content: "\f22a"; }
+.ri-treasure-map-line:before { content: "\f22b"; }
+.ri-trello-fill:before { content: "\f22c"; }
+.ri-trello-line:before { content: "\f22d"; }
+.ri-trophy-fill:before { content: "\f22e"; }
+.ri-trophy-line:before { content: "\f22f"; }
+.ri-truck-fill:before { content: "\f230"; }
+.ri-truck-line:before { content: "\f231"; }
+.ri-tumblr-fill:before { content: "\f232"; }
+.ri-tumblr-line:before { content: "\f233"; }
+.ri-tv-2-fill:before { content: "\f234"; }
+.ri-tv-2-line:before { content: "\f235"; }
+.ri-tv-fill:before { content: "\f236"; }
+.ri-tv-line:before { content: "\f237"; }
+.ri-twitch-fill:before { content: "\f238"; }
+.ri-twitch-line:before { content: "\f239"; }
+.ri-twitter-fill:before { content: "\f23a"; }
+.ri-twitter-line:before { content: "\f23b"; }
+.ri-typhoon-fill:before { content: "\f23c"; }
+.ri-typhoon-line:before { content: "\f23d"; }
+.ri-u-disk-fill:before { content: "\f23e"; }
+.ri-u-disk-line:before { content: "\f23f"; }
+.ri-ubuntu-fill:before { content: "\f240"; }
+.ri-ubuntu-line:before { content: "\f241"; }
+.ri-umbrella-fill:before { content: "\f242"; }
+.ri-umbrella-line:before { content: "\f243"; }
+.ri-underline:before { content: "\f244"; }
+.ri-uninstall-fill:before { content: "\f245"; }
+.ri-uninstall-line:before { content: "\f246"; }
+.ri-unsplash-fill:before { content: "\f247"; }
+.ri-unsplash-line:before { content: "\f248"; }
+.ri-upload-2-fill:before { content: "\f249"; }
+.ri-upload-2-line:before { content: "\f24a"; }
+.ri-upload-cloud-2-fill:before { content: "\f24b"; }
+.ri-upload-cloud-2-line:before { content: "\f24c"; }
+.ri-upload-cloud-fill:before { content: "\f24d"; }
+.ri-upload-cloud-line:before { content: "\f24e"; }
+.ri-upload-fill:before { content: "\f24f"; }
+.ri-upload-line:before { content: "\f250"; }
+.ri-usb-fill:before { content: "\f251"; }
+.ri-usb-line:before { content: "\f252"; }
+.ri-user-2-fill:before { content: "\f253"; }
+.ri-user-2-line:before { content: "\f254"; }
+.ri-user-3-fill:before { content: "\f255"; }
+.ri-user-3-line:before { content: "\f256"; }
+.ri-user-4-fill:before { content: "\f257"; }
+.ri-user-4-line:before { content: "\f258"; }
+.ri-user-5-fill:before { content: "\f259"; }
+.ri-user-5-line:before { content: "\f25a"; }
+.ri-user-6-fill:before { content: "\f25b"; }
+.ri-user-6-line:before { content: "\f25c"; }
+.ri-user-add-fill:before { content: "\f25d"; }
+.ri-user-add-line:before { content: "\f25e"; }
+.ri-user-fill:before { content: "\f25f"; }
+.ri-user-follow-fill:before { content: "\f260"; }
+.ri-user-follow-line:before { content: "\f261"; }
+.ri-user-heart-fill:before { content: "\f262"; }
+.ri-user-heart-line:before { content: "\f263"; }
+.ri-user-line:before { content: "\f264"; }
+.ri-user-location-fill:before { content: "\f265"; }
+.ri-user-location-line:before { content: "\f266"; }
+.ri-user-received-2-fill:before { content: "\f267"; }
+.ri-user-received-2-line:before { content: "\f268"; }
+.ri-user-received-fill:before { content: "\f269"; }
+.ri-user-received-line:before { content: "\f26a"; }
+.ri-user-search-fill:before { content: "\f26b"; }
+.ri-user-search-line:before { content: "\f26c"; }
+.ri-user-settings-fill:before { content: "\f26d"; }
+.ri-user-settings-line:before { content: "\f26e"; }
+.ri-user-shared-2-fill:before { content: "\f26f"; }
+.ri-user-shared-2-line:before { content: "\f270"; }
+.ri-user-shared-fill:before { content: "\f271"; }
+.ri-user-shared-line:before { content: "\f272"; }
+.ri-user-smile-fill:before { content: "\f273"; }
+.ri-user-smile-line:before { content: "\f274"; }
+.ri-user-star-fill:before { content: "\f275"; }
+.ri-user-star-line:before { content: "\f276"; }
+.ri-user-unfollow-fill:before { content: "\f277"; }
+.ri-user-unfollow-line:before { content: "\f278"; }
+.ri-user-voice-fill:before { content: "\f279"; }
+.ri-user-voice-line:before { content: "\f27a"; }
+.ri-video-add-fill:before { content: "\f27b"; }
+.ri-video-add-line:before { content: "\f27c"; }
+.ri-video-chat-fill:before { content: "\f27d"; }
+.ri-video-chat-line:before { content: "\f27e"; }
+.ri-video-download-fill:before { content: "\f27f"; }
+.ri-video-download-line:before { content: "\f280"; }
+.ri-video-fill:before { content: "\f281"; }
+.ri-video-line:before { content: "\f282"; }
+.ri-video-upload-fill:before { content: "\f283"; }
+.ri-video-upload-line:before { content: "\f284"; }
+.ri-vidicon-2-fill:before { content: "\f285"; }
+.ri-vidicon-2-line:before { content: "\f286"; }
+.ri-vidicon-fill:before { content: "\f287"; }
+.ri-vidicon-line:before { content: "\f288"; }
+.ri-vimeo-fill:before { content: "\f289"; }
+.ri-vimeo-line:before { content: "\f28a"; }
+.ri-vip-crown-2-fill:before { content: "\f28b"; }
+.ri-vip-crown-2-line:before { content: "\f28c"; }
+.ri-vip-crown-fill:before { content: "\f28d"; }
+.ri-vip-crown-line:before { content: "\f28e"; }
+.ri-vip-diamond-fill:before { content: "\f28f"; }
+.ri-vip-diamond-line:before { content: "\f290"; }
+.ri-vip-fill:before { content: "\f291"; }
+.ri-vip-line:before { content: "\f292"; }
+.ri-virus-fill:before { content: "\f293"; }
+.ri-virus-line:before { content: "\f294"; }
+.ri-visa-fill:before { content: "\f295"; }
+.ri-visa-line:before { content: "\f296"; }
+.ri-voice-recognition-fill:before { content: "\f297"; }
+.ri-voice-recognition-line:before { content: "\f298"; }
+.ri-voiceprint-fill:before { content: "\f299"; }
+.ri-voiceprint-line:before { content: "\f29a"; }
+.ri-volume-down-fill:before { content: "\f29b"; }
+.ri-volume-down-line:before { content: "\f29c"; }
+.ri-volume-mute-fill:before { content: "\f29d"; }
+.ri-volume-mute-line:before { content: "\f29e"; }
+.ri-volume-off-vibrate-fill:before { content: "\f29f"; }
+.ri-volume-off-vibrate-line:before { content: "\f2a0"; }
+.ri-volume-up-fill:before { content: "\f2a1"; }
+.ri-volume-up-line:before { content: "\f2a2"; }
+.ri-volume-vibrate-fill:before { content: "\f2a3"; }
+.ri-volume-vibrate-line:before { content: "\f2a4"; }
+.ri-vuejs-fill:before { content: "\f2a5"; }
+.ri-vuejs-line:before { content: "\f2a6"; }
+.ri-walk-fill:before { content: "\f2a7"; }
+.ri-walk-line:before { content: "\f2a8"; }
+.ri-wallet-2-fill:before { content: "\f2a9"; }
+.ri-wallet-2-line:before { content: "\f2aa"; }
+.ri-wallet-3-fill:before { content: "\f2ab"; }
+.ri-wallet-3-line:before { content: "\f2ac"; }
+.ri-wallet-fill:before { content: "\f2ad"; }
+.ri-wallet-line:before { content: "\f2ae"; }
+.ri-water-flash-fill:before { content: "\f2af"; }
+.ri-water-flash-line:before { content: "\f2b0"; }
+.ri-webcam-fill:before { content: "\f2b1"; }
+.ri-webcam-line:before { content: "\f2b2"; }
+.ri-wechat-2-fill:before { content: "\f2b3"; }
+.ri-wechat-2-line:before { content: "\f2b4"; }
+.ri-wechat-fill:before { content: "\f2b5"; }
+.ri-wechat-line:before { content: "\f2b6"; }
+.ri-wechat-pay-fill:before { content: "\f2b7"; }
+.ri-wechat-pay-line:before { content: "\f2b8"; }
+.ri-weibo-fill:before { content: "\f2b9"; }
+.ri-weibo-line:before { content: "\f2ba"; }
+.ri-whatsapp-fill:before { content: "\f2bb"; }
+.ri-whatsapp-line:before { content: "\f2bc"; }
+.ri-wheelchair-fill:before { content: "\f2bd"; }
+.ri-wheelchair-line:before { content: "\f2be"; }
+.ri-wifi-fill:before { content: "\f2bf"; }
+.ri-wifi-line:before { content: "\f2c0"; }
+.ri-wifi-off-fill:before { content: "\f2c1"; }
+.ri-wifi-off-line:before { content: "\f2c2"; }
+.ri-window-2-fill:before { content: "\f2c3"; }
+.ri-window-2-line:before { content: "\f2c4"; }
+.ri-window-fill:before { content: "\f2c5"; }
+.ri-window-line:before { content: "\f2c6"; }
+.ri-windows-fill:before { content: "\f2c7"; }
+.ri-windows-line:before { content: "\f2c8"; }
+.ri-windy-fill:before { content: "\f2c9"; }
+.ri-windy-line:before { content: "\f2ca"; }
+.ri-wireless-charging-fill:before { content: "\f2cb"; }
+.ri-wireless-charging-line:before { content: "\f2cc"; }
+.ri-women-fill:before { content: "\f2cd"; }
+.ri-women-line:before { content: "\f2ce"; }
+.ri-wubi-input:before { content: "\f2cf"; }
+.ri-xbox-fill:before { content: "\f2d0"; }
+.ri-xbox-line:before { content: "\f2d1"; }
+.ri-xing-fill:before { content: "\f2d2"; }
+.ri-xing-line:before { content: "\f2d3"; }
+.ri-youtube-fill:before { content: "\f2d4"; }
+.ri-youtube-line:before { content: "\f2d5"; }
+.ri-zcool-fill:before { content: "\f2d6"; }
+.ri-zcool-line:before { content: "\f2d7"; }
+.ri-zhihu-fill:before { content: "\f2d8"; }
+.ri-zhihu-line:before { content: "\f2d9"; }
+.ri-zoom-in-fill:before { content: "\f2da"; }
+.ri-zoom-in-line:before { content: "\f2db"; }
+.ri-zoom-out-fill:before { content: "\f2dc"; }
+.ri-zoom-out-line:before { content: "\f2dd"; }
+.ri-zzz-fill:before { content: "\f2de"; }
+.ri-zzz-line:before { content: "\f2df"; }
+.ri-arrow-down-double-fill:before { content: "\f2e0"; }
+.ri-arrow-down-double-line:before { content: "\f2e1"; }
+.ri-arrow-left-double-fill:before { content: "\f2e2"; }
+.ri-arrow-left-double-line:before { content: "\f2e3"; }
+.ri-arrow-right-double-fill:before { content: "\f2e4"; }
+.ri-arrow-right-double-line:before { content: "\f2e5"; }
+.ri-arrow-turn-back-fill:before { content: "\f2e6"; }
+.ri-arrow-turn-back-line:before { content: "\f2e7"; }
+.ri-arrow-turn-forward-fill:before { content: "\f2e8"; }
+.ri-arrow-turn-forward-line:before { content: "\f2e9"; }
+.ri-arrow-up-double-fill:before { content: "\f2ea"; }
+.ri-arrow-up-double-line:before { content: "\f2eb"; }
+.ri-bard-fill:before { content: "\f2ec"; }
+.ri-bard-line:before { content: "\f2ed"; }
+.ri-bootstrap-fill:before { content: "\f2ee"; }
+.ri-bootstrap-line:before { content: "\f2ef"; }
+.ri-box-1-fill:before { content: "\f2f0"; }
+.ri-box-1-line:before { content: "\f2f1"; }
+.ri-box-2-fill:before { content: "\f2f2"; }
+.ri-box-2-line:before { content: "\f2f3"; }
+.ri-box-3-fill:before { content: "\f2f4"; }
+.ri-box-3-line:before { content: "\f2f5"; }
+.ri-brain-fill:before { content: "\f2f6"; }
+.ri-brain-line:before { content: "\f2f7"; }
+.ri-candle-fill:before { content: "\f2f8"; }
+.ri-candle-line:before { content: "\f2f9"; }
+.ri-cash-fill:before { content: "\f2fa"; }
+.ri-cash-line:before { content: "\f2fb"; }
+.ri-contract-left-fill:before { content: "\f2fc"; }
+.ri-contract-left-line:before { content: "\f2fd"; }
+.ri-contract-left-right-fill:before { content: "\f2fe"; }
+.ri-contract-left-right-line:before { content: "\f2ff"; }
+.ri-contract-right-fill:before { content: "\f300"; }
+.ri-contract-right-line:before { content: "\f301"; }
+.ri-contract-up-down-fill:before { content: "\f302"; }
+.ri-contract-up-down-line:before { content: "\f303"; }
+.ri-copilot-fill:before { content: "\f304"; }
+.ri-copilot-line:before { content: "\f305"; }
+.ri-corner-down-left-fill:before { content: "\f306"; }
+.ri-corner-down-left-line:before { content: "\f307"; }
+.ri-corner-down-right-fill:before { content: "\f308"; }
+.ri-corner-down-right-line:before { content: "\f309"; }
+.ri-corner-left-down-fill:before { content: "\f30a"; }
+.ri-corner-left-down-line:before { content: "\f30b"; }
+.ri-corner-left-up-fill:before { content: "\f30c"; }
+.ri-corner-left-up-line:before { content: "\f30d"; }
+.ri-corner-right-down-fill:before { content: "\f30e"; }
+.ri-corner-right-down-line:before { content: "\f30f"; }
+.ri-corner-right-up-fill:before { content: "\f310"; }
+.ri-corner-right-up-line:before { content: "\f311"; }
+.ri-corner-up-left-double-fill:before { content: "\f312"; }
+.ri-corner-up-left-double-line:before { content: "\f313"; }
+.ri-corner-up-left-fill:before { content: "\f314"; }
+.ri-corner-up-left-line:before { content: "\f315"; }
+.ri-corner-up-right-double-fill:before { content: "\f316"; }
+.ri-corner-up-right-double-line:before { content: "\f317"; }
+.ri-corner-up-right-fill:before { content: "\f318"; }
+.ri-corner-up-right-line:before { content: "\f319"; }
+.ri-cross-fill:before { content: "\f31a"; }
+.ri-cross-line:before { content: "\f31b"; }
+.ri-edge-new-fill:before { content: "\f31c"; }
+.ri-edge-new-line:before { content: "\f31d"; }
+.ri-equal-fill:before { content: "\f31e"; }
+.ri-equal-line:before { content: "\f31f"; }
+.ri-expand-left-fill:before { content: "\f320"; }
+.ri-expand-left-line:before { content: "\f321"; }
+.ri-expand-left-right-fill:before { content: "\f322"; }
+.ri-expand-left-right-line:before { content: "\f323"; }
+.ri-expand-right-fill:before { content: "\f324"; }
+.ri-expand-right-line:before { content: "\f325"; }
+.ri-expand-up-down-fill:before { content: "\f326"; }
+.ri-expand-up-down-line:before { content: "\f327"; }
+.ri-flickr-fill:before { content: "\f328"; }
+.ri-flickr-line:before { content: "\f329"; }
+.ri-forward-10-fill:before { content: "\f32a"; }
+.ri-forward-10-line:before { content: "\f32b"; }
+.ri-forward-15-fill:before { content: "\f32c"; }
+.ri-forward-15-line:before { content: "\f32d"; }
+.ri-forward-30-fill:before { content: "\f32e"; }
+.ri-forward-30-line:before { content: "\f32f"; }
+.ri-forward-5-fill:before { content: "\f330"; }
+.ri-forward-5-line:before { content: "\f331"; }
+.ri-graduation-cap-fill:before { content: "\f332"; }
+.ri-graduation-cap-line:before { content: "\f333"; }
+.ri-home-office-fill:before { content: "\f334"; }
+.ri-home-office-line:before { content: "\f335"; }
+.ri-hourglass-2-fill:before { content: "\f336"; }
+.ri-hourglass-2-line:before { content: "\f337"; }
+.ri-hourglass-fill:before { content: "\f338"; }
+.ri-hourglass-line:before { content: "\f339"; }
+.ri-javascript-fill:before { content: "\f33a"; }
+.ri-javascript-line:before { content: "\f33b"; }
+.ri-loop-left-fill:before { content: "\f33c"; }
+.ri-loop-left-line:before { content: "\f33d"; }
+.ri-loop-right-fill:before { content: "\f33e"; }
+.ri-loop-right-line:before { content: "\f33f"; }
+.ri-memories-fill:before { content: "\f340"; }
+.ri-memories-line:before { content: "\f341"; }
+.ri-meta-fill:before { content: "\f342"; }
+.ri-meta-line:before { content: "\f343"; }
+.ri-microsoft-loop-fill:before { content: "\f344"; }
+.ri-microsoft-loop-line:before { content: "\f345"; }
+.ri-nft-fill:before { content: "\f346"; }
+.ri-nft-line:before { content: "\f347"; }
+.ri-notion-fill:before { content: "\f348"; }
+.ri-notion-line:before { content: "\f349"; }
+.ri-openai-fill:before { content: "\f34a"; }
+.ri-openai-line:before { content: "\f34b"; }
+.ri-overline:before { content: "\f34c"; }
+.ri-p2p-fill:before { content: "\f34d"; }
+.ri-p2p-line:before { content: "\f34e"; }
+.ri-presentation-fill:before { content: "\f34f"; }
+.ri-presentation-line:before { content: "\f350"; }
+.ri-replay-10-fill:before { content: "\f351"; }
+.ri-replay-10-line:before { content: "\f352"; }
+.ri-replay-15-fill:before { content: "\f353"; }
+.ri-replay-15-line:before { content: "\f354"; }
+.ri-replay-30-fill:before { content: "\f355"; }
+.ri-replay-30-line:before { content: "\f356"; }
+.ri-replay-5-fill:before { content: "\f357"; }
+.ri-replay-5-line:before { content: "\f358"; }
+.ri-school-fill:before { content: "\f359"; }
+.ri-school-line:before { content: "\f35a"; }
+.ri-shining-2-fill:before { content: "\f35b"; }
+.ri-shining-2-line:before { content: "\f35c"; }
+.ri-shining-fill:before { content: "\f35d"; }
+.ri-shining-line:before { content: "\f35e"; }
+.ri-sketching:before { content: "\f35f"; }
+.ri-skip-down-fill:before { content: "\f360"; }
+.ri-skip-down-line:before { content: "\f361"; }
+.ri-skip-left-fill:before { content: "\f362"; }
+.ri-skip-left-line:before { content: "\f363"; }
+.ri-skip-right-fill:before { content: "\f364"; }
+.ri-skip-right-line:before { content: "\f365"; }
+.ri-skip-up-fill:before { content: "\f366"; }
+.ri-skip-up-line:before { content: "\f367"; }
+.ri-slow-down-fill:before { content: "\f368"; }
+.ri-slow-down-line:before { content: "\f369"; }
+.ri-sparkling-2-fill:before { content: "\f36a"; }
+.ri-sparkling-2-line:before { content: "\f36b"; }
+.ri-sparkling-fill:before { content: "\f36c"; }
+.ri-sparkling-line:before { content: "\f36d"; }
+.ri-speak-fill:before { content: "\f36e"; }
+.ri-speak-line:before { content: "\f36f"; }
+.ri-speed-up-fill:before { content: "\f370"; }
+.ri-speed-up-line:before { content: "\f371"; }
+.ri-tiktok-fill:before { content: "\f372"; }
+.ri-tiktok-line:before { content: "\f373"; }
+.ri-token-swap-fill:before { content: "\f374"; }
+.ri-token-swap-line:before { content: "\f375"; }
+.ri-unpin-fill:before { content: "\f376"; }
+.ri-unpin-line:before { content: "\f377"; }
+.ri-wechat-channels-fill:before { content: "\f378"; }
+.ri-wechat-channels-line:before { content: "\f379"; }
+.ri-wordpress-fill:before { content: "\f37a"; }
+.ri-wordpress-line:before { content: "\f37b"; }
+.ri-blender-fill:before { content: "\f37c"; }
+.ri-blender-line:before { content: "\f37d"; }
+.ri-emoji-sticker-fill:before { content: "\f37e"; }
+.ri-emoji-sticker-line:before { content: "\f37f"; }
+.ri-git-close-pull-request-fill:before { content: "\f380"; }
+.ri-git-close-pull-request-line:before { content: "\f381"; }
+.ri-instance-fill:before { content: "\f382"; }
+.ri-instance-line:before { content: "\f383"; }
+.ri-megaphone-fill:before { content: "\f384"; }
+.ri-megaphone-line:before { content: "\f385"; }
+.ri-pass-expired-fill:before { content: "\f386"; }
+.ri-pass-expired-line:before { content: "\f387"; }
+.ri-pass-pending-fill:before { content: "\f388"; }
+.ri-pass-pending-line:before { content: "\f389"; }
+.ri-pass-valid-fill:before { content: "\f38a"; }
+.ri-pass-valid-line:before { content: "\f38b"; }
+.ri-ai-generate:before { content: "\f38c"; }
+.ri-calendar-close-fill:before { content: "\f38d"; }
+.ri-calendar-close-line:before { content: "\f38e"; }
+.ri-draggable:before { content: "\f38f"; }
+.ri-font-family:before { content: "\f390"; }
+.ri-font-mono:before { content: "\f391"; }
+.ri-font-sans-serif:before { content: "\f392"; }
+.ri-font-sans:before { content: "\f393"; }
+.ri-hard-drive-3-fill:before { content: "\f394"; }
+.ri-hard-drive-3-line:before { content: "\f395"; }
+.ri-kick-fill:before { content: "\f396"; }
+.ri-kick-line:before { content: "\f397"; }
+.ri-list-check-3:before { content: "\f398"; }
+.ri-list-indefinite:before { content: "\f399"; }
+.ri-list-ordered-2:before { content: "\f39a"; }
+.ri-list-radio:before { content: "\f39b"; }
+.ri-openbase-fill:before { content: "\f39c"; }
+.ri-openbase-line:before { content: "\f39d"; }
+.ri-planet-fill:before { content: "\f39e"; }
+.ri-planet-line:before { content: "\f39f"; }
+.ri-prohibited-fill:before { content: "\f3a0"; }
+.ri-prohibited-line:before { content: "\f3a1"; }
+.ri-quote-text:before { content: "\f3a2"; }
+.ri-seo-fill:before { content: "\f3a3"; }
+.ri-seo-line:before { content: "\f3a4"; }
+.ri-slash-commands:before { content: "\f3a5"; }
+.ri-archive-2-fill:before { content: "\f3a6"; }
+.ri-archive-2-line:before { content: "\f3a7"; }
+.ri-inbox-2-fill:before { content: "\f3a8"; }
+.ri-inbox-2-line:before { content: "\f3a9"; }
+.ri-shake-hands-fill:before { content: "\f3aa"; }
+.ri-shake-hands-line:before { content: "\f3ab"; }
+.ri-supabase-fill:before { content: "\f3ac"; }
+.ri-supabase-line:before { content: "\f3ad"; }
+.ri-water-percent-fill:before { content: "\f3ae"; }
+.ri-water-percent-line:before { content: "\f3af"; }
+.ri-yuque-fill:before { content: "\f3b0"; }
+.ri-yuque-line:before { content: "\f3b1"; }
+.ri-crosshair-2-fill:before { content: "\f3b2"; }
+.ri-crosshair-2-line:before { content: "\f3b3"; }
+.ri-crosshair-fill:before { content: "\f3b4"; }
+.ri-crosshair-line:before { content: "\f3b5"; }
+.ri-file-close-fill:before { content: "\f3b6"; }
+.ri-file-close-line:before { content: "\f3b7"; }
+.ri-infinity-fill:before { content: "\f3b8"; }
+.ri-infinity-line:before { content: "\f3b9"; }
+.ri-rfid-fill:before { content: "\f3ba"; }
+.ri-rfid-line:before { content: "\f3bb"; }
+.ri-slash-commands-2:before { content: "\f3bc"; }
+.ri-user-forbid-fill:before { content: "\f3bd"; }
+.ri-user-forbid-line:before { content: "\f3be"; }
+.ri-beer-fill:before { content: "\f3bf"; }
+.ri-beer-line:before { content: "\f3c0"; }
+.ri-circle-fill:before { content: "\f3c1"; }
+.ri-circle-line:before { content: "\f3c2"; }
+.ri-dropdown-list:before { content: "\f3c3"; }
+.ri-file-image-fill:before { content: "\f3c4"; }
+.ri-file-image-line:before { content: "\f3c5"; }
+.ri-file-pdf-2-fill:before { content: "\f3c6"; }
+.ri-file-pdf-2-line:before { content: "\f3c7"; }
+.ri-file-video-fill:before { content: "\f3c8"; }
+.ri-file-video-line:before { content: "\f3c9"; }
+.ri-folder-image-fill:before { content: "\f3ca"; }
+.ri-folder-image-line:before { content: "\f3cb"; }
+.ri-folder-video-fill:before { content: "\f3cc"; }
+.ri-folder-video-line:before { content: "\f3cd"; }
+.ri-hexagon-fill:before { content: "\f3ce"; }
+.ri-hexagon-line:before { content: "\f3cf"; }
+.ri-menu-search-fill:before { content: "\f3d0"; }
+.ri-menu-search-line:before { content: "\f3d1"; }
+.ri-octagon-fill:before { content: "\f3d2"; }
+.ri-octagon-line:before { content: "\f3d3"; }
+.ri-pentagon-fill:before { content: "\f3d4"; }
+.ri-pentagon-line:before { content: "\f3d5"; }
+.ri-rectangle-fill:before { content: "\f3d6"; }
+.ri-rectangle-line:before { content: "\f3d7"; }
+.ri-robot-2-fill:before { content: "\f3d8"; }
+.ri-robot-2-line:before { content: "\f3d9"; }
+.ri-shapes-fill:before { content: "\f3da"; }
+.ri-shapes-line:before { content: "\f3db"; }
+.ri-square-fill:before { content: "\f3dc"; }
+.ri-square-line:before { content: "\f3dd"; }
+.ri-tent-fill:before { content: "\f3de"; }
+.ri-tent-line:before { content: "\f3df"; }
+.ri-threads-fill:before { content: "\f3e0"; }
+.ri-threads-line:before { content: "\f3e1"; }
+.ri-tree-fill:before { content: "\f3e2"; }
+.ri-tree-line:before { content: "\f3e3"; }
+.ri-triangle-fill:before { content: "\f3e4"; }
+.ri-triangle-line:before { content: "\f3e5"; }
+.ri-twitter-x-fill:before { content: "\f3e6"; }
+.ri-twitter-x-line:before { content: "\f3e7"; }
+.ri-verified-badge-fill:before { content: "\f3e8"; }
+.ri-verified-badge-line:before { content: "\f3e9"; }
+.ri-armchair-fill:before { content: "\f3ea"; }
+.ri-armchair-line:before { content: "\f3eb"; }
+.ri-bnb-fill:before { content: "\f3ec"; }
+.ri-bnb-line:before { content: "\f3ed"; }
+.ri-bread-fill:before { content: "\f3ee"; }
+.ri-bread-line:before { content: "\f3ef"; }
+.ri-btc-fill:before { content: "\f3f0"; }
+.ri-btc-line:before { content: "\f3f1"; }
+.ri-calendar-schedule-fill:before { content: "\f3f2"; }
+.ri-calendar-schedule-line:before { content: "\f3f3"; }
+.ri-dice-1-fill:before { content: "\f3f4"; }
+.ri-dice-1-line:before { content: "\f3f5"; }
+.ri-dice-2-fill:before { content: "\f3f6"; }
+.ri-dice-2-line:before { content: "\f3f7"; }
+.ri-dice-3-fill:before { content: "\f3f8"; }
+.ri-dice-3-line:before { content: "\f3f9"; }
+.ri-dice-4-fill:before { content: "\f3fa"; }
+.ri-dice-4-line:before { content: "\f3fb"; }
+.ri-dice-5-fill:before { content: "\f3fc"; }
+.ri-dice-5-line:before { content: "\f3fd"; }
+.ri-dice-6-fill:before { content: "\f3fe"; }
+.ri-dice-6-line:before { content: "\f3ff"; }
+.ri-dice-fill:before { content: "\f400"; }
+.ri-dice-line:before { content: "\f401"; }
+.ri-drinks-fill:before { content: "\f402"; }
+.ri-drinks-line:before { content: "\f403"; }
+.ri-equalizer-2-fill:before { content: "\f404"; }
+.ri-equalizer-2-line:before { content: "\f405"; }
+.ri-equalizer-3-fill:before { content: "\f406"; }
+.ri-equalizer-3-line:before { content: "\f407"; }
+.ri-eth-fill:before { content: "\f408"; }
+.ri-eth-line:before { content: "\f409"; }
+.ri-flower-fill:before { content: "\f40a"; }
+.ri-flower-line:before { content: "\f40b"; }
+.ri-glasses-2-fill:before { content: "\f40c"; }
+.ri-glasses-2-line:before { content: "\f40d"; }
+.ri-glasses-fill:before { content: "\f40e"; }
+.ri-glasses-line:before { content: "\f40f"; }
+.ri-goggles-fill:before { content: "\f410"; }
+.ri-goggles-line:before { content: "\f411"; }
+.ri-image-circle-fill:before { content: "\f412"; }
+.ri-image-circle-line:before { content: "\f413"; }
+.ri-info-i:before { content: "\f414"; }
+.ri-money-rupee-circle-fill:before { content: "\f415"; }
+.ri-money-rupee-circle-line:before { content: "\f416"; }
+.ri-news-fill:before { content: "\f417"; }
+.ri-news-line:before { content: "\f418"; }
+.ri-robot-3-fill:before { content: "\f419"; }
+.ri-robot-3-line:before { content: "\f41a"; }
+.ri-share-2-fill:before { content: "\f41b"; }
+.ri-share-2-line:before { content: "\f41c"; }
+.ri-sofa-fill:before { content: "\f41d"; }
+.ri-sofa-line:before { content: "\f41e"; }
+.ri-svelte-fill:before { content: "\f41f"; }
+.ri-svelte-line:before { content: "\f420"; }
+.ri-vk-fill:before { content: "\f421"; }
+.ri-vk-line:before { content: "\f422"; }
+.ri-xrp-fill:before { content: "\f423"; }
+.ri-xrp-line:before { content: "\f424"; }
+.ri-xtz-fill:before { content: "\f425"; }
+.ri-xtz-line:before { content: "\f426"; }
+.ri-archive-stack-fill:before { content: "\f427"; }
+.ri-archive-stack-line:before { content: "\f428"; }
+.ri-bowl-fill:before { content: "\f429"; }
+.ri-bowl-line:before { content: "\f42a"; }
+.ri-calendar-view:before { content: "\f42b"; }
+.ri-carousel-view:before { content: "\f42c"; }
+.ri-code-block:before { content: "\f42d"; }
+.ri-color-filter-fill:before { content: "\f42e"; }
+.ri-color-filter-line:before { content: "\f42f"; }
+.ri-contacts-book-3-fill:before { content: "\f430"; }
+.ri-contacts-book-3-line:before { content: "\f431"; }
+.ri-contract-fill:before { content: "\f432"; }
+.ri-contract-line:before { content: "\f433"; }
+.ri-drinks-2-fill:before { content: "\f434"; }
+.ri-drinks-2-line:before { content: "\f435"; }
+.ri-export-fill:before { content: "\f436"; }
+.ri-export-line:before { content: "\f437"; }
+.ri-file-check-fill:before { content: "\f438"; }
+.ri-file-check-line:before { content: "\f439"; }
+.ri-focus-mode:before { content: "\f43a"; }
+.ri-folder-6-fill:before { content: "\f43b"; }
+.ri-folder-6-line:before { content: "\f43c"; }
+.ri-folder-check-fill:before { content: "\f43d"; }
+.ri-folder-check-line:before { content: "\f43e"; }
+.ri-folder-close-fill:before { content: "\f43f"; }
+.ri-folder-close-line:before { content: "\f440"; }
+.ri-folder-cloud-fill:before { content: "\f441"; }
+.ri-folder-cloud-line:before { content: "\f442"; }
+.ri-gallery-view-2:before { content: "\f443"; }
+.ri-gallery-view:before { content: "\f444"; }
+.ri-hand:before { content: "\f445"; }
+.ri-import-fill:before { content: "\f446"; }
+.ri-import-line:before { content: "\f447"; }
+.ri-information-2-fill:before { content: "\f448"; }
+.ri-information-2-line:before { content: "\f449"; }
+.ri-kanban-view-2:before { content: "\f44a"; }
+.ri-kanban-view:before { content: "\f44b"; }
+.ri-list-view:before { content: "\f44c"; }
+.ri-lock-star-fill:before { content: "\f44d"; }
+.ri-lock-star-line:before { content: "\f44e"; }
+.ri-puzzle-2-fill:before { content: "\f44f"; }
+.ri-puzzle-2-line:before { content: "\f450"; }
+.ri-puzzle-fill:before { content: "\f451"; }
+.ri-puzzle-line:before { content: "\f452"; }
+.ri-ram-2-fill:before { content: "\f453"; }
+.ri-ram-2-line:before { content: "\f454"; }
+.ri-ram-fill:before { content: "\f455"; }
+.ri-ram-line:before { content: "\f456"; }
+.ri-receipt-fill:before { content: "\f457"; }
+.ri-receipt-line:before { content: "\f458"; }
+.ri-shadow-fill:before { content: "\f459"; }
+.ri-shadow-line:before { content: "\f45a"; }
+.ri-sidebar-fold-fill:before { content: "\f45b"; }
+.ri-sidebar-fold-line:before { content: "\f45c"; }
+.ri-sidebar-unfold-fill:before { content: "\f45d"; }
+.ri-sidebar-unfold-line:before { content: "\f45e"; }
+.ri-slideshow-view:before { content: "\f45f"; }
+.ri-sort-alphabet-asc:before { content: "\f460"; }
+.ri-sort-alphabet-desc:before { content: "\f461"; }
+.ri-sort-number-asc:before { content: "\f462"; }
+.ri-sort-number-desc:before { content: "\f463"; }
+.ri-stacked-view:before { content: "\f464"; }
+.ri-sticky-note-add-fill:before { content: "\f465"; }
+.ri-sticky-note-add-line:before { content: "\f466"; }
+.ri-swap-2-fill:before { content: "\f467"; }
+.ri-swap-2-line:before { content: "\f468"; }
+.ri-swap-3-fill:before { content: "\f469"; }
+.ri-swap-3-line:before { content: "\f46a"; }
+.ri-table-3:before { content: "\f46b"; }
+.ri-table-view:before { content: "\f46c"; }
+.ri-text-block:before { content: "\f46d"; }
+.ri-text-snippet:before { content: "\f46e"; }
+.ri-timeline-view:before { content: "\f46f"; }
+.ri-blogger-fill:before { content: "\f470"; }
+.ri-blogger-line:before { content: "\f471"; }
+.ri-chat-thread-fill:before { content: "\f472"; }
+.ri-chat-thread-line:before { content: "\f473"; }
+.ri-discount-percent-fill:before { content: "\f474"; }
+.ri-discount-percent-line:before { content: "\f475"; }
+.ri-exchange-2-fill:before { content: "\f476"; }
+.ri-exchange-2-line:before { content: "\f477"; }
+.ri-git-fork-fill:before { content: "\f478"; }
+.ri-git-fork-line:before { content: "\f479"; }
+.ri-input-field:before { content: "\f47a"; }
+.ri-progress-1-fill:before { content: "\f47b"; }
+.ri-progress-1-line:before { content: "\f47c"; }
+.ri-progress-2-fill:before { content: "\f47d"; }
+.ri-progress-2-line:before { content: "\f47e"; }
+.ri-progress-3-fill:before { content: "\f47f"; }
+.ri-progress-3-line:before { content: "\f480"; }
+.ri-progress-4-fill:before { content: "\f481"; }
+.ri-progress-4-line:before { content: "\f482"; }
+.ri-progress-5-fill:before { content: "\f483"; }
+.ri-progress-5-line:before { content: "\f484"; }
+.ri-progress-6-fill:before { content: "\f485"; }
+.ri-progress-6-line:before { content: "\f486"; }
+.ri-progress-7-fill:before { content: "\f487"; }
+.ri-progress-7-line:before { content: "\f488"; }
+.ri-progress-8-fill:before { content: "\f489"; }
+.ri-progress-8-line:before { content: "\f48a"; }
+.ri-remix-run-fill:before { content: "\f48b"; }
+.ri-remix-run-line:before { content: "\f48c"; }
+.ri-signpost-fill:before { content: "\f48d"; }
+.ri-signpost-line:before { content: "\f48e"; }
+.ri-time-zone-fill:before { content: "\f48f"; }
+.ri-time-zone-line:before { content: "\f490"; }
+.ri-arrow-down-wide-fill:before { content: "\f491"; }
+.ri-arrow-down-wide-line:before { content: "\f492"; }
+.ri-arrow-left-wide-fill:before { content: "\f493"; }
+.ri-arrow-left-wide-line:before { content: "\f494"; }
+.ri-arrow-right-wide-fill:before { content: "\f495"; }
+.ri-arrow-right-wide-line:before { content: "\f496"; }
+.ri-arrow-up-wide-fill:before { content: "\f497"; }
+.ri-arrow-up-wide-line:before { content: "\f498"; }
+.ri-bluesky-fill:before { content: "\f499"; }
+.ri-bluesky-line:before { content: "\f49a"; }
+.ri-expand-height-fill:before { content: "\f49b"; }
+.ri-expand-height-line:before { content: "\f49c"; }
+.ri-expand-width-fill:before { content: "\f49d"; }
+.ri-expand-width-line:before { content: "\f49e"; }
+.ri-forward-end-fill:before { content: "\f49f"; }
+.ri-forward-end-line:before { content: "\f4a0"; }
+.ri-forward-end-mini-fill:before { content: "\f4a1"; }
+.ri-forward-end-mini-line:before { content: "\f4a2"; }
+.ri-friendica-fill:before { content: "\f4a3"; }
+.ri-friendica-line:before { content: "\f4a4"; }
+.ri-git-pr-draft-fill:before { content: "\f4a5"; }
+.ri-git-pr-draft-line:before { content: "\f4a6"; }
+.ri-play-reverse-fill:before { content: "\f4a7"; }
+.ri-play-reverse-line:before { content: "\f4a8"; }
+.ri-play-reverse-mini-fill:before { content: "\f4a9"; }
+.ri-play-reverse-mini-line:before { content: "\f4aa"; }
+.ri-rewind-start-fill:before { content: "\f4ab"; }
+.ri-rewind-start-line:before { content: "\f4ac"; }
+.ri-rewind-start-mini-fill:before { content: "\f4ad"; }
+.ri-rewind-start-mini-line:before { content: "\f4ae"; }
+.ri-scroll-to-bottom-fill:before { content: "\f4af"; }
+.ri-scroll-to-bottom-line:before { content: "\f4b0"; }
+.ri-add-large-fill:before { content: "\f4b1"; }
+.ri-add-large-line:before { content: "\f4b2"; }
+.ri-aed-electrodes-fill:before { content: "\f4b3"; }
+.ri-aed-electrodes-line:before { content: "\f4b4"; }
+.ri-aed-fill:before { content: "\f4b5"; }
+.ri-aed-line:before { content: "\f4b6"; }
+.ri-alibaba-cloud-fill:before { content: "\f4b7"; }
+.ri-alibaba-cloud-line:before { content: "\f4b8"; }
+.ri-align-item-bottom-fill:before { content: "\f4b9"; }
+.ri-align-item-bottom-line:before { content: "\f4ba"; }
+.ri-align-item-horizontal-center-fill:before { content: "\f4bb"; }
+.ri-align-item-horizontal-center-line:before { content: "\f4bc"; }
+.ri-align-item-left-fill:before { content: "\f4bd"; }
+.ri-align-item-left-line:before { content: "\f4be"; }
+.ri-align-item-right-fill:before { content: "\f4bf"; }
+.ri-align-item-right-line:before { content: "\f4c0"; }
+.ri-align-item-top-fill:before { content: "\f4c1"; }
+.ri-align-item-top-line:before { content: "\f4c2"; }
+.ri-align-item-vertical-center-fill:before { content: "\f4c3"; }
+.ri-align-item-vertical-center-line:before { content: "\f4c4"; }
+.ri-apps-2-add-fill:before { content: "\f4c5"; }
+.ri-apps-2-add-line:before { content: "\f4c6"; }
+.ri-close-large-fill:before { content: "\f4c7"; }
+.ri-close-large-line:before { content: "\f4c8"; }
+.ri-collapse-diagonal-2-fill:before { content: "\f4c9"; }
+.ri-collapse-diagonal-2-line:before { content: "\f4ca"; }
+.ri-collapse-diagonal-fill:before { content: "\f4cb"; }
+.ri-collapse-diagonal-line:before { content: "\f4cc"; }
+.ri-dashboard-horizontal-fill:before { content: "\f4cd"; }
+.ri-dashboard-horizontal-line:before { content: "\f4ce"; }
+.ri-expand-diagonal-2-fill:before { content: "\f4cf"; }
+.ri-expand-diagonal-2-line:before { content: "\f4d0"; }
+.ri-expand-diagonal-fill:before { content: "\f4d1"; }
+.ri-expand-diagonal-line:before { content: "\f4d2"; }
+.ri-firebase-fill:before { content: "\f4d3"; }
+.ri-firebase-line:before { content: "\f4d4"; }
+.ri-flip-horizontal-2-fill:before { content: "\f4d5"; }
+.ri-flip-horizontal-2-line:before { content: "\f4d6"; }
+.ri-flip-horizontal-fill:before { content: "\f4d7"; }
+.ri-flip-horizontal-line:before { content: "\f4d8"; }
+.ri-flip-vertical-2-fill:before { content: "\f4d9"; }
+.ri-flip-vertical-2-line:before { content: "\f4da"; }
+.ri-flip-vertical-fill:before { content: "\f4db"; }
+.ri-flip-vertical-line:before { content: "\f4dc"; }
+.ri-formula:before { content: "\f4dd"; }
+.ri-function-add-fill:before { content: "\f4de"; }
+.ri-function-add-line:before { content: "\f4df"; }
+.ri-goblet-2-fill:before { content: "\f4e0"; }
+.ri-goblet-2-line:before { content: "\f4e1"; }
+.ri-golf-ball-fill:before { content: "\f4e2"; }
+.ri-golf-ball-line:before { content: "\f4e3"; }
+.ri-group-3-fill:before { content: "\f4e4"; }
+.ri-group-3-line:before { content: "\f4e5"; }
+.ri-heart-add-2-fill:before { content: "\f4e6"; }
+.ri-heart-add-2-line:before { content: "\f4e7"; }
+.ri-id-card-fill:before { content: "\f4e8"; }
+.ri-id-card-line:before { content: "\f4e9"; }
+.ri-information-off-fill:before { content: "\f4ea"; }
+.ri-information-off-line:before { content: "\f4eb"; }
+.ri-java-fill:before { content: "\f4ec"; }
+.ri-java-line:before { content: "\f4ed"; }
+.ri-layout-grid-2-fill:before { content: "\f4ee"; }
+.ri-layout-grid-2-line:before { content: "\f4ef"; }
+.ri-layout-horizontal-fill:before { content: "\f4f0"; }
+.ri-layout-horizontal-line:before { content: "\f4f1"; }
+.ri-layout-vertical-fill:before { content: "\f4f2"; }
+.ri-layout-vertical-line:before { content: "\f4f3"; }
+.ri-menu-fold-2-fill:before { content: "\f4f4"; }
+.ri-menu-fold-2-line:before { content: "\f4f5"; }
+.ri-menu-fold-3-fill:before { content: "\f4f6"; }
+.ri-menu-fold-3-line:before { content: "\f4f7"; }
+.ri-menu-fold-4-fill:before { content: "\f4f8"; }
+.ri-menu-fold-4-line:before { content: "\f4f9"; }
+.ri-menu-unfold-2-fill:before { content: "\f4fa"; }
+.ri-menu-unfold-2-line:before { content: "\f4fb"; }
+.ri-menu-unfold-3-fill:before { content: "\f4fc"; }
+.ri-menu-unfold-3-line:before { content: "\f4fd"; }
+.ri-menu-unfold-4-fill:before { content: "\f4fe"; }
+.ri-menu-unfold-4-line:before { content: "\f4ff"; }
+.ri-mobile-download-fill:before { content: "\f500"; }
+.ri-mobile-download-line:before { content: "\f501"; }
+.ri-nextjs-fill:before { content: "\f502"; }
+.ri-nextjs-line:before { content: "\f503"; }
+.ri-nodejs-fill:before { content: "\f504"; }
+.ri-nodejs-line:before { content: "\f505"; }
+.ri-pause-large-fill:before { content: "\f506"; }
+.ri-pause-large-line:before { content: "\f507"; }
+.ri-play-large-fill:before { content: "\f508"; }
+.ri-play-large-line:before { content: "\f509"; }
+.ri-play-reverse-large-fill:before { content: "\f50a"; }
+.ri-play-reverse-large-line:before { content: "\f50b"; }
+.ri-police-badge-fill:before { content: "\f50c"; }
+.ri-police-badge-line:before { content: "\f50d"; }
+.ri-prohibited-2-fill:before { content: "\f50e"; }
+.ri-prohibited-2-line:before { content: "\f50f"; }
+.ri-shopping-bag-4-fill:before { content: "\f510"; }
+.ri-shopping-bag-4-line:before { content: "\f511"; }
+.ri-snowflake-fill:before { content: "\f512"; }
+.ri-snowflake-line:before { content: "\f513"; }
+.ri-square-root:before { content: "\f514"; }
+.ri-stop-large-fill:before { content: "\f515"; }
+.ri-stop-large-line:before { content: "\f516"; }
+.ri-tailwind-css-fill:before { content: "\f517"; }
+.ri-tailwind-css-line:before { content: "\f518"; }
+.ri-tooth-fill:before { content: "\f519"; }
+.ri-tooth-line:before { content: "\f51a"; }
+.ri-video-off-fill:before { content: "\f51b"; }
+.ri-video-off-line:before { content: "\f51c"; }
+.ri-video-on-fill:before { content: "\f51d"; }
+.ri-video-on-line:before { content: "\f51e"; }
+.ri-webhook-fill:before { content: "\f51f"; }
+.ri-webhook-line:before { content: "\f520"; }
+.ri-weight-fill:before { content: "\f521"; }
+.ri-weight-line:before { content: "\f522"; }
+.ri-book-shelf-fill:before { content: "\f523"; }
+.ri-book-shelf-line:before { content: "\f524"; }
+.ri-brain-2-fill:before { content: "\f525"; }
+.ri-brain-2-line:before { content: "\f526"; }
+.ri-chat-search-fill:before { content: "\f527"; }
+.ri-chat-search-line:before { content: "\f528"; }
+.ri-chat-unread-fill:before { content: "\f529"; }
+.ri-chat-unread-line:before { content: "\f52a"; }
+.ri-collapse-horizontal-fill:before { content: "\f52b"; }
+.ri-collapse-horizontal-line:before { content: "\f52c"; }
+.ri-collapse-vertical-fill:before { content: "\f52d"; }
+.ri-collapse-vertical-line:before { content: "\f52e"; }
+.ri-dna-fill:before { content: "\f52f"; }
+.ri-dna-line:before { content: "\f530"; }
+.ri-dropper-fill:before { content: "\f531"; }
+.ri-dropper-line:before { content: "\f532"; }
+.ri-expand-diagonal-s-2-fill:before { content: "\f533"; }
+.ri-expand-diagonal-s-2-line:before { content: "\f534"; }
+.ri-expand-diagonal-s-fill:before { content: "\f535"; }
+.ri-expand-diagonal-s-line:before { content: "\f536"; }
+.ri-expand-horizontal-fill:before { content: "\f537"; }
+.ri-expand-horizontal-line:before { content: "\f538"; }
+.ri-expand-horizontal-s-fill:before { content: "\f539"; }
+.ri-expand-horizontal-s-line:before { content: "\f53a"; }
+.ri-expand-vertical-fill:before { content: "\f53b"; }
+.ri-expand-vertical-line:before { content: "\f53c"; }
+.ri-expand-vertical-s-fill:before { content: "\f53d"; }
+.ri-expand-vertical-s-line:before { content: "\f53e"; }
+.ri-gemini-fill:before { content: "\f53f"; }
+.ri-gemini-line:before { content: "\f540"; }
+.ri-reset-left-fill:before { content: "\f541"; }
+.ri-reset-left-line:before { content: "\f542"; }
+.ri-reset-right-fill:before { content: "\f543"; }
+.ri-reset-right-line:before { content: "\f544"; }
+.ri-stairs-fill:before { content: "\f545"; }
+.ri-stairs-line:before { content: "\f546"; }
+.ri-telegram-2-fill:before { content: "\f547"; }
+.ri-telegram-2-line:before { content: "\f548"; }
+.ri-triangular-flag-fill:before { content: "\f549"; }
+.ri-triangular-flag-line:before { content: "\f54a"; }
+.ri-user-minus-fill:before { content: "\f54b"; }
+.ri-user-minus-line:before { content: "\f54c"; }
+.ri-account-box-2-fill:before { content: "\f54d"; }
+.ri-account-box-2-line:before { content: "\f54e"; }
+.ri-account-circle-2-fill:before { content: "\f54f"; }
+.ri-account-circle-2-line:before { content: "\f550"; }
+.ri-alarm-snooze-fill:before { content: "\f551"; }
+.ri-alarm-snooze-line:before { content: "\f552"; }
+.ri-arrow-down-box-fill:before { content: "\f553"; }
+.ri-arrow-down-box-line:before { content: "\f554"; }
+.ri-arrow-left-box-fill:before { content: "\f555"; }
+.ri-arrow-left-box-line:before { content: "\f556"; }
+.ri-arrow-left-down-box-fill:before { content: "\f557"; }
+.ri-arrow-left-down-box-line:before { content: "\f558"; }
+.ri-arrow-left-up-box-fill:before { content: "\f559"; }
+.ri-arrow-left-up-box-line:before { content: "\f55a"; }
+.ri-arrow-right-box-fill:before { content: "\f55b"; }
+.ri-arrow-right-box-line:before { content: "\f55c"; }
+.ri-arrow-right-down-box-fill:before { content: "\f55d"; }
+.ri-arrow-right-down-box-line:before { content: "\f55e"; }
+.ri-arrow-right-up-box-fill:before { content: "\f55f"; }
+.ri-arrow-right-up-box-line:before { content: "\f560"; }
+.ri-arrow-up-box-fill:before { content: "\f561"; }
+.ri-arrow-up-box-line:before { content: "\f562"; }
+.ri-bar-chart-box-ai-fill:before { content: "\f563"; }
+.ri-bar-chart-box-ai-line:before { content: "\f564"; }
+.ri-brush-ai-fill:before { content: "\f565"; }
+.ri-brush-ai-line:before { content: "\f566"; }
+.ri-camera-ai-fill:before { content: "\f567"; }
+.ri-camera-ai-line:before { content: "\f568"; }
+.ri-chat-ai-fill:before { content: "\f569"; }
+.ri-chat-ai-line:before { content: "\f56a"; }
+.ri-chat-smile-ai-fill:before { content: "\f56b"; }
+.ri-chat-smile-ai-line:before { content: "\f56c"; }
+.ri-chat-voice-ai-fill:before { content: "\f56d"; }
+.ri-chat-voice-ai-line:before { content: "\f56e"; }
+.ri-code-ai-fill:before { content: "\f56f"; }
+.ri-code-ai-line:before { content: "\f570"; }
+.ri-color-filter-ai-fill:before { content: "\f571"; }
+.ri-color-filter-ai-line:before { content: "\f572"; }
+.ri-custom-size:before { content: "\f573"; }
+.ri-fediverse-fill:before { content: "\f574"; }
+.ri-fediverse-line:before { content: "\f575"; }
+.ri-flag-off-fill:before { content: "\f576"; }
+.ri-flag-off-line:before { content: "\f577"; }
+.ri-home-9-fill:before { content: "\f578"; }
+.ri-home-9-line:before { content: "\f579"; }
+.ri-image-ai-fill:before { content: "\f57a"; }
+.ri-image-ai-line:before { content: "\f57b"; }
+.ri-image-circle-ai-fill:before { content: "\f57c"; }
+.ri-image-circle-ai-line:before { content: "\f57d"; }
+.ri-info-card-fill:before { content: "\f57e"; }
+.ri-info-card-line:before { content: "\f57f"; }
+.ri-landscape-ai-fill:before { content: "\f580"; }
+.ri-landscape-ai-line:before { content: "\f581"; }
+.ri-letter-spacing-2:before { content: "\f582"; }
+.ri-line-height-2:before { content: "\f583"; }
+.ri-mail-ai-fill:before { content: "\f584"; }
+.ri-mail-ai-line:before { content: "\f585"; }
+.ri-mic-2-ai-fill:before { content: "\f586"; }
+.ri-mic-2-ai-line:before { content: "\f587"; }
+.ri-mic-ai-fill:before { content: "\f588"; }
+.ri-mic-ai-line:before { content: "\f589"; }
+.ri-movie-ai-fill:before { content: "\f58a"; }
+.ri-movie-ai-line:before { content: "\f58b"; }
+.ri-music-ai-fill:before { content: "\f58c"; }
+.ri-music-ai-line:before { content: "\f58d"; }
+.ri-notification-snooze-fill:before { content: "\f58e"; }
+.ri-notification-snooze-line:before { content: "\f58f"; }
+.ri-php-fill:before { content: "\f590"; }
+.ri-php-line:before { content: "\f591"; }
+.ri-pix-fill:before { content: "\f592"; }
+.ri-pix-line:before { content: "\f593"; }
+.ri-pulse-ai-fill:before { content: "\f594"; }
+.ri-pulse-ai-line:before { content: "\f595"; }
+.ri-quill-pen-ai-fill:before { content: "\f596"; }
+.ri-quill-pen-ai-line:before { content: "\f597"; }
+.ri-speak-ai-fill:before { content: "\f598"; }
+.ri-speak-ai-line:before { content: "\f599"; }
+.ri-star-off-fill:before { content: "\f59a"; }
+.ri-star-off-line:before { content: "\f59b"; }
+.ri-translate-ai-2:before { content: "\f59c"; }
+.ri-translate-ai:before { content: "\f59d"; }
+.ri-user-community-fill:before { content: "\f59e"; }
+.ri-user-community-line:before { content: "\f59f"; }
+.ri-vercel-fill:before { content: "\f5a0"; }
+.ri-vercel-line:before { content: "\f5a1"; }
+.ri-video-ai-fill:before { content: "\f5a2"; }
+.ri-video-ai-line:before { content: "\f5a3"; }
+.ri-video-on-ai-fill:before { content: "\f5a4"; }
+.ri-video-on-ai-line:before { content: "\f5a5"; }
+.ri-voice-ai-fill:before { content: "\f5a6"; }
+.ri-voice-ai-line:before { content: "\f5a7"; }
+.ri-ai-generate-2:before { content: "\f5a8"; }
+.ri-ai-generate-text:before { content: "\f5a9"; }
+.ri-anthropic-fill:before { content: "\f5aa"; }
+.ri-anthropic-line:before { content: "\f5ab"; }
+.ri-apps-2-ai-fill:before { content: "\f5ac"; }
+.ri-apps-2-ai-line:before { content: "\f5ad"; }
+.ri-camera-lens-ai-fill:before { content: "\f5ae"; }
+.ri-camera-lens-ai-line:before { content: "\f5af"; }
+.ri-clapperboard-ai-fill:before { content: "\f5b0"; }
+.ri-clapperboard-ai-line:before { content: "\f5b1"; }
+.ri-claude-fill:before { content: "\f5b2"; }
+.ri-claude-line:before { content: "\f5b3"; }
+.ri-closed-captioning-ai-fill:before { content: "\f5b4"; }
+.ri-closed-captioning-ai-line:before { content: "\f5b5"; }
+.ri-dvd-ai-fill:before { content: "\f5b6"; }
+.ri-dvd-ai-line:before { content: "\f5b7"; }
+.ri-film-ai-fill:before { content: "\f5b8"; }
+.ri-film-ai-line:before { content: "\f5b9"; }
+.ri-font-size-ai:before { content: "\f5ba"; }
+.ri-mixtral-fill:before { content: "\f5bb"; }
+.ri-mixtral-line:before { content: "\f5bc"; }
+.ri-movie-2-ai-fill:before { content: "\f5bd"; }
+.ri-movie-2-ai-line:before { content: "\f5be"; }
+.ri-mv-ai-fill:before { content: "\f5bf"; }
+.ri-mv-ai-line:before { content: "\f5c0"; }
+.ri-perplexity-fill:before { content: "\f5c1"; }
+.ri-perplexity-line:before { content: "\f5c2"; }
+.ri-poker-clubs-fill:before { content: "\f5c3"; }
+.ri-poker-clubs-line:before { content: "\f5c4"; }
+.ri-poker-diamonds-fill:before { content: "\f5c5"; }
+.ri-poker-diamonds-line:before { content: "\f5c6"; }
+.ri-poker-hearts-fill:before { content: "\f5c7"; }
+.ri-poker-hearts-line:before { content: "\f5c8"; }
+.ri-poker-spades-fill:before { content: "\f5c9"; }
+.ri-poker-spades-line:before { content: "\f5ca"; }
+.ri-safe-3-fill:before { content: "\f5cb"; }
+.ri-safe-3-line:before { content: "\f5cc"; }
+.ri-accessibility-fill:before { content: "\f5cd"; }
+.ri-accessibility-line:before { content: "\f5ce"; }
+.ri-alarm-add-fill:before { content: "\f5cf"; }
+.ri-alarm-add-line:before { content: "\f5d0"; }
+.ri-arrow-down-long-fill:before { content: "\f5d1"; }
+.ri-arrow-down-long-line:before { content: "\f5d2"; }
+.ri-arrow-left-down-long-fill:before { content: "\f5d3"; }
+.ri-arrow-left-down-long-line:before { content: "\f5d4"; }
+.ri-arrow-left-long-fill:before { content: "\f5d5"; }
+.ri-arrow-left-long-line:before { content: "\f5d6"; }
+.ri-arrow-left-up-long-fill:before { content: "\f5d7"; }
+.ri-arrow-left-up-long-line:before { content: "\f5d8"; }
+.ri-arrow-right-down-long-fill:before { content: "\f5d9"; }
+.ri-arrow-right-down-long-line:before { content: "\f5da"; }
+.ri-arrow-right-long-fill:before { content: "\f5db"; }
+.ri-arrow-right-long-line:before { content: "\f5dc"; }
+.ri-arrow-right-up-long-fill:before { content: "\f5dd"; }
+.ri-arrow-right-up-long-line:before { content: "\f5de"; }
+.ri-arrow-up-long-fill:before { content: "\f5df"; }
+.ri-arrow-up-long-line:before { content: "\f5e0"; }
+.ri-chess-fill:before { content: "\f5e1"; }
+.ri-chess-line:before { content: "\f5e2"; }
+.ri-diamond-fill:before { content: "\f5e3"; }
+.ri-diamond-line:before { content: "\f5e4"; }
+.ri-diamond-ring-fill:before { content: "\f5e5"; }
+.ri-diamond-ring-line:before { content: "\f5e6"; }
+.ri-figma-fill:before { content: "\f5e7"; }
+.ri-figma-line:before { content: "\f5e8"; }
+.ri-firefox-browser-fill:before { content: "\f5e9"; }
+.ri-firefox-browser-line:before { content: "\f5ea"; }
+.ri-jewelry-fill:before { content: "\f5eb"; }
+.ri-jewelry-line:before { content: "\f5ec"; }
+.ri-multi-image-fill:before { content: "\f5ed"; }
+.ri-multi-image-line:before { content: "\f5ee"; }
+.ri-no-credit-card-fill:before { content: "\f5ef"; }
+.ri-no-credit-card-line:before { content: "\f5f0"; }
+.ri-service-bell-fill:before { content: "\f5f1"; }
+.ri-service-bell-line:before { content: "\f5f2"; }
+
+.install-app-modal[data-v-40e226b5] .n-modal {
+ max-width: 24rem
+}
+.install-app-modal .modal-content[data-v-40e226b5] {
+ padding: 1rem;
+ padding-bottom: 0px
+}
+.install-app-modal .modal-content .modal-header[data-v-40e226b5] {
+ margin-bottom: 1.5rem;
+ display: flex;
+ align-items: center
+}
+.install-app-modal .modal-content .modal-header .app-icon[data-v-40e226b5] {
+ margin-right: 1rem;
+ height: 5rem;
+ width: 5rem;
+ overflow: hidden;
+ border-radius: 1rem
+}
+.install-app-modal .modal-content .modal-header .app-icon img[data-v-40e226b5] {
+ height: 100%;
+ width: 100%;
+ -o-object-fit: cover;
+ object-fit: cover
+}
+.install-app-modal .modal-content .modal-header .app-info[data-v-40e226b5] {
+ flex: 1 1 0%
+}
+.install-app-modal .modal-content .modal-header .app-info .app-name[data-v-40e226b5] {
+ margin-bottom: 0.25rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700
+}
+.install-app-modal .modal-content .modal-header .app-info .app-desc[data-v-40e226b5] {
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.install-app-modal .modal-content .modal-actions[data-v-40e226b5] {
+ margin-top: 1rem;
+ display: flex;
+ gap: 0.75rem
+}
+.install-app-modal .modal-content .modal-actions .n-button[data-v-40e226b5] {
+ flex: 1 1 0%
+}
+.install-app-modal .modal-content .modal-actions .cancel-btn[data-v-40e226b5] {
+ border-style: none;
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1))
+}
+.install-app-modal .modal-content .modal-actions .cancel-btn[data-v-40e226b5]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1))
+}
+.install-app-modal .modal-content .modal-actions .install-btn[data-v-40e226b5] {
+ border-style: none;
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1))
+}
+.install-app-modal .modal-content .modal-actions .install-btn[data-v-40e226b5]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1))
+}.bottom[data-v-7497922f] {
+ height: 7rem
+}.update-app-modal[data-v-f3abdbb7] .n-modal {
+ max-width: 56rem
+}
+.update-app-modal .modal-content[data-v-f3abdbb7] {
+ padding: 1.5rem;
+ padding-bottom: 1rem
+}
+.update-app-modal .modal-content .modal-header[data-v-f3abdbb7] {
+ margin-bottom: 1.5rem;
+ display: flex;
+ align-items: center
+}
+.update-app-modal .modal-content .modal-header .app-icon[data-v-f3abdbb7] {
+ margin-right: 1.5rem;
+ height: 6rem;
+ width: 6rem;
+ overflow: hidden;
+ border-radius: 1rem
+}
+.update-app-modal .modal-content .modal-header .app-icon img[data-v-f3abdbb7] {
+ height: 100%;
+ width: 100%;
+ -o-object-fit: cover;
+ object-fit: cover
+}
+.update-app-modal .modal-content .modal-header .app-info[data-v-f3abdbb7] {
+ flex: 1 1 0%
+}
+.update-app-modal .modal-content .modal-header .app-info .app-name[data-v-f3abdbb7] {
+ margin-bottom: 0.5rem;
+ font-size: 1.5rem;
+ line-height: 2rem;
+ font-weight: 700
+}
+.update-app-modal .modal-content .modal-header .app-info .app-desc[data-v-f3abdbb7] {
+ font-size: 1rem;
+ line-height: 1.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info[data-v-f3abdbb7] {
+ margin-bottom: 1.5rem;
+ border-radius: 0.5rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .update-info[data-v-f3abdbb7]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-title[data-v-f3abdbb7] {
+ padding: 1rem;
+ padding-bottom: 0.5rem;
+ font-size: 1rem;
+ line-height: 1.5rem;
+ font-weight: 500
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] {
+ padding: 1rem;
+ padding-top: 0.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(75 85 99 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] h1 {
+ margin-bottom: 0.75rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] h2 {
+ margin-bottom: 0.75rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] h3 {
+ margin-bottom: 0.5rem;
+ font-size: 1rem;
+ line-height: 1.5rem;
+ font-weight: 700
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] p {
+ margin-bottom: 0.75rem;
+ line-height: 1.625
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] ul {
+ margin-bottom: 0.75rem;
+ list-style-position: inside;
+ list-style-type: disc
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] ol {
+ margin-bottom: 0.75rem;
+ list-style-position: inside;
+ list-style-type: decimal
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] li {
+ margin-bottom: 0.5rem;
+ line-height: 1.625
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] code {
+ border-radius: 0.25rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+ padding-left: 0.375rem;
+ padding-right: 0.375rem;
+ padding-top: 0.125rem;
+ padding-bottom: 0.125rem;
+ --tw-text-opacity: 1;
+ color: rgb(31 41 55 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] code:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(229 231 235 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] pre {
+ margin-bottom: 0.75rem;
+ overflow-x: auto;
+ border-radius: 0.25rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1));
+ padding: 0.75rem
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] pre:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] pre code {
+ background-color: transparent;
+ padding: 0px
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] blockquote {
+ margin-bottom: 0.75rem;
+ border-left-width: 4px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ padding-left: 1rem
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] blockquote:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] a {
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] a:hover {
+ --tw-text-opacity: 1;
+ color: rgb(22 163 74 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] a:hover:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(74 222 128 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] hr {
+ margin-top: 1rem;
+ margin-bottom: 1rem;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] hr:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table {
+ margin-bottom: 0.75rem;
+ width: 100%
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table th, .update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table td {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table th:is(.dark *), .update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table td:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(75 85 99 / var(--tw-border-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table th {
+ --tw-bg-opacity: 1;
+ background-color: rgb(243 244 246 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .update-info .update-body[data-v-f3abdbb7] table th:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .modal-actions[data-v-f3abdbb7] {
+ margin-top: 1.5rem;
+ display: flex;
+ gap: 1rem
+}
+.update-app-modal .modal-content .modal-actions .n-button[data-v-f3abdbb7] {
+ flex: 1 1 0%;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ font-size: 1rem;
+ line-height: 1.5rem
+}
+.update-app-modal .modal-content .modal-actions .cancel-btn[data-v-f3abdbb7] {
+ border-style: none;
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(209 213 219 / var(--tw-text-opacity, 1))
+}
+.update-app-modal .modal-content .modal-actions .cancel-btn[data-v-f3abdbb7]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(55 65 81 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .modal-actions .update-btn[data-v-f3abdbb7] {
+ border-style: none;
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1))
+}
+.update-app-modal .modal-content .modal-actions .update-btn[data-v-f3abdbb7]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1))
+}.layout-page[data-v-f03a9852] {
+ height: 100vh;
+ width: 100vw;
+ overflow: hidden;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.layout-page[data-v-f03a9852]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.layout-main[data-v-f03a9852] {
+ position: relative;
+ height: 100%;
+ width: 100%;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.layout-main[data-v-f03a9852]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.layout-main-page[data-v-f03a9852] {
+ display: flex;
+ height: 100%;
+}
+.menu[data-v-f03a9852] {
+ height: 100%;
+}
+.main[data-v-f03a9852] {
+ display: flex;
+ flex: 1 1 0%;
+ flex-direction: column;
+ overflow: hidden;
+}
+.main-content[data-v-f03a9852] {
+ flex: 1 1 0%;
+ overflow: hidden;
+}
+.main-page[data-v-f03a9852] {
+ height: 100%;
+}
+.mobile .main-content[data-v-f03a9852] {
+ height: calc(100vh - 146px);
+ overflow: auto;
+ display: block;
+ flex: none;
+}.app-container[data-v-49a312c0] {
+ height: 100%;
+ width: 100%;
+ -webkit-user-select: none;
+ -moz-user-select: none;
+ user-select: none;
+}
+.mobile .text-base[data-v-49a312c0] {
+ font-size: 14px !important;
+}
+.html[data-v-49a312c0]:has(.mobile) {
+ font-size: 14px;
+}.loading-box[data-v-d776f97a] {
+ position: absolute;
+ left: 0;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ width: 100%;
+ height: 100%;
+ overflow: hidden;
+ z-index: 9999;
+}
+.loading-box .mask[data-v-d776f97a] {
+ width: 100%;
+ height: 100%;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.5;
+}
+.loading-box .mask[data-v-d776f97a]:is(.dark *) {
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.5;
+}
+.loading-box .loading-content-box[data-v-d776f97a] {
+ position: absolute;
+ left: 0;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ width: 100%;
+ height: 100%;
+ display: flex;
+ flex-direction: column;
+ justify-content: center;
+ align-items: center;
+}
+.loading-box .tip[data-v-d776f97a] {
+ font-size: 14px;
+ margin-top: 8px;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-ChDcb7c6.css.gz b/out/renderer/assets/index-ChDcb7c6.css.gz
new file mode 100644
index 0000000..9f35491
Binary files /dev/null and b/out/renderer/assets/index-ChDcb7c6.css.gz differ
diff --git a/out/renderer/assets/index-CzpNk4J5.css b/out/renderer/assets/index-CzpNk4J5.css
new file mode 100644
index 0000000..d9e01e1
--- /dev/null
+++ b/out/renderer/assets/index-CzpNk4J5.css
@@ -0,0 +1,172 @@
+.search-item[data-v-3449f610] {
+ display: flex;
+ cursor: pointer;
+ align-items: center;
+ border-radius: 1.5rem;
+ padding: 0.75rem;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}.search-item[data-v-3449f610]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(233 236 239 / var(--tw-bg-opacity, 1));
+}.search-item[data-v-3449f610]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+}.search-item[data-v-3449f610] {
+ margin: 0 10px;
+}
+.search-item .search-item-img[data-v-3449f610] {
+ margin-right: 1rem;
+ height: 3rem;
+ width: 3rem;
+ overflow: hidden;
+ border-radius: 1rem;
+}
+.search-item .search-item-info[data-v-3449f610] {
+ flex: 1 1 0%;
+ overflow: hidden;
+}
+.search-item .search-item-info-name[data-v-3449f610] {
+ text-align: center;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.search-item .search-item-info-artist[data-v-3449f610] {
+ text-align: center;
+ font-size: 0.75rem;
+ line-height: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.mv:hover .play[data-v-3449f610] {
+ opacity: 0.6;
+}
+.mv .search-item-img[data-v-3449f610] {
+ width: 160px;
+ height: 90px;
+ position: relative;
+ border-radius: 0.5rem;
+}
+.mv .play[data-v-3449f610] {
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ --tw-translate-x: -50%;
+ --tw-translate-y: -50%;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+ opacity: 0;
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.mv .play .icon[data-v-3449f610] {
+ font-size: 3rem;
+ line-height: 1;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}.search-page[data-v-254ebbc1] {
+ display: flex;
+ height: 100%;
+}
+.hot-search[data-v-254ebbc1] {
+ margin-right: 1rem;
+ flex: 1 1 0%;
+ overflow: hidden;
+ border-radius: 0.75rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+}
+.hot-search[data-v-254ebbc1]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+}
+.hot-search[data-v-254ebbc1] {
+ animation-duration: 0.2s;
+ min-width: 400px;
+ height: 100%;
+}
+.hot-search-list[data-v-254ebbc1] {
+ padding-bottom: 7rem;
+}
+.hot-search-item[data-v-254ebbc1] {
+ cursor: pointer;
+ border-radius: 0.75rem;
+ padding-left: 1rem;
+ padding-right: 1rem;
+ padding-top: 0.75rem;
+ padding-bottom: 0.75rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.hot-search-item[data-v-254ebbc1]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.hot-search-item[data-v-254ebbc1] {
+ transition: all 0.3s ease;
+}
+.hot-search-item[data-v-254ebbc1]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+}
+.hot-search-item[data-v-254ebbc1]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(45 45 45 / var(--tw-bg-opacity, 1));
+}
+.hot-search-item-count[data-v-254ebbc1] {
+ margin-left: 0.75rem;
+ display: inline-block;
+ width: 2rem;
+ --tw-text-opacity: 1;
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1));
+}
+.hot-search-item-count-3[data-v-254ebbc1] {
+ margin-left: 0.75rem;
+ display: inline-block;
+ width: 2rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(239 68 68 / var(--tw-text-opacity, 1));
+}
+.search-list[data-v-254ebbc1] {
+ flex: 1 1 0%;
+ border-radius: 0.75rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+}
+.search-list[data-v-254ebbc1]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+}
+.search-list[data-v-254ebbc1] {
+ height: 100%;
+}
+.search-list-box[data-v-254ebbc1] {
+ padding-bottom: 7rem;
+}
+.title[data-v-254ebbc1] {
+ margin-top: 0.5rem;
+ margin-bottom: 0.5rem;
+ margin-left: 1rem;
+ margin-right: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.title[data-v-254ebbc1]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mobile .hot-search[data-v-254ebbc1] {
+ margin-right: 0px;
+ width: 100%;
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-CzpNk4J5.css.gz b/out/renderer/assets/index-CzpNk4J5.css.gz
new file mode 100644
index 0000000..b428f7d
Binary files /dev/null and b/out/renderer/assets/index-CzpNk4J5.css.gz differ
diff --git a/out/renderer/assets/index-DKaFsuse.js b/out/renderer/assets/index-DKaFsuse.js
new file mode 100644
index 0000000..8a78114
--- /dev/null
+++ b/out/renderer/assets/index-DKaFsuse.js
@@ -0,0 +1,34584 @@
+const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-DSilVM87.js","./home-BXGE9AqN.js","./MusicList-s-QHu-iA.js","./SongItem-CoswpGn6.js","./Image-DXClIklC.js","./use-locale-DLWAOXez.js","./Ellipsis-D4R5dIX2.js","./SongItem-Bw5Qa7XV.css","./Drawer-BEJ8Ydua.js","./Avatar-rQ2og-6c.js","./Tag-C0oC92WF.js","./MusicList-NCsRWE81.css","./index-JJypdZPY.js","./index-B-m4kL_6.css","./index-BlaUC8oz.css","./index-C-VCusx9.js","./MvPlayer-I4IDK1xL.js","./Icon-DucaliTK.js","./Slider-BA6NituQ.js","./MvPlayer-BPFZslTY.css","./Layout-CvYBg1vI.js","./index-CzpNk4J5.css","./index-Bc5fdT5j.js","./index-s6QFASec.css","./index-SvIREzLs.js","./index-b8HibJP6.css","./index-DhLgZEXT.js","./index-BmgzcEyo.css","./index-BPmJoRDi.js","./index-COH3Oisr.css","./index-RCxsGzpS.js","./Switch-D3Z_Vg3u.js","./index-DVDStqOk.css","./AppMenu-CbDXL_JE.js","./AppMenu-iZYnVe2B.css","./PlayBar-BNzUvTGp.js","./PlayBar-Ct36doNR.css","./SearchBar-Cx7zzS9t.js","./login-BsPxQYi6.js","./SearchBar-CIYxJjXH.css","./TitleBar-Bl1cFyS0.js","./TitleBar-DxNBjVsT.css","./index-Dn0J0Jmw.js","./index-DcmHQdN6.css","./index-BCv4VDKm.js","./index-BE7j41Na.css"])))=>i.map(i=>d[i]);
+/**
+* @vue/shared v3.5.13
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/
+/*! #__NO_SIDE_EFFECTS__ */
+// @__NO_SIDE_EFFECTS__
+function makeMap(str) {
+ const map = /* @__PURE__ */ Object.create(null);
+ for (const key of str.split(",")) map[key] = 1;
+ return (val) => val in map;
+}
+const EMPTY_OBJ = {};
+const EMPTY_ARR = [];
+const NOOP = () => {
+};
+const NO = () => false;
+const isOn = (key) => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && // uppercase letter
+(key.charCodeAt(2) > 122 || key.charCodeAt(2) < 97);
+const isModelListener = (key) => key.startsWith("onUpdate:");
+const extend$1 = Object.assign;
+const remove = (arr, el) => {
+ const i = arr.indexOf(el);
+ if (i > -1) {
+ arr.splice(i, 1);
+ }
+};
+const hasOwnProperty$b = Object.prototype.hasOwnProperty;
+const hasOwn = (val, key) => hasOwnProperty$b.call(val, key);
+const isArray$3 = Array.isArray;
+const isMap = (val) => toTypeString(val) === "[object Map]";
+const isSet = (val) => toTypeString(val) === "[object Set]";
+const isRegExp$1 = (val) => toTypeString(val) === "[object RegExp]";
+const isFunction$2 = (val) => typeof val === "function";
+const isString$1 = (val) => typeof val === "string";
+const isSymbol$1 = (val) => typeof val === "symbol";
+const isObject$4 = (val) => val !== null && typeof val === "object";
+const isPromise$1 = (val) => {
+ return (isObject$4(val) || isFunction$2(val)) && isFunction$2(val.then) && isFunction$2(val.catch);
+};
+const objectToString$1 = Object.prototype.toString;
+const toTypeString = (value) => objectToString$1.call(value);
+const toRawType = (value) => {
+ return toTypeString(value).slice(8, -1);
+};
+const isPlainObject$2 = (val) => toTypeString(val) === "[object Object]";
+const isIntegerKey = (key) => isString$1(key) && key !== "NaN" && key[0] !== "-" && "" + parseInt(key, 10) === key;
+const isReservedProp = /* @__PURE__ */ makeMap(
+ // the leading comma is intentional so empty string "" is also included
+ ",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"
+);
+const cacheStringFunction = (fn) => {
+ const cache2 = /* @__PURE__ */ Object.create(null);
+ return (str) => {
+ const hit = cache2[str];
+ return hit || (cache2[str] = fn(str));
+ };
+};
+const camelizeRE = /-(\w)/g;
+const camelize = cacheStringFunction(
+ (str) => {
+ return str.replace(camelizeRE, (_, c2) => c2 ? c2.toUpperCase() : "");
+ }
+);
+const hyphenateRE = /\B([A-Z])/g;
+const hyphenate = cacheStringFunction(
+ (str) => str.replace(hyphenateRE, "-$1").toLowerCase()
+);
+const capitalize = cacheStringFunction((str) => {
+ return str.charAt(0).toUpperCase() + str.slice(1);
+});
+const toHandlerKey = cacheStringFunction(
+ (str) => {
+ const s = str ? `on${capitalize(str)}` : ``;
+ return s;
+ }
+);
+const hasChanged = (value, oldValue) => !Object.is(value, oldValue);
+const invokeArrayFns = (fns, ...arg) => {
+ for (let i = 0; i < fns.length; i++) {
+ fns[i](...arg);
+ }
+};
+const def$1 = (obj, key, value, writable = false) => {
+ Object.defineProperty(obj, key, {
+ configurable: true,
+ enumerable: false,
+ writable,
+ value
+ });
+};
+const looseToNumber = (val) => {
+ const n = parseFloat(val);
+ return isNaN(n) ? val : n;
+};
+const toNumber = (val) => {
+ const n = isString$1(val) ? Number(val) : NaN;
+ return isNaN(n) ? val : n;
+};
+let _globalThis;
+const getGlobalThis = () => {
+ return _globalThis || (_globalThis = typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : {});
+};
+function normalizeStyle(value) {
+ if (isArray$3(value)) {
+ const res = {};
+ for (let i = 0; i < value.length; i++) {
+ const item = value[i];
+ const normalized = isString$1(item) ? parseStringStyle(item) : normalizeStyle(item);
+ if (normalized) {
+ for (const key in normalized) {
+ res[key] = normalized[key];
+ }
+ }
+ }
+ return res;
+ } else if (isString$1(value) || isObject$4(value)) {
+ return value;
+ }
+}
+const listDelimiterRE = /;(?![^(]*\))/g;
+const propertyDelimiterRE = /:([^]+)/;
+const styleCommentRE = /\/\*[^]*?\*\//g;
+function parseStringStyle(cssText) {
+ const ret = {};
+ cssText.replace(styleCommentRE, "").split(listDelimiterRE).forEach((item) => {
+ if (item) {
+ const tmp = item.split(propertyDelimiterRE);
+ tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());
+ }
+ });
+ return ret;
+}
+function normalizeClass(value) {
+ let res = "";
+ if (isString$1(value)) {
+ res = value;
+ } else if (isArray$3(value)) {
+ for (let i = 0; i < value.length; i++) {
+ const normalized = normalizeClass(value[i]);
+ if (normalized) {
+ res += normalized + " ";
+ }
+ }
+ } else if (isObject$4(value)) {
+ for (const name2 in value) {
+ if (value[name2]) {
+ res += name2 + " ";
+ }
+ }
+ }
+ return res.trim();
+}
+const specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;
+const isSpecialBooleanAttr = /* @__PURE__ */ makeMap(specialBooleanAttrs);
+function includeBooleanAttr(value) {
+ return !!value || value === "";
+}
+const isRef$1 = (val) => {
+ return !!(val && val["__v_isRef"] === true);
+};
+const toDisplayString = (val) => {
+ return isString$1(val) ? val : val == null ? "" : isArray$3(val) || isObject$4(val) && (val.toString === objectToString$1 || !isFunction$2(val.toString)) ? isRef$1(val) ? toDisplayString(val.value) : JSON.stringify(val, replacer, 2) : String(val);
+};
+const replacer = (_key, val) => {
+ if (isRef$1(val)) {
+ return replacer(_key, val.value);
+ } else if (isMap(val)) {
+ return {
+ [`Map(${val.size})`]: [...val.entries()].reduce(
+ (entries, [key, val2], i) => {
+ entries[stringifySymbol(key, i) + " =>"] = val2;
+ return entries;
+ },
+ {}
+ )
+ };
+ } else if (isSet(val)) {
+ return {
+ [`Set(${val.size})`]: [...val.values()].map((v) => stringifySymbol(v))
+ };
+ } else if (isSymbol$1(val)) {
+ return stringifySymbol(val);
+ } else if (isObject$4(val) && !isArray$3(val) && !isPlainObject$2(val)) {
+ return String(val);
+ }
+ return val;
+};
+const stringifySymbol = (v, i = "") => {
+ var _a;
+ return (
+ // Symbol.description in es2019+ so we need to cast here to pass
+ // the lib: es2016 check
+ isSymbol$1(v) ? `Symbol(${(_a = v.description) != null ? _a : i})` : v
+ );
+};
+/**
+* @vue/reactivity v3.5.13
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/
+let activeEffectScope;
+class EffectScope {
+ constructor(detached = false) {
+ this.detached = detached;
+ this._active = true;
+ this.effects = [];
+ this.cleanups = [];
+ this._isPaused = false;
+ this.parent = activeEffectScope;
+ if (!detached && activeEffectScope) {
+ this.index = (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(
+ this
+ ) - 1;
+ }
+ }
+ get active() {
+ return this._active;
+ }
+ pause() {
+ if (this._active) {
+ this._isPaused = true;
+ let i, l;
+ if (this.scopes) {
+ for (i = 0, l = this.scopes.length; i < l; i++) {
+ this.scopes[i].pause();
+ }
+ }
+ for (i = 0, l = this.effects.length; i < l; i++) {
+ this.effects[i].pause();
+ }
+ }
+ }
+ /**
+ * Resumes the effect scope, including all child scopes and effects.
+ */
+ resume() {
+ if (this._active) {
+ if (this._isPaused) {
+ this._isPaused = false;
+ let i, l;
+ if (this.scopes) {
+ for (i = 0, l = this.scopes.length; i < l; i++) {
+ this.scopes[i].resume();
+ }
+ }
+ for (i = 0, l = this.effects.length; i < l; i++) {
+ this.effects[i].resume();
+ }
+ }
+ }
+ }
+ run(fn) {
+ if (this._active) {
+ const currentEffectScope = activeEffectScope;
+ try {
+ activeEffectScope = this;
+ return fn();
+ } finally {
+ activeEffectScope = currentEffectScope;
+ }
+ }
+ }
+ /**
+ * This should only be called on non-detached scopes
+ * @internal
+ */
+ on() {
+ activeEffectScope = this;
+ }
+ /**
+ * This should only be called on non-detached scopes
+ * @internal
+ */
+ off() {
+ activeEffectScope = this.parent;
+ }
+ stop(fromParent) {
+ if (this._active) {
+ this._active = false;
+ let i, l;
+ for (i = 0, l = this.effects.length; i < l; i++) {
+ this.effects[i].stop();
+ }
+ this.effects.length = 0;
+ for (i = 0, l = this.cleanups.length; i < l; i++) {
+ this.cleanups[i]();
+ }
+ this.cleanups.length = 0;
+ if (this.scopes) {
+ for (i = 0, l = this.scopes.length; i < l; i++) {
+ this.scopes[i].stop(true);
+ }
+ this.scopes.length = 0;
+ }
+ if (!this.detached && this.parent && !fromParent) {
+ const last = this.parent.scopes.pop();
+ if (last && last !== this) {
+ this.parent.scopes[this.index] = last;
+ last.index = this.index;
+ }
+ }
+ this.parent = void 0;
+ }
+ }
+}
+function effectScope(detached) {
+ return new EffectScope(detached);
+}
+function getCurrentScope() {
+ return activeEffectScope;
+}
+function onScopeDispose(fn, failSilently = false) {
+ if (activeEffectScope) {
+ activeEffectScope.cleanups.push(fn);
+ }
+}
+let activeSub;
+const pausedQueueEffects = /* @__PURE__ */ new WeakSet();
+class ReactiveEffect {
+ constructor(fn) {
+ this.fn = fn;
+ this.deps = void 0;
+ this.depsTail = void 0;
+ this.flags = 1 | 4;
+ this.next = void 0;
+ this.cleanup = void 0;
+ this.scheduler = void 0;
+ if (activeEffectScope && activeEffectScope.active) {
+ activeEffectScope.effects.push(this);
+ }
+ }
+ pause() {
+ this.flags |= 64;
+ }
+ resume() {
+ if (this.flags & 64) {
+ this.flags &= ~64;
+ if (pausedQueueEffects.has(this)) {
+ pausedQueueEffects.delete(this);
+ this.trigger();
+ }
+ }
+ }
+ /**
+ * @internal
+ */
+ notify() {
+ if (this.flags & 2 && !(this.flags & 32)) {
+ return;
+ }
+ if (!(this.flags & 8)) {
+ batch(this);
+ }
+ }
+ run() {
+ if (!(this.flags & 1)) {
+ return this.fn();
+ }
+ this.flags |= 2;
+ cleanupEffect(this);
+ prepareDeps(this);
+ const prevEffect = activeSub;
+ const prevShouldTrack = shouldTrack;
+ activeSub = this;
+ shouldTrack = true;
+ try {
+ return this.fn();
+ } finally {
+ cleanupDeps(this);
+ activeSub = prevEffect;
+ shouldTrack = prevShouldTrack;
+ this.flags &= ~2;
+ }
+ }
+ stop() {
+ if (this.flags & 1) {
+ for (let link2 = this.deps; link2; link2 = link2.nextDep) {
+ removeSub(link2);
+ }
+ this.deps = this.depsTail = void 0;
+ cleanupEffect(this);
+ this.onStop && this.onStop();
+ this.flags &= ~1;
+ }
+ }
+ trigger() {
+ if (this.flags & 64) {
+ pausedQueueEffects.add(this);
+ } else if (this.scheduler) {
+ this.scheduler();
+ } else {
+ this.runIfDirty();
+ }
+ }
+ /**
+ * @internal
+ */
+ runIfDirty() {
+ if (isDirty(this)) {
+ this.run();
+ }
+ }
+ get dirty() {
+ return isDirty(this);
+ }
+}
+let batchDepth = 0;
+let batchedSub;
+let batchedComputed;
+function batch(sub, isComputed = false) {
+ sub.flags |= 8;
+ if (isComputed) {
+ sub.next = batchedComputed;
+ batchedComputed = sub;
+ return;
+ }
+ sub.next = batchedSub;
+ batchedSub = sub;
+}
+function startBatch() {
+ batchDepth++;
+}
+function endBatch() {
+ if (--batchDepth > 0) {
+ return;
+ }
+ if (batchedComputed) {
+ let e = batchedComputed;
+ batchedComputed = void 0;
+ while (e) {
+ const next = e.next;
+ e.next = void 0;
+ e.flags &= ~8;
+ e = next;
+ }
+ }
+ let error;
+ while (batchedSub) {
+ let e = batchedSub;
+ batchedSub = void 0;
+ while (e) {
+ const next = e.next;
+ e.next = void 0;
+ e.flags &= ~8;
+ if (e.flags & 1) {
+ try {
+ ;
+ e.trigger();
+ } catch (err) {
+ if (!error) error = err;
+ }
+ }
+ e = next;
+ }
+ }
+ if (error) throw error;
+}
+function prepareDeps(sub) {
+ for (let link2 = sub.deps; link2; link2 = link2.nextDep) {
+ link2.version = -1;
+ link2.prevActiveLink = link2.dep.activeLink;
+ link2.dep.activeLink = link2;
+ }
+}
+function cleanupDeps(sub) {
+ let head;
+ let tail = sub.depsTail;
+ let link2 = tail;
+ while (link2) {
+ const prev = link2.prevDep;
+ if (link2.version === -1) {
+ if (link2 === tail) tail = prev;
+ removeSub(link2);
+ removeDep(link2);
+ } else {
+ head = link2;
+ }
+ link2.dep.activeLink = link2.prevActiveLink;
+ link2.prevActiveLink = void 0;
+ link2 = prev;
+ }
+ sub.deps = head;
+ sub.depsTail = tail;
+}
+function isDirty(sub) {
+ for (let link2 = sub.deps; link2; link2 = link2.nextDep) {
+ if (link2.dep.version !== link2.version || link2.dep.computed && (refreshComputed(link2.dep.computed) || link2.dep.version !== link2.version)) {
+ return true;
+ }
+ }
+ if (sub._dirty) {
+ return true;
+ }
+ return false;
+}
+function refreshComputed(computed2) {
+ if (computed2.flags & 4 && !(computed2.flags & 16)) {
+ return;
+ }
+ computed2.flags &= ~16;
+ if (computed2.globalVersion === globalVersion) {
+ return;
+ }
+ computed2.globalVersion = globalVersion;
+ const dep = computed2.dep;
+ computed2.flags |= 2;
+ if (dep.version > 0 && !computed2.isSSR && computed2.deps && !isDirty(computed2)) {
+ computed2.flags &= ~2;
+ return;
+ }
+ const prevSub = activeSub;
+ const prevShouldTrack = shouldTrack;
+ activeSub = computed2;
+ shouldTrack = true;
+ try {
+ prepareDeps(computed2);
+ const value = computed2.fn(computed2._value);
+ if (dep.version === 0 || hasChanged(value, computed2._value)) {
+ computed2._value = value;
+ dep.version++;
+ }
+ } catch (err) {
+ dep.version++;
+ throw err;
+ } finally {
+ activeSub = prevSub;
+ shouldTrack = prevShouldTrack;
+ cleanupDeps(computed2);
+ computed2.flags &= ~2;
+ }
+}
+function removeSub(link2, soft = false) {
+ const { dep, prevSub, nextSub } = link2;
+ if (prevSub) {
+ prevSub.nextSub = nextSub;
+ link2.prevSub = void 0;
+ }
+ if (nextSub) {
+ nextSub.prevSub = prevSub;
+ link2.nextSub = void 0;
+ }
+ if (dep.subs === link2) {
+ dep.subs = prevSub;
+ if (!prevSub && dep.computed) {
+ dep.computed.flags &= ~4;
+ for (let l = dep.computed.deps; l; l = l.nextDep) {
+ removeSub(l, true);
+ }
+ }
+ }
+ if (!soft && !--dep.sc && dep.map) {
+ dep.map.delete(dep.key);
+ }
+}
+function removeDep(link2) {
+ const { prevDep, nextDep } = link2;
+ if (prevDep) {
+ prevDep.nextDep = nextDep;
+ link2.prevDep = void 0;
+ }
+ if (nextDep) {
+ nextDep.prevDep = prevDep;
+ link2.nextDep = void 0;
+ }
+}
+let shouldTrack = true;
+const trackStack = [];
+function pauseTracking() {
+ trackStack.push(shouldTrack);
+ shouldTrack = false;
+}
+function resetTracking() {
+ const last = trackStack.pop();
+ shouldTrack = last === void 0 ? true : last;
+}
+function cleanupEffect(e) {
+ const { cleanup } = e;
+ e.cleanup = void 0;
+ if (cleanup) {
+ const prevSub = activeSub;
+ activeSub = void 0;
+ try {
+ cleanup();
+ } finally {
+ activeSub = prevSub;
+ }
+ }
+}
+let globalVersion = 0;
+class Link {
+ constructor(sub, dep) {
+ this.sub = sub;
+ this.dep = dep;
+ this.version = dep.version;
+ this.nextDep = this.prevDep = this.nextSub = this.prevSub = this.prevActiveLink = void 0;
+ }
+}
+class Dep {
+ constructor(computed2) {
+ this.computed = computed2;
+ this.version = 0;
+ this.activeLink = void 0;
+ this.subs = void 0;
+ this.map = void 0;
+ this.key = void 0;
+ this.sc = 0;
+ }
+ track(debugInfo) {
+ if (!activeSub || !shouldTrack || activeSub === this.computed) {
+ return;
+ }
+ let link2 = this.activeLink;
+ if (link2 === void 0 || link2.sub !== activeSub) {
+ link2 = this.activeLink = new Link(activeSub, this);
+ if (!activeSub.deps) {
+ activeSub.deps = activeSub.depsTail = link2;
+ } else {
+ link2.prevDep = activeSub.depsTail;
+ activeSub.depsTail.nextDep = link2;
+ activeSub.depsTail = link2;
+ }
+ addSub(link2);
+ } else if (link2.version === -1) {
+ link2.version = this.version;
+ if (link2.nextDep) {
+ const next = link2.nextDep;
+ next.prevDep = link2.prevDep;
+ if (link2.prevDep) {
+ link2.prevDep.nextDep = next;
+ }
+ link2.prevDep = activeSub.depsTail;
+ link2.nextDep = void 0;
+ activeSub.depsTail.nextDep = link2;
+ activeSub.depsTail = link2;
+ if (activeSub.deps === link2) {
+ activeSub.deps = next;
+ }
+ }
+ }
+ return link2;
+ }
+ trigger(debugInfo) {
+ this.version++;
+ globalVersion++;
+ this.notify(debugInfo);
+ }
+ notify(debugInfo) {
+ startBatch();
+ try {
+ if (false) ;
+ for (let link2 = this.subs; link2; link2 = link2.prevSub) {
+ if (link2.sub.notify()) {
+ ;
+ link2.sub.dep.notify();
+ }
+ }
+ } finally {
+ endBatch();
+ }
+ }
+}
+function addSub(link2) {
+ link2.dep.sc++;
+ if (link2.sub.flags & 4) {
+ const computed2 = link2.dep.computed;
+ if (computed2 && !link2.dep.subs) {
+ computed2.flags |= 4 | 16;
+ for (let l = computed2.deps; l; l = l.nextDep) {
+ addSub(l);
+ }
+ }
+ const currentTail = link2.dep.subs;
+ if (currentTail !== link2) {
+ link2.prevSub = currentTail;
+ if (currentTail) currentTail.nextSub = link2;
+ }
+ link2.dep.subs = link2;
+ }
+}
+const targetMap = /* @__PURE__ */ new WeakMap();
+const ITERATE_KEY = Symbol(
+ ""
+);
+const MAP_KEY_ITERATE_KEY = Symbol(
+ ""
+);
+const ARRAY_ITERATE_KEY = Symbol(
+ ""
+);
+function track(target, type, key) {
+ if (shouldTrack && activeSub) {
+ let depsMap = targetMap.get(target);
+ if (!depsMap) {
+ targetMap.set(target, depsMap = /* @__PURE__ */ new Map());
+ }
+ let dep = depsMap.get(key);
+ if (!dep) {
+ depsMap.set(key, dep = new Dep());
+ dep.map = depsMap;
+ dep.key = key;
+ }
+ {
+ dep.track();
+ }
+ }
+}
+function trigger$1(target, type, key, newValue, oldValue, oldTarget) {
+ const depsMap = targetMap.get(target);
+ if (!depsMap) {
+ globalVersion++;
+ return;
+ }
+ const run = (dep) => {
+ if (dep) {
+ {
+ dep.trigger();
+ }
+ }
+ };
+ startBatch();
+ if (type === "clear") {
+ depsMap.forEach(run);
+ } else {
+ const targetIsArray = isArray$3(target);
+ const isArrayIndex = targetIsArray && isIntegerKey(key);
+ if (targetIsArray && key === "length") {
+ const newLength = Number(newValue);
+ depsMap.forEach((dep, key2) => {
+ if (key2 === "length" || key2 === ARRAY_ITERATE_KEY || !isSymbol$1(key2) && key2 >= newLength) {
+ run(dep);
+ }
+ });
+ } else {
+ if (key !== void 0 || depsMap.has(void 0)) {
+ run(depsMap.get(key));
+ }
+ if (isArrayIndex) {
+ run(depsMap.get(ARRAY_ITERATE_KEY));
+ }
+ switch (type) {
+ case "add":
+ if (!targetIsArray) {
+ run(depsMap.get(ITERATE_KEY));
+ if (isMap(target)) {
+ run(depsMap.get(MAP_KEY_ITERATE_KEY));
+ }
+ } else if (isArrayIndex) {
+ run(depsMap.get("length"));
+ }
+ break;
+ case "delete":
+ if (!targetIsArray) {
+ run(depsMap.get(ITERATE_KEY));
+ if (isMap(target)) {
+ run(depsMap.get(MAP_KEY_ITERATE_KEY));
+ }
+ }
+ break;
+ case "set":
+ if (isMap(target)) {
+ run(depsMap.get(ITERATE_KEY));
+ }
+ break;
+ }
+ }
+ }
+ endBatch();
+}
+function getDepFromReactive(object, key) {
+ const depMap = targetMap.get(object);
+ return depMap && depMap.get(key);
+}
+function reactiveReadArray(array) {
+ const raw = toRaw(array);
+ if (raw === array) return raw;
+ track(raw, "iterate", ARRAY_ITERATE_KEY);
+ return isShallow(array) ? raw : raw.map(toReactive);
+}
+function shallowReadArray(arr) {
+ track(arr = toRaw(arr), "iterate", ARRAY_ITERATE_KEY);
+ return arr;
+}
+const arrayInstrumentations = {
+ __proto__: null,
+ [Symbol.iterator]() {
+ return iterator(this, Symbol.iterator, toReactive);
+ },
+ concat(...args) {
+ return reactiveReadArray(this).concat(
+ ...args.map((x) => isArray$3(x) ? reactiveReadArray(x) : x)
+ );
+ },
+ entries() {
+ return iterator(this, "entries", (value) => {
+ value[1] = toReactive(value[1]);
+ return value;
+ });
+ },
+ every(fn, thisArg) {
+ return apply$1(this, "every", fn, thisArg, void 0, arguments);
+ },
+ filter(fn, thisArg) {
+ return apply$1(this, "filter", fn, thisArg, (v) => v.map(toReactive), arguments);
+ },
+ find(fn, thisArg) {
+ return apply$1(this, "find", fn, thisArg, toReactive, arguments);
+ },
+ findIndex(fn, thisArg) {
+ return apply$1(this, "findIndex", fn, thisArg, void 0, arguments);
+ },
+ findLast(fn, thisArg) {
+ return apply$1(this, "findLast", fn, thisArg, toReactive, arguments);
+ },
+ findLastIndex(fn, thisArg) {
+ return apply$1(this, "findLastIndex", fn, thisArg, void 0, arguments);
+ },
+ // flat, flatMap could benefit from ARRAY_ITERATE but are not straight-forward to implement
+ forEach(fn, thisArg) {
+ return apply$1(this, "forEach", fn, thisArg, void 0, arguments);
+ },
+ includes(...args) {
+ return searchProxy(this, "includes", args);
+ },
+ indexOf(...args) {
+ return searchProxy(this, "indexOf", args);
+ },
+ join(separator) {
+ return reactiveReadArray(this).join(separator);
+ },
+ // keys() iterator only reads `length`, no optimisation required
+ lastIndexOf(...args) {
+ return searchProxy(this, "lastIndexOf", args);
+ },
+ map(fn, thisArg) {
+ return apply$1(this, "map", fn, thisArg, void 0, arguments);
+ },
+ pop() {
+ return noTracking(this, "pop");
+ },
+ push(...args) {
+ return noTracking(this, "push", args);
+ },
+ reduce(fn, ...args) {
+ return reduce(this, "reduce", fn, args);
+ },
+ reduceRight(fn, ...args) {
+ return reduce(this, "reduceRight", fn, args);
+ },
+ shift() {
+ return noTracking(this, "shift");
+ },
+ // slice could use ARRAY_ITERATE but also seems to beg for range tracking
+ some(fn, thisArg) {
+ return apply$1(this, "some", fn, thisArg, void 0, arguments);
+ },
+ splice(...args) {
+ return noTracking(this, "splice", args);
+ },
+ toReversed() {
+ return reactiveReadArray(this).toReversed();
+ },
+ toSorted(comparer) {
+ return reactiveReadArray(this).toSorted(comparer);
+ },
+ toSpliced(...args) {
+ return reactiveReadArray(this).toSpliced(...args);
+ },
+ unshift(...args) {
+ return noTracking(this, "unshift", args);
+ },
+ values() {
+ return iterator(this, "values", toReactive);
+ }
+};
+function iterator(self2, method, wrapValue) {
+ const arr = shallowReadArray(self2);
+ const iter = arr[method]();
+ if (arr !== self2 && !isShallow(self2)) {
+ iter._next = iter.next;
+ iter.next = () => {
+ const result = iter._next();
+ if (result.value) {
+ result.value = wrapValue(result.value);
+ }
+ return result;
+ };
+ }
+ return iter;
+}
+const arrayProto$1 = Array.prototype;
+function apply$1(self2, method, fn, thisArg, wrappedRetFn, args) {
+ const arr = shallowReadArray(self2);
+ const needsWrap = arr !== self2 && !isShallow(self2);
+ const methodFn = arr[method];
+ if (methodFn !== arrayProto$1[method]) {
+ const result2 = methodFn.apply(self2, args);
+ return needsWrap ? toReactive(result2) : result2;
+ }
+ let wrappedFn = fn;
+ if (arr !== self2) {
+ if (needsWrap) {
+ wrappedFn = function(item, index) {
+ return fn.call(this, toReactive(item), index, self2);
+ };
+ } else if (fn.length > 2) {
+ wrappedFn = function(item, index) {
+ return fn.call(this, item, index, self2);
+ };
+ }
+ }
+ const result = methodFn.call(arr, wrappedFn, thisArg);
+ return needsWrap && wrappedRetFn ? wrappedRetFn(result) : result;
+}
+function reduce(self2, method, fn, args) {
+ const arr = shallowReadArray(self2);
+ let wrappedFn = fn;
+ if (arr !== self2) {
+ if (!isShallow(self2)) {
+ wrappedFn = function(acc, item, index) {
+ return fn.call(this, acc, toReactive(item), index, self2);
+ };
+ } else if (fn.length > 3) {
+ wrappedFn = function(acc, item, index) {
+ return fn.call(this, acc, item, index, self2);
+ };
+ }
+ }
+ return arr[method](wrappedFn, ...args);
+}
+function searchProxy(self2, method, args) {
+ const arr = toRaw(self2);
+ track(arr, "iterate", ARRAY_ITERATE_KEY);
+ const res = arr[method](...args);
+ if ((res === -1 || res === false) && isProxy(args[0])) {
+ args[0] = toRaw(args[0]);
+ return arr[method](...args);
+ }
+ return res;
+}
+function noTracking(self2, method, args = []) {
+ pauseTracking();
+ startBatch();
+ const res = toRaw(self2)[method].apply(self2, args);
+ endBatch();
+ resetTracking();
+ return res;
+}
+const isNonTrackableKeys = /* @__PURE__ */ makeMap(`__proto__,__v_isRef,__isVue`);
+const builtInSymbols = new Set(
+ /* @__PURE__ */ Object.getOwnPropertyNames(Symbol).filter((key) => key !== "arguments" && key !== "caller").map((key) => Symbol[key]).filter(isSymbol$1)
+);
+function hasOwnProperty$a(key) {
+ if (!isSymbol$1(key)) key = String(key);
+ const obj = toRaw(this);
+ track(obj, "has", key);
+ return obj.hasOwnProperty(key);
+}
+class BaseReactiveHandler {
+ constructor(_isReadonly = false, _isShallow = false) {
+ this._isReadonly = _isReadonly;
+ this._isShallow = _isShallow;
+ }
+ get(target, key, receiver) {
+ if (key === "__v_skip") return target["__v_skip"];
+ const isReadonly2 = this._isReadonly, isShallow2 = this._isShallow;
+ if (key === "__v_isReactive") {
+ return !isReadonly2;
+ } else if (key === "__v_isReadonly") {
+ return isReadonly2;
+ } else if (key === "__v_isShallow") {
+ return isShallow2;
+ } else if (key === "__v_raw") {
+ if (receiver === (isReadonly2 ? isShallow2 ? shallowReadonlyMap : readonlyMap : isShallow2 ? shallowReactiveMap : reactiveMap).get(target) || // receiver is not the reactive proxy, but has the same prototype
+ // this means the receiver is a user proxy of the reactive proxy
+ Object.getPrototypeOf(target) === Object.getPrototypeOf(receiver)) {
+ return target;
+ }
+ return;
+ }
+ const targetIsArray = isArray$3(target);
+ if (!isReadonly2) {
+ let fn;
+ if (targetIsArray && (fn = arrayInstrumentations[key])) {
+ return fn;
+ }
+ if (key === "hasOwnProperty") {
+ return hasOwnProperty$a;
+ }
+ }
+ const res = Reflect.get(
+ target,
+ key,
+ // if this is a proxy wrapping a ref, return methods using the raw ref
+ // as receiver so that we don't have to call `toRaw` on the ref in all
+ // its class methods
+ isRef(target) ? target : receiver
+ );
+ if (isSymbol$1(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {
+ return res;
+ }
+ if (!isReadonly2) {
+ track(target, "get", key);
+ }
+ if (isShallow2) {
+ return res;
+ }
+ if (isRef(res)) {
+ return targetIsArray && isIntegerKey(key) ? res : res.value;
+ }
+ if (isObject$4(res)) {
+ return isReadonly2 ? readonly(res) : reactive(res);
+ }
+ return res;
+ }
+}
+class MutableReactiveHandler extends BaseReactiveHandler {
+ constructor(isShallow2 = false) {
+ super(false, isShallow2);
+ }
+ set(target, key, value, receiver) {
+ let oldValue = target[key];
+ if (!this._isShallow) {
+ const isOldValueReadonly = isReadonly(oldValue);
+ if (!isShallow(value) && !isReadonly(value)) {
+ oldValue = toRaw(oldValue);
+ value = toRaw(value);
+ }
+ if (!isArray$3(target) && isRef(oldValue) && !isRef(value)) {
+ if (isOldValueReadonly) {
+ return false;
+ } else {
+ oldValue.value = value;
+ return true;
+ }
+ }
+ }
+ const hadKey = isArray$3(target) && isIntegerKey(key) ? Number(key) < target.length : hasOwn(target, key);
+ const result = Reflect.set(
+ target,
+ key,
+ value,
+ isRef(target) ? target : receiver
+ );
+ if (target === toRaw(receiver)) {
+ if (!hadKey) {
+ trigger$1(target, "add", key, value);
+ } else if (hasChanged(value, oldValue)) {
+ trigger$1(target, "set", key, value);
+ }
+ }
+ return result;
+ }
+ deleteProperty(target, key) {
+ const hadKey = hasOwn(target, key);
+ target[key];
+ const result = Reflect.deleteProperty(target, key);
+ if (result && hadKey) {
+ trigger$1(target, "delete", key, void 0);
+ }
+ return result;
+ }
+ has(target, key) {
+ const result = Reflect.has(target, key);
+ if (!isSymbol$1(key) || !builtInSymbols.has(key)) {
+ track(target, "has", key);
+ }
+ return result;
+ }
+ ownKeys(target) {
+ track(
+ target,
+ "iterate",
+ isArray$3(target) ? "length" : ITERATE_KEY
+ );
+ return Reflect.ownKeys(target);
+ }
+}
+class ReadonlyReactiveHandler extends BaseReactiveHandler {
+ constructor(isShallow2 = false) {
+ super(true, isShallow2);
+ }
+ set(target, key) {
+ return true;
+ }
+ deleteProperty(target, key) {
+ return true;
+ }
+}
+const mutableHandlers = /* @__PURE__ */ new MutableReactiveHandler();
+const readonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler();
+const shallowReactiveHandlers = /* @__PURE__ */ new MutableReactiveHandler(true);
+const shallowReadonlyHandlers = /* @__PURE__ */ new ReadonlyReactiveHandler(true);
+const toShallow = (value) => value;
+const getProto = (v) => Reflect.getPrototypeOf(v);
+function createIterableMethod(method, isReadonly2, isShallow2) {
+ return function(...args) {
+ const target = this["__v_raw"];
+ const rawTarget = toRaw(target);
+ const targetIsMap = isMap(rawTarget);
+ const isPair = method === "entries" || method === Symbol.iterator && targetIsMap;
+ const isKeyOnly = method === "keys" && targetIsMap;
+ const innerIterator = target[method](...args);
+ const wrap = isShallow2 ? toShallow : isReadonly2 ? toReadonly : toReactive;
+ !isReadonly2 && track(
+ rawTarget,
+ "iterate",
+ isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY
+ );
+ return {
+ // iterator protocol
+ next() {
+ const { value, done } = innerIterator.next();
+ return done ? { value, done } : {
+ value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),
+ done
+ };
+ },
+ // iterable protocol
+ [Symbol.iterator]() {
+ return this;
+ }
+ };
+ };
+}
+function createReadonlyMethod(type) {
+ return function(...args) {
+ return type === "delete" ? false : type === "clear" ? void 0 : this;
+ };
+}
+function createInstrumentations(readonly2, shallow) {
+ const instrumentations = {
+ get(key) {
+ const target = this["__v_raw"];
+ const rawTarget = toRaw(target);
+ const rawKey = toRaw(key);
+ if (!readonly2) {
+ if (hasChanged(key, rawKey)) {
+ track(rawTarget, "get", key);
+ }
+ track(rawTarget, "get", rawKey);
+ }
+ const { has } = getProto(rawTarget);
+ const wrap = shallow ? toShallow : readonly2 ? toReadonly : toReactive;
+ if (has.call(rawTarget, key)) {
+ return wrap(target.get(key));
+ } else if (has.call(rawTarget, rawKey)) {
+ return wrap(target.get(rawKey));
+ } else if (target !== rawTarget) {
+ target.get(key);
+ }
+ },
+ get size() {
+ const target = this["__v_raw"];
+ !readonly2 && track(toRaw(target), "iterate", ITERATE_KEY);
+ return Reflect.get(target, "size", target);
+ },
+ has(key) {
+ const target = this["__v_raw"];
+ const rawTarget = toRaw(target);
+ const rawKey = toRaw(key);
+ if (!readonly2) {
+ if (hasChanged(key, rawKey)) {
+ track(rawTarget, "has", key);
+ }
+ track(rawTarget, "has", rawKey);
+ }
+ return key === rawKey ? target.has(key) : target.has(key) || target.has(rawKey);
+ },
+ forEach(callback, thisArg) {
+ const observed = this;
+ const target = observed["__v_raw"];
+ const rawTarget = toRaw(target);
+ const wrap = shallow ? toShallow : readonly2 ? toReadonly : toReactive;
+ !readonly2 && track(rawTarget, "iterate", ITERATE_KEY);
+ return target.forEach((value, key) => {
+ return callback.call(thisArg, wrap(value), wrap(key), observed);
+ });
+ }
+ };
+ extend$1(
+ instrumentations,
+ readonly2 ? {
+ add: createReadonlyMethod("add"),
+ set: createReadonlyMethod("set"),
+ delete: createReadonlyMethod("delete"),
+ clear: createReadonlyMethod("clear")
+ } : {
+ add(value) {
+ if (!shallow && !isShallow(value) && !isReadonly(value)) {
+ value = toRaw(value);
+ }
+ const target = toRaw(this);
+ const proto = getProto(target);
+ const hadKey = proto.has.call(target, value);
+ if (!hadKey) {
+ target.add(value);
+ trigger$1(target, "add", value, value);
+ }
+ return this;
+ },
+ set(key, value) {
+ if (!shallow && !isShallow(value) && !isReadonly(value)) {
+ value = toRaw(value);
+ }
+ const target = toRaw(this);
+ const { has, get: get2 } = getProto(target);
+ let hadKey = has.call(target, key);
+ if (!hadKey) {
+ key = toRaw(key);
+ hadKey = has.call(target, key);
+ }
+ const oldValue = get2.call(target, key);
+ target.set(key, value);
+ if (!hadKey) {
+ trigger$1(target, "add", key, value);
+ } else if (hasChanged(value, oldValue)) {
+ trigger$1(target, "set", key, value);
+ }
+ return this;
+ },
+ delete(key) {
+ const target = toRaw(this);
+ const { has, get: get2 } = getProto(target);
+ let hadKey = has.call(target, key);
+ if (!hadKey) {
+ key = toRaw(key);
+ hadKey = has.call(target, key);
+ }
+ get2 ? get2.call(target, key) : void 0;
+ const result = target.delete(key);
+ if (hadKey) {
+ trigger$1(target, "delete", key, void 0);
+ }
+ return result;
+ },
+ clear() {
+ const target = toRaw(this);
+ const hadItems = target.size !== 0;
+ const result = target.clear();
+ if (hadItems) {
+ trigger$1(
+ target,
+ "clear",
+ void 0,
+ void 0
+ );
+ }
+ return result;
+ }
+ }
+ );
+ const iteratorMethods = [
+ "keys",
+ "values",
+ "entries",
+ Symbol.iterator
+ ];
+ iteratorMethods.forEach((method) => {
+ instrumentations[method] = createIterableMethod(method, readonly2, shallow);
+ });
+ return instrumentations;
+}
+function createInstrumentationGetter(isReadonly2, shallow) {
+ const instrumentations = createInstrumentations(isReadonly2, shallow);
+ return (target, key, receiver) => {
+ if (key === "__v_isReactive") {
+ return !isReadonly2;
+ } else if (key === "__v_isReadonly") {
+ return isReadonly2;
+ } else if (key === "__v_raw") {
+ return target;
+ }
+ return Reflect.get(
+ hasOwn(instrumentations, key) && key in target ? instrumentations : target,
+ key,
+ receiver
+ );
+ };
+}
+const mutableCollectionHandlers = {
+ get: /* @__PURE__ */ createInstrumentationGetter(false, false)
+};
+const shallowCollectionHandlers = {
+ get: /* @__PURE__ */ createInstrumentationGetter(false, true)
+};
+const readonlyCollectionHandlers = {
+ get: /* @__PURE__ */ createInstrumentationGetter(true, false)
+};
+const shallowReadonlyCollectionHandlers = {
+ get: /* @__PURE__ */ createInstrumentationGetter(true, true)
+};
+const reactiveMap = /* @__PURE__ */ new WeakMap();
+const shallowReactiveMap = /* @__PURE__ */ new WeakMap();
+const readonlyMap = /* @__PURE__ */ new WeakMap();
+const shallowReadonlyMap = /* @__PURE__ */ new WeakMap();
+function targetTypeMap(rawType) {
+ switch (rawType) {
+ case "Object":
+ case "Array":
+ return 1;
+ case "Map":
+ case "Set":
+ case "WeakMap":
+ case "WeakSet":
+ return 2;
+ default:
+ return 0;
+ }
+}
+function getTargetType(value) {
+ return value["__v_skip"] || !Object.isExtensible(value) ? 0 : targetTypeMap(toRawType(value));
+}
+function reactive(target) {
+ if (isReadonly(target)) {
+ return target;
+ }
+ return createReactiveObject(
+ target,
+ false,
+ mutableHandlers,
+ mutableCollectionHandlers,
+ reactiveMap
+ );
+}
+function shallowReactive(target) {
+ return createReactiveObject(
+ target,
+ false,
+ shallowReactiveHandlers,
+ shallowCollectionHandlers,
+ shallowReactiveMap
+ );
+}
+function readonly(target) {
+ return createReactiveObject(
+ target,
+ true,
+ readonlyHandlers,
+ readonlyCollectionHandlers,
+ readonlyMap
+ );
+}
+function shallowReadonly(target) {
+ return createReactiveObject(
+ target,
+ true,
+ shallowReadonlyHandlers,
+ shallowReadonlyCollectionHandlers,
+ shallowReadonlyMap
+ );
+}
+function createReactiveObject(target, isReadonly2, baseHandlers, collectionHandlers, proxyMap) {
+ if (!isObject$4(target)) {
+ return target;
+ }
+ if (target["__v_raw"] && !(isReadonly2 && target["__v_isReactive"])) {
+ return target;
+ }
+ const existingProxy = proxyMap.get(target);
+ if (existingProxy) {
+ return existingProxy;
+ }
+ const targetType = getTargetType(target);
+ if (targetType === 0) {
+ return target;
+ }
+ const proxy = new Proxy(
+ target,
+ targetType === 2 ? collectionHandlers : baseHandlers
+ );
+ proxyMap.set(target, proxy);
+ return proxy;
+}
+function isReactive(value) {
+ if (isReadonly(value)) {
+ return isReactive(value["__v_raw"]);
+ }
+ return !!(value && value["__v_isReactive"]);
+}
+function isReadonly(value) {
+ return !!(value && value["__v_isReadonly"]);
+}
+function isShallow(value) {
+ return !!(value && value["__v_isShallow"]);
+}
+function isProxy(value) {
+ return value ? !!value["__v_raw"] : false;
+}
+function toRaw(observed) {
+ const raw = observed && observed["__v_raw"];
+ return raw ? toRaw(raw) : observed;
+}
+function markRaw(value) {
+ if (!hasOwn(value, "__v_skip") && Object.isExtensible(value)) {
+ def$1(value, "__v_skip", true);
+ }
+ return value;
+}
+const toReactive = (value) => isObject$4(value) ? reactive(value) : value;
+const toReadonly = (value) => isObject$4(value) ? readonly(value) : value;
+function isRef(r) {
+ return r ? r["__v_isRef"] === true : false;
+}
+function ref(value) {
+ return createRef(value, false);
+}
+function shallowRef(value) {
+ return createRef(value, true);
+}
+function createRef(rawValue, shallow) {
+ if (isRef(rawValue)) {
+ return rawValue;
+ }
+ return new RefImpl(rawValue, shallow);
+}
+class RefImpl {
+ constructor(value, isShallow2) {
+ this.dep = new Dep();
+ this["__v_isRef"] = true;
+ this["__v_isShallow"] = false;
+ this._rawValue = isShallow2 ? value : toRaw(value);
+ this._value = isShallow2 ? value : toReactive(value);
+ this["__v_isShallow"] = isShallow2;
+ }
+ get value() {
+ {
+ this.dep.track();
+ }
+ return this._value;
+ }
+ set value(newValue) {
+ const oldValue = this._rawValue;
+ const useDirectValue = this["__v_isShallow"] || isShallow(newValue) || isReadonly(newValue);
+ newValue = useDirectValue ? newValue : toRaw(newValue);
+ if (hasChanged(newValue, oldValue)) {
+ this._rawValue = newValue;
+ this._value = useDirectValue ? newValue : toReactive(newValue);
+ {
+ this.dep.trigger();
+ }
+ }
+ }
+}
+function unref(ref2) {
+ return isRef(ref2) ? ref2.value : ref2;
+}
+const shallowUnwrapHandlers = {
+ get: (target, key, receiver) => key === "__v_raw" ? target : unref(Reflect.get(target, key, receiver)),
+ set: (target, key, value, receiver) => {
+ const oldValue = target[key];
+ if (isRef(oldValue) && !isRef(value)) {
+ oldValue.value = value;
+ return true;
+ } else {
+ return Reflect.set(target, key, value, receiver);
+ }
+ }
+};
+function proxyRefs(objectWithRefs) {
+ return isReactive(objectWithRefs) ? objectWithRefs : new Proxy(objectWithRefs, shallowUnwrapHandlers);
+}
+class ObjectRefImpl {
+ constructor(_object, _key, _defaultValue) {
+ this._object = _object;
+ this._key = _key;
+ this._defaultValue = _defaultValue;
+ this["__v_isRef"] = true;
+ this._value = void 0;
+ }
+ get value() {
+ const val = this._object[this._key];
+ return this._value = val === void 0 ? this._defaultValue : val;
+ }
+ set value(newVal) {
+ this._object[this._key] = newVal;
+ }
+ get dep() {
+ return getDepFromReactive(toRaw(this._object), this._key);
+ }
+}
+class GetterRefImpl {
+ constructor(_getter) {
+ this._getter = _getter;
+ this["__v_isRef"] = true;
+ this["__v_isReadonly"] = true;
+ this._value = void 0;
+ }
+ get value() {
+ return this._value = this._getter();
+ }
+}
+function toRef(source, key, defaultValue) {
+ if (isRef(source)) {
+ return source;
+ } else if (isFunction$2(source)) {
+ return new GetterRefImpl(source);
+ } else if (isObject$4(source) && arguments.length > 1) {
+ return propertyToRef(source, key, defaultValue);
+ } else {
+ return ref(source);
+ }
+}
+function propertyToRef(source, key, defaultValue) {
+ const val = source[key];
+ return isRef(val) ? val : new ObjectRefImpl(source, key, defaultValue);
+}
+class ComputedRefImpl {
+ constructor(fn, setter, isSSR) {
+ this.fn = fn;
+ this.setter = setter;
+ this._value = void 0;
+ this.dep = new Dep(this);
+ this.__v_isRef = true;
+ this.deps = void 0;
+ this.depsTail = void 0;
+ this.flags = 16;
+ this.globalVersion = globalVersion - 1;
+ this.next = void 0;
+ this.effect = this;
+ this["__v_isReadonly"] = !setter;
+ this.isSSR = isSSR;
+ }
+ /**
+ * @internal
+ */
+ notify() {
+ this.flags |= 16;
+ if (!(this.flags & 8) && // avoid infinite self recursion
+ activeSub !== this) {
+ batch(this, true);
+ return true;
+ }
+ }
+ get value() {
+ const link2 = this.dep.track();
+ refreshComputed(this);
+ if (link2) {
+ link2.version = this.dep.version;
+ }
+ return this._value;
+ }
+ set value(newValue) {
+ if (this.setter) {
+ this.setter(newValue);
+ }
+ }
+}
+function computed$1(getterOrOptions, debugOptions, isSSR = false) {
+ let getter;
+ let setter;
+ if (isFunction$2(getterOrOptions)) {
+ getter = getterOrOptions;
+ } else {
+ getter = getterOrOptions.get;
+ setter = getterOrOptions.set;
+ }
+ const cRef = new ComputedRefImpl(getter, setter, isSSR);
+ return cRef;
+}
+const INITIAL_WATCHER_VALUE = {};
+const cleanupMap = /* @__PURE__ */ new WeakMap();
+let activeWatcher = void 0;
+function onWatcherCleanup(cleanupFn, failSilently = false, owner = activeWatcher) {
+ if (owner) {
+ let cleanups = cleanupMap.get(owner);
+ if (!cleanups) cleanupMap.set(owner, cleanups = []);
+ cleanups.push(cleanupFn);
+ }
+}
+function watch$1(source, cb, options = EMPTY_OBJ) {
+ const { immediate, deep, once, scheduler: scheduler2, augmentJob, call: call2 } = options;
+ const reactiveGetter = (source2) => {
+ if (deep) return source2;
+ if (isShallow(source2) || deep === false || deep === 0)
+ return traverse(source2, 1);
+ return traverse(source2);
+ };
+ let effect2;
+ let getter;
+ let cleanup;
+ let boundCleanup;
+ let forceTrigger = false;
+ let isMultiSource = false;
+ if (isRef(source)) {
+ getter = () => source.value;
+ forceTrigger = isShallow(source);
+ } else if (isReactive(source)) {
+ getter = () => reactiveGetter(source);
+ forceTrigger = true;
+ } else if (isArray$3(source)) {
+ isMultiSource = true;
+ forceTrigger = source.some((s) => isReactive(s) || isShallow(s));
+ getter = () => source.map((s) => {
+ if (isRef(s)) {
+ return s.value;
+ } else if (isReactive(s)) {
+ return reactiveGetter(s);
+ } else if (isFunction$2(s)) {
+ return call2 ? call2(s, 2) : s();
+ } else ;
+ });
+ } else if (isFunction$2(source)) {
+ if (cb) {
+ getter = call2 ? () => call2(source, 2) : source;
+ } else {
+ getter = () => {
+ if (cleanup) {
+ pauseTracking();
+ try {
+ cleanup();
+ } finally {
+ resetTracking();
+ }
+ }
+ const currentEffect = activeWatcher;
+ activeWatcher = effect2;
+ try {
+ return call2 ? call2(source, 3, [boundCleanup]) : source(boundCleanup);
+ } finally {
+ activeWatcher = currentEffect;
+ }
+ };
+ }
+ } else {
+ getter = NOOP;
+ }
+ if (cb && deep) {
+ const baseGetter = getter;
+ const depth = deep === true ? Infinity : deep;
+ getter = () => traverse(baseGetter(), depth);
+ }
+ const scope = getCurrentScope();
+ const watchHandle = () => {
+ effect2.stop();
+ if (scope && scope.active) {
+ remove(scope.effects, effect2);
+ }
+ };
+ if (once && cb) {
+ const _cb = cb;
+ cb = (...args) => {
+ _cb(...args);
+ watchHandle();
+ };
+ }
+ let oldValue = isMultiSource ? new Array(source.length).fill(INITIAL_WATCHER_VALUE) : INITIAL_WATCHER_VALUE;
+ const job = (immediateFirstRun) => {
+ if (!(effect2.flags & 1) || !effect2.dirty && !immediateFirstRun) {
+ return;
+ }
+ if (cb) {
+ const newValue = effect2.run();
+ if (deep || forceTrigger || (isMultiSource ? newValue.some((v, i) => hasChanged(v, oldValue[i])) : hasChanged(newValue, oldValue))) {
+ if (cleanup) {
+ cleanup();
+ }
+ const currentWatcher = activeWatcher;
+ activeWatcher = effect2;
+ try {
+ const args = [
+ newValue,
+ // pass undefined as the old value when it's changed for the first time
+ oldValue === INITIAL_WATCHER_VALUE ? void 0 : isMultiSource && oldValue[0] === INITIAL_WATCHER_VALUE ? [] : oldValue,
+ boundCleanup
+ ];
+ call2 ? call2(cb, 3, args) : (
+ // @ts-expect-error
+ cb(...args)
+ );
+ oldValue = newValue;
+ } finally {
+ activeWatcher = currentWatcher;
+ }
+ }
+ } else {
+ effect2.run();
+ }
+ };
+ if (augmentJob) {
+ augmentJob(job);
+ }
+ effect2 = new ReactiveEffect(getter);
+ effect2.scheduler = scheduler2 ? () => scheduler2(job, false) : job;
+ boundCleanup = (fn) => onWatcherCleanup(fn, false, effect2);
+ cleanup = effect2.onStop = () => {
+ const cleanups = cleanupMap.get(effect2);
+ if (cleanups) {
+ if (call2) {
+ call2(cleanups, 4);
+ } else {
+ for (const cleanup2 of cleanups) cleanup2();
+ }
+ cleanupMap.delete(effect2);
+ }
+ };
+ if (cb) {
+ if (immediate) {
+ job(true);
+ } else {
+ oldValue = effect2.run();
+ }
+ } else if (scheduler2) {
+ scheduler2(job.bind(null, true), true);
+ } else {
+ effect2.run();
+ }
+ watchHandle.pause = effect2.pause.bind(effect2);
+ watchHandle.resume = effect2.resume.bind(effect2);
+ watchHandle.stop = watchHandle;
+ return watchHandle;
+}
+function traverse(value, depth = Infinity, seen2) {
+ if (depth <= 0 || !isObject$4(value) || value["__v_skip"]) {
+ return value;
+ }
+ seen2 = seen2 || /* @__PURE__ */ new Set();
+ if (seen2.has(value)) {
+ return value;
+ }
+ seen2.add(value);
+ depth--;
+ if (isRef(value)) {
+ traverse(value.value, depth, seen2);
+ } else if (isArray$3(value)) {
+ for (let i = 0; i < value.length; i++) {
+ traverse(value[i], depth, seen2);
+ }
+ } else if (isSet(value) || isMap(value)) {
+ value.forEach((v) => {
+ traverse(v, depth, seen2);
+ });
+ } else if (isPlainObject$2(value)) {
+ for (const key in value) {
+ traverse(value[key], depth, seen2);
+ }
+ for (const key of Object.getOwnPropertySymbols(value)) {
+ if (Object.prototype.propertyIsEnumerable.call(value, key)) {
+ traverse(value[key], depth, seen2);
+ }
+ }
+ }
+ return value;
+}
+/**
+* @vue/runtime-core v3.5.13
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/
+const stack$1 = [];
+let isWarning = false;
+function warn$1$1(msg2, ...args) {
+ if (isWarning) return;
+ isWarning = true;
+ pauseTracking();
+ const instance = stack$1.length ? stack$1[stack$1.length - 1].component : null;
+ const appWarnHandler = instance && instance.appContext.config.warnHandler;
+ const trace = getComponentTrace();
+ if (appWarnHandler) {
+ callWithErrorHandling(
+ appWarnHandler,
+ instance,
+ 11,
+ [
+ // eslint-disable-next-line no-restricted-syntax
+ msg2 + args.map((a) => {
+ var _a, _b;
+ return (_b = (_a = a.toString) == null ? void 0 : _a.call(a)) != null ? _b : JSON.stringify(a);
+ }).join(""),
+ instance && instance.proxy,
+ trace.map(
+ ({ vnode: vnode2 }) => `at <${formatComponentName(instance, vnode2.type)}>`
+ ).join("\n"),
+ trace
+ ]
+ );
+ } else {
+ const warnArgs = [`[Vue warn]: ${msg2}`, ...args];
+ if (trace.length && // avoid spamming console during tests
+ true) {
+ warnArgs.push(`
+`, ...formatTrace(trace));
+ }
+ console.warn(...warnArgs);
+ }
+ resetTracking();
+ isWarning = false;
+}
+function getComponentTrace() {
+ let currentVNode = stack$1[stack$1.length - 1];
+ if (!currentVNode) {
+ return [];
+ }
+ const normalizedStack = [];
+ while (currentVNode) {
+ const last = normalizedStack[0];
+ if (last && last.vnode === currentVNode) {
+ last.recurseCount++;
+ } else {
+ normalizedStack.push({
+ vnode: currentVNode,
+ recurseCount: 0
+ });
+ }
+ const parentInstance = currentVNode.component && currentVNode.component.parent;
+ currentVNode = parentInstance && parentInstance.vnode;
+ }
+ return normalizedStack;
+}
+function formatTrace(trace) {
+ const logs = [];
+ trace.forEach((entry, i) => {
+ logs.push(...i === 0 ? [] : [`
+`], ...formatTraceEntry(entry));
+ });
+ return logs;
+}
+function formatTraceEntry({ vnode: vnode2, recurseCount }) {
+ const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;
+ const isRoot = vnode2.component ? vnode2.component.parent == null : false;
+ const open = ` at <${formatComponentName(
+ vnode2.component,
+ vnode2.type,
+ isRoot
+ )}`;
+ const close = `>` + postfix;
+ return vnode2.props ? [open, ...formatProps(vnode2.props), close] : [open + close];
+}
+function formatProps(props) {
+ const res = [];
+ const keys = Object.keys(props);
+ keys.slice(0, 3).forEach((key) => {
+ res.push(...formatProp(key, props[key]));
+ });
+ if (keys.length > 3) {
+ res.push(` ...`);
+ }
+ return res;
+}
+function formatProp(key, value, raw) {
+ if (isString$1(value)) {
+ value = JSON.stringify(value);
+ return raw ? value : [`${key}=${value}`];
+ } else if (typeof value === "number" || typeof value === "boolean" || value == null) {
+ return raw ? value : [`${key}=${value}`];
+ } else if (isRef(value)) {
+ value = formatProp(key, toRaw(value.value), true);
+ return raw ? value : [`${key}=Ref<`, value, `>`];
+ } else if (isFunction$2(value)) {
+ return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];
+ } else {
+ value = toRaw(value);
+ return raw ? value : [`${key}=`, value];
+ }
+}
+function callWithErrorHandling(fn, instance, type, args) {
+ try {
+ return args ? fn(...args) : fn();
+ } catch (err) {
+ handleError(err, instance, type);
+ }
+}
+function callWithAsyncErrorHandling(fn, instance, type, args) {
+ if (isFunction$2(fn)) {
+ const res = callWithErrorHandling(fn, instance, type, args);
+ if (res && isPromise$1(res)) {
+ res.catch((err) => {
+ handleError(err, instance, type);
+ });
+ }
+ return res;
+ }
+ if (isArray$3(fn)) {
+ const values = [];
+ for (let i = 0; i < fn.length; i++) {
+ values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));
+ }
+ return values;
+ }
+}
+function handleError(err, instance, type, throwInDev = true) {
+ const contextVNode = instance ? instance.vnode : null;
+ const { errorHandler, throwUnhandledErrorInProduction } = instance && instance.appContext.config || EMPTY_OBJ;
+ if (instance) {
+ let cur = instance.parent;
+ const exposedInstance = instance.proxy;
+ const errorInfo = `https://vuejs.org/error-reference/#runtime-${type}`;
+ while (cur) {
+ const errorCapturedHooks = cur.ec;
+ if (errorCapturedHooks) {
+ for (let i = 0; i < errorCapturedHooks.length; i++) {
+ if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {
+ return;
+ }
+ }
+ }
+ cur = cur.parent;
+ }
+ if (errorHandler) {
+ pauseTracking();
+ callWithErrorHandling(errorHandler, null, 10, [
+ err,
+ exposedInstance,
+ errorInfo
+ ]);
+ resetTracking();
+ return;
+ }
+ }
+ logError(err, type, contextVNode, throwInDev, throwUnhandledErrorInProduction);
+}
+function logError(err, type, contextVNode, throwInDev = true, throwInProd = false) {
+ if (throwInProd) {
+ throw err;
+ } else {
+ console.error(err);
+ }
+}
+const queue = [];
+let flushIndex = -1;
+const pendingPostFlushCbs = [];
+let activePostFlushCbs = null;
+let postFlushIndex = 0;
+const resolvedPromise = /* @__PURE__ */ Promise.resolve();
+let currentFlushPromise = null;
+function nextTick(fn) {
+ const p2 = currentFlushPromise || resolvedPromise;
+ return fn ? p2.then(this ? fn.bind(this) : fn) : p2;
+}
+function findInsertionIndex$1(id) {
+ let start = flushIndex + 1;
+ let end = queue.length;
+ while (start < end) {
+ const middle = start + end >>> 1;
+ const middleJob = queue[middle];
+ const middleJobId = getId(middleJob);
+ if (middleJobId < id || middleJobId === id && middleJob.flags & 2) {
+ start = middle + 1;
+ } else {
+ end = middle;
+ }
+ }
+ return start;
+}
+function queueJob(job) {
+ if (!(job.flags & 1)) {
+ const jobId = getId(job);
+ const lastJob = queue[queue.length - 1];
+ if (!lastJob || // fast path when the job id is larger than the tail
+ !(job.flags & 2) && jobId >= getId(lastJob)) {
+ queue.push(job);
+ } else {
+ queue.splice(findInsertionIndex$1(jobId), 0, job);
+ }
+ job.flags |= 1;
+ queueFlush();
+ }
+}
+function queueFlush() {
+ if (!currentFlushPromise) {
+ currentFlushPromise = resolvedPromise.then(flushJobs);
+ }
+}
+function queuePostFlushCb(cb) {
+ if (!isArray$3(cb)) {
+ if (activePostFlushCbs && cb.id === -1) {
+ activePostFlushCbs.splice(postFlushIndex + 1, 0, cb);
+ } else if (!(cb.flags & 1)) {
+ pendingPostFlushCbs.push(cb);
+ cb.flags |= 1;
+ }
+ } else {
+ pendingPostFlushCbs.push(...cb);
+ }
+ queueFlush();
+}
+function flushPreFlushCbs(instance, seen2, i = flushIndex + 1) {
+ for (; i < queue.length; i++) {
+ const cb = queue[i];
+ if (cb && cb.flags & 2) {
+ if (instance && cb.id !== instance.uid) {
+ continue;
+ }
+ queue.splice(i, 1);
+ i--;
+ if (cb.flags & 4) {
+ cb.flags &= ~1;
+ }
+ cb();
+ if (!(cb.flags & 4)) {
+ cb.flags &= ~1;
+ }
+ }
+ }
+}
+function flushPostFlushCbs(seen2) {
+ if (pendingPostFlushCbs.length) {
+ const deduped = [...new Set(pendingPostFlushCbs)].sort(
+ (a, b) => getId(a) - getId(b)
+ );
+ pendingPostFlushCbs.length = 0;
+ if (activePostFlushCbs) {
+ activePostFlushCbs.push(...deduped);
+ return;
+ }
+ activePostFlushCbs = deduped;
+ for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {
+ const cb = activePostFlushCbs[postFlushIndex];
+ if (cb.flags & 4) {
+ cb.flags &= ~1;
+ }
+ if (!(cb.flags & 8)) cb();
+ cb.flags &= ~1;
+ }
+ activePostFlushCbs = null;
+ postFlushIndex = 0;
+ }
+}
+const getId = (job) => job.id == null ? job.flags & 2 ? -1 : Infinity : job.id;
+function flushJobs(seen2) {
+ try {
+ for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {
+ const job = queue[flushIndex];
+ if (job && !(job.flags & 8)) {
+ if (false) ;
+ if (job.flags & 4) {
+ job.flags &= ~1;
+ }
+ callWithErrorHandling(
+ job,
+ job.i,
+ job.i ? 15 : 14
+ );
+ if (!(job.flags & 4)) {
+ job.flags &= ~1;
+ }
+ }
+ }
+ } finally {
+ for (; flushIndex < queue.length; flushIndex++) {
+ const job = queue[flushIndex];
+ if (job) {
+ job.flags &= ~1;
+ }
+ }
+ flushIndex = -1;
+ queue.length = 0;
+ flushPostFlushCbs();
+ currentFlushPromise = null;
+ if (queue.length || pendingPostFlushCbs.length) {
+ flushJobs();
+ }
+ }
+}
+let currentRenderingInstance = null;
+let currentScopeId = null;
+function setCurrentRenderingInstance(instance) {
+ const prev = currentRenderingInstance;
+ currentRenderingInstance = instance;
+ currentScopeId = instance && instance.type.__scopeId || null;
+ return prev;
+}
+function withCtx(fn, ctx2 = currentRenderingInstance, isNonScopedSlot) {
+ if (!ctx2) return fn;
+ if (fn._n) {
+ return fn;
+ }
+ const renderFnWithContext = (...args) => {
+ if (renderFnWithContext._d) {
+ setBlockTracking(-1);
+ }
+ const prevInstance = setCurrentRenderingInstance(ctx2);
+ let res;
+ try {
+ res = fn(...args);
+ } finally {
+ setCurrentRenderingInstance(prevInstance);
+ if (renderFnWithContext._d) {
+ setBlockTracking(1);
+ }
+ }
+ return res;
+ };
+ renderFnWithContext._n = true;
+ renderFnWithContext._c = true;
+ renderFnWithContext._d = true;
+ return renderFnWithContext;
+}
+function withDirectives(vnode2, directives2) {
+ if (currentRenderingInstance === null) {
+ return vnode2;
+ }
+ const instance = getComponentPublicInstance(currentRenderingInstance);
+ const bindings = vnode2.dirs || (vnode2.dirs = []);
+ for (let i = 0; i < directives2.length; i++) {
+ let [dir, value, arg, modifiers = EMPTY_OBJ] = directives2[i];
+ if (dir) {
+ if (isFunction$2(dir)) {
+ dir = {
+ mounted: dir,
+ updated: dir
+ };
+ }
+ if (dir.deep) {
+ traverse(value);
+ }
+ bindings.push({
+ dir,
+ instance,
+ value,
+ oldValue: void 0,
+ arg,
+ modifiers
+ });
+ }
+ }
+ return vnode2;
+}
+function invokeDirectiveHook(vnode2, prevVNode, instance, name2) {
+ const bindings = vnode2.dirs;
+ const oldBindings = prevVNode && prevVNode.dirs;
+ for (let i = 0; i < bindings.length; i++) {
+ const binding = bindings[i];
+ if (oldBindings) {
+ binding.oldValue = oldBindings[i].value;
+ }
+ let hook = binding.dir[name2];
+ if (hook) {
+ pauseTracking();
+ callWithAsyncErrorHandling(hook, instance, 8, [
+ vnode2.el,
+ binding,
+ vnode2,
+ prevVNode
+ ]);
+ resetTracking();
+ }
+ }
+}
+const TeleportEndKey = Symbol("_vte");
+const isTeleport = (type) => type.__isTeleport;
+const isTeleportDisabled = (props) => props && (props.disabled || props.disabled === "");
+const isTeleportDeferred = (props) => props && (props.defer || props.defer === "");
+const isTargetSVG = (target) => typeof SVGElement !== "undefined" && target instanceof SVGElement;
+const isTargetMathML = (target) => typeof MathMLElement === "function" && target instanceof MathMLElement;
+const resolveTarget = (props, select) => {
+ const targetSelector = props && props.to;
+ if (isString$1(targetSelector)) {
+ if (!select) {
+ return null;
+ } else {
+ const target = select(targetSelector);
+ return target;
+ }
+ } else {
+ return targetSelector;
+ }
+};
+const TeleportImpl = {
+ name: "Teleport",
+ __isTeleport: true,
+ process(n1, n2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized, internals) {
+ const {
+ mc: mountChildren,
+ pc: patchChildren,
+ pbc: patchBlockChildren,
+ o: { insert, querySelector, createText, createComment }
+ } = internals;
+ const disabled = isTeleportDisabled(n2.props);
+ let { shapeFlag, children, dynamicChildren } = n2;
+ if (n1 == null) {
+ const placeholder = n2.el = createText("");
+ const mainAnchor = n2.anchor = createText("");
+ insert(placeholder, container, anchor);
+ insert(mainAnchor, container, anchor);
+ const mount2 = (container2, anchor2) => {
+ if (shapeFlag & 16) {
+ if (parentComponent && parentComponent.isCE) {
+ parentComponent.ce._teleportTarget = container2;
+ }
+ mountChildren(
+ children,
+ container2,
+ anchor2,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ };
+ const mountToTarget = () => {
+ const target = n2.target = resolveTarget(n2.props, querySelector);
+ const targetAnchor = prepareAnchor(target, n2, createText, insert);
+ if (target) {
+ if (namespace2 !== "svg" && isTargetSVG(target)) {
+ namespace2 = "svg";
+ } else if (namespace2 !== "mathml" && isTargetMathML(target)) {
+ namespace2 = "mathml";
+ }
+ if (!disabled) {
+ mount2(target, targetAnchor);
+ updateCssVars(n2, false);
+ }
+ }
+ };
+ if (disabled) {
+ mount2(container, mainAnchor);
+ updateCssVars(n2, true);
+ }
+ if (isTeleportDeferred(n2.props)) {
+ queuePostRenderEffect(() => {
+ mountToTarget();
+ n2.el.__isMounted = true;
+ }, parentSuspense);
+ } else {
+ mountToTarget();
+ }
+ } else {
+ if (isTeleportDeferred(n2.props) && !n1.el.__isMounted) {
+ queuePostRenderEffect(() => {
+ TeleportImpl.process(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized,
+ internals
+ );
+ delete n1.el.__isMounted;
+ }, parentSuspense);
+ return;
+ }
+ n2.el = n1.el;
+ n2.targetStart = n1.targetStart;
+ const mainAnchor = n2.anchor = n1.anchor;
+ const target = n2.target = n1.target;
+ const targetAnchor = n2.targetAnchor = n1.targetAnchor;
+ const wasDisabled = isTeleportDisabled(n1.props);
+ const currentContainer = wasDisabled ? container : target;
+ const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;
+ if (namespace2 === "svg" || isTargetSVG(target)) {
+ namespace2 = "svg";
+ } else if (namespace2 === "mathml" || isTargetMathML(target)) {
+ namespace2 = "mathml";
+ }
+ if (dynamicChildren) {
+ patchBlockChildren(
+ n1.dynamicChildren,
+ dynamicChildren,
+ currentContainer,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds
+ );
+ traverseStaticChildren(n1, n2, true);
+ } else if (!optimized) {
+ patchChildren(
+ n1,
+ n2,
+ currentContainer,
+ currentAnchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ false
+ );
+ }
+ if (disabled) {
+ if (!wasDisabled) {
+ moveTeleport(
+ n2,
+ container,
+ mainAnchor,
+ internals,
+ 1
+ );
+ } else {
+ if (n2.props && n1.props && n2.props.to !== n1.props.to) {
+ n2.props.to = n1.props.to;
+ }
+ }
+ } else {
+ if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {
+ const nextTarget = n2.target = resolveTarget(
+ n2.props,
+ querySelector
+ );
+ if (nextTarget) {
+ moveTeleport(
+ n2,
+ nextTarget,
+ null,
+ internals,
+ 0
+ );
+ }
+ } else if (wasDisabled) {
+ moveTeleport(
+ n2,
+ target,
+ targetAnchor,
+ internals,
+ 1
+ );
+ }
+ }
+ updateCssVars(n2, disabled);
+ }
+ },
+ remove(vnode2, parentComponent, parentSuspense, { um: unmount2, o: { remove: hostRemove } }, doRemove) {
+ const {
+ shapeFlag,
+ children,
+ anchor,
+ targetStart,
+ targetAnchor,
+ target,
+ props
+ } = vnode2;
+ if (target) {
+ hostRemove(targetStart);
+ hostRemove(targetAnchor);
+ }
+ doRemove && hostRemove(anchor);
+ if (shapeFlag & 16) {
+ const shouldRemove = doRemove || !isTeleportDisabled(props);
+ for (let i = 0; i < children.length; i++) {
+ const child = children[i];
+ unmount2(
+ child,
+ parentComponent,
+ parentSuspense,
+ shouldRemove,
+ !!child.dynamicChildren
+ );
+ }
+ }
+ },
+ move: moveTeleport,
+ hydrate: hydrateTeleport
+};
+function moveTeleport(vnode2, container, parentAnchor, { o: { insert }, m: move }, moveType = 2) {
+ if (moveType === 0) {
+ insert(vnode2.targetAnchor, container, parentAnchor);
+ }
+ const { el, anchor, shapeFlag, children, props } = vnode2;
+ const isReorder = moveType === 2;
+ if (isReorder) {
+ insert(el, container, parentAnchor);
+ }
+ if (!isReorder || isTeleportDisabled(props)) {
+ if (shapeFlag & 16) {
+ for (let i = 0; i < children.length; i++) {
+ move(
+ children[i],
+ container,
+ parentAnchor,
+ 2
+ );
+ }
+ }
+ }
+ if (isReorder) {
+ insert(anchor, container, parentAnchor);
+ }
+}
+function hydrateTeleport(node, vnode2, parentComponent, parentSuspense, slotScopeIds, optimized, {
+ o: { nextSibling, parentNode, querySelector, insert, createText }
+}, hydrateChildren) {
+ const target = vnode2.target = resolveTarget(
+ vnode2.props,
+ querySelector
+ );
+ if (target) {
+ const disabled = isTeleportDisabled(vnode2.props);
+ const targetNode = target._lpa || target.firstChild;
+ if (vnode2.shapeFlag & 16) {
+ if (disabled) {
+ vnode2.anchor = hydrateChildren(
+ nextSibling(node),
+ vnode2,
+ parentNode(node),
+ parentComponent,
+ parentSuspense,
+ slotScopeIds,
+ optimized
+ );
+ vnode2.targetStart = targetNode;
+ vnode2.targetAnchor = targetNode && nextSibling(targetNode);
+ } else {
+ vnode2.anchor = nextSibling(node);
+ let targetAnchor = targetNode;
+ while (targetAnchor) {
+ if (targetAnchor && targetAnchor.nodeType === 8) {
+ if (targetAnchor.data === "teleport start anchor") {
+ vnode2.targetStart = targetAnchor;
+ } else if (targetAnchor.data === "teleport anchor") {
+ vnode2.targetAnchor = targetAnchor;
+ target._lpa = vnode2.targetAnchor && nextSibling(vnode2.targetAnchor);
+ break;
+ }
+ }
+ targetAnchor = nextSibling(targetAnchor);
+ }
+ if (!vnode2.targetAnchor) {
+ prepareAnchor(target, vnode2, createText, insert);
+ }
+ hydrateChildren(
+ targetNode && nextSibling(targetNode),
+ vnode2,
+ target,
+ parentComponent,
+ parentSuspense,
+ slotScopeIds,
+ optimized
+ );
+ }
+ }
+ updateCssVars(vnode2, disabled);
+ }
+ return vnode2.anchor && nextSibling(vnode2.anchor);
+}
+const Teleport = TeleportImpl;
+function updateCssVars(vnode2, isDisabled) {
+ const ctx2 = vnode2.ctx;
+ if (ctx2 && ctx2.ut) {
+ let node, anchor;
+ if (isDisabled) {
+ node = vnode2.el;
+ anchor = vnode2.anchor;
+ } else {
+ node = vnode2.targetStart;
+ anchor = vnode2.targetAnchor;
+ }
+ while (node && node !== anchor) {
+ if (node.nodeType === 1) node.setAttribute("data-v-owner", ctx2.uid);
+ node = node.nextSibling;
+ }
+ ctx2.ut();
+ }
+}
+function prepareAnchor(target, vnode2, createText, insert) {
+ const targetStart = vnode2.targetStart = createText("");
+ const targetAnchor = vnode2.targetAnchor = createText("");
+ targetStart[TeleportEndKey] = targetAnchor;
+ if (target) {
+ insert(targetStart, target);
+ insert(targetAnchor, target);
+ }
+ return targetAnchor;
+}
+const leaveCbKey = Symbol("_leaveCb");
+const enterCbKey$1 = Symbol("_enterCb");
+function useTransitionState() {
+ const state2 = {
+ isMounted: false,
+ isLeaving: false,
+ isUnmounting: false,
+ leavingVNodes: /* @__PURE__ */ new Map()
+ };
+ onMounted(() => {
+ state2.isMounted = true;
+ });
+ onBeforeUnmount(() => {
+ state2.isUnmounting = true;
+ });
+ return state2;
+}
+const TransitionHookValidator = [Function, Array];
+const BaseTransitionPropsValidators = {
+ mode: String,
+ appear: Boolean,
+ persisted: Boolean,
+ // enter
+ onBeforeEnter: TransitionHookValidator,
+ onEnter: TransitionHookValidator,
+ onAfterEnter: TransitionHookValidator,
+ onEnterCancelled: TransitionHookValidator,
+ // leave
+ onBeforeLeave: TransitionHookValidator,
+ onLeave: TransitionHookValidator,
+ onAfterLeave: TransitionHookValidator,
+ onLeaveCancelled: TransitionHookValidator,
+ // appear
+ onBeforeAppear: TransitionHookValidator,
+ onAppear: TransitionHookValidator,
+ onAfterAppear: TransitionHookValidator,
+ onAppearCancelled: TransitionHookValidator
+};
+const recursiveGetSubtree = (instance) => {
+ const subTree = instance.subTree;
+ return subTree.component ? recursiveGetSubtree(subTree.component) : subTree;
+};
+const BaseTransitionImpl = {
+ name: `BaseTransition`,
+ props: BaseTransitionPropsValidators,
+ setup(props, { slots }) {
+ const instance = getCurrentInstance();
+ const state2 = useTransitionState();
+ return () => {
+ const children = slots.default && getTransitionRawChildren(slots.default(), true);
+ if (!children || !children.length) {
+ return;
+ }
+ const child = findNonCommentChild(children);
+ const rawProps = toRaw(props);
+ const { mode } = rawProps;
+ if (state2.isLeaving) {
+ return emptyPlaceholder(child);
+ }
+ const innerChild = getInnerChild$1(child);
+ if (!innerChild) {
+ return emptyPlaceholder(child);
+ }
+ let enterHooks = resolveTransitionHooks(
+ innerChild,
+ rawProps,
+ state2,
+ instance,
+ // #11061, ensure enterHooks is fresh after clone
+ (hooks) => enterHooks = hooks
+ );
+ if (innerChild.type !== Comment) {
+ setTransitionHooks(innerChild, enterHooks);
+ }
+ let oldInnerChild = instance.subTree && getInnerChild$1(instance.subTree);
+ if (oldInnerChild && oldInnerChild.type !== Comment && !isSameVNodeType(innerChild, oldInnerChild) && recursiveGetSubtree(instance).type !== Comment) {
+ let leavingHooks = resolveTransitionHooks(
+ oldInnerChild,
+ rawProps,
+ state2,
+ instance
+ );
+ setTransitionHooks(oldInnerChild, leavingHooks);
+ if (mode === "out-in" && innerChild.type !== Comment) {
+ state2.isLeaving = true;
+ leavingHooks.afterLeave = () => {
+ state2.isLeaving = false;
+ if (!(instance.job.flags & 8)) {
+ instance.update();
+ }
+ delete leavingHooks.afterLeave;
+ oldInnerChild = void 0;
+ };
+ return emptyPlaceholder(child);
+ } else if (mode === "in-out" && innerChild.type !== Comment) {
+ leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {
+ const leavingVNodesCache = getLeavingNodesForType(
+ state2,
+ oldInnerChild
+ );
+ leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;
+ el[leaveCbKey] = () => {
+ earlyRemove();
+ el[leaveCbKey] = void 0;
+ delete enterHooks.delayedLeave;
+ oldInnerChild = void 0;
+ };
+ enterHooks.delayedLeave = () => {
+ delayedLeave();
+ delete enterHooks.delayedLeave;
+ oldInnerChild = void 0;
+ };
+ };
+ } else {
+ oldInnerChild = void 0;
+ }
+ } else if (oldInnerChild) {
+ oldInnerChild = void 0;
+ }
+ return child;
+ };
+ }
+};
+function findNonCommentChild(children) {
+ let child = children[0];
+ if (children.length > 1) {
+ for (const c2 of children) {
+ if (c2.type !== Comment) {
+ child = c2;
+ break;
+ }
+ }
+ }
+ return child;
+}
+const BaseTransition = BaseTransitionImpl;
+function getLeavingNodesForType(state2, vnode2) {
+ const { leavingVNodes } = state2;
+ let leavingVNodesCache = leavingVNodes.get(vnode2.type);
+ if (!leavingVNodesCache) {
+ leavingVNodesCache = /* @__PURE__ */ Object.create(null);
+ leavingVNodes.set(vnode2.type, leavingVNodesCache);
+ }
+ return leavingVNodesCache;
+}
+function resolveTransitionHooks(vnode2, props, state2, instance, postClone) {
+ const {
+ appear,
+ mode,
+ persisted = false,
+ onBeforeEnter,
+ onEnter,
+ onAfterEnter,
+ onEnterCancelled,
+ onBeforeLeave,
+ onLeave,
+ onAfterLeave,
+ onLeaveCancelled,
+ onBeforeAppear,
+ onAppear,
+ onAfterAppear,
+ onAppearCancelled
+ } = props;
+ const key = String(vnode2.key);
+ const leavingVNodesCache = getLeavingNodesForType(state2, vnode2);
+ const callHook2 = (hook, args) => {
+ hook && callWithAsyncErrorHandling(
+ hook,
+ instance,
+ 9,
+ args
+ );
+ };
+ const callAsyncHook = (hook, args) => {
+ const done = args[1];
+ callHook2(hook, args);
+ if (isArray$3(hook)) {
+ if (hook.every((hook2) => hook2.length <= 1)) done();
+ } else if (hook.length <= 1) {
+ done();
+ }
+ };
+ const hooks = {
+ mode,
+ persisted,
+ beforeEnter(el) {
+ let hook = onBeforeEnter;
+ if (!state2.isMounted) {
+ if (appear) {
+ hook = onBeforeAppear || onBeforeEnter;
+ } else {
+ return;
+ }
+ }
+ if (el[leaveCbKey]) {
+ el[leaveCbKey](
+ true
+ /* cancelled */
+ );
+ }
+ const leavingVNode = leavingVNodesCache[key];
+ if (leavingVNode && isSameVNodeType(vnode2, leavingVNode) && leavingVNode.el[leaveCbKey]) {
+ leavingVNode.el[leaveCbKey]();
+ }
+ callHook2(hook, [el]);
+ },
+ enter(el) {
+ let hook = onEnter;
+ let afterHook = onAfterEnter;
+ let cancelHook = onEnterCancelled;
+ if (!state2.isMounted) {
+ if (appear) {
+ hook = onAppear || onEnter;
+ afterHook = onAfterAppear || onAfterEnter;
+ cancelHook = onAppearCancelled || onEnterCancelled;
+ } else {
+ return;
+ }
+ }
+ let called = false;
+ const done = el[enterCbKey$1] = (cancelled) => {
+ if (called) return;
+ called = true;
+ if (cancelled) {
+ callHook2(cancelHook, [el]);
+ } else {
+ callHook2(afterHook, [el]);
+ }
+ if (hooks.delayedLeave) {
+ hooks.delayedLeave();
+ }
+ el[enterCbKey$1] = void 0;
+ };
+ if (hook) {
+ callAsyncHook(hook, [el, done]);
+ } else {
+ done();
+ }
+ },
+ leave(el, remove2) {
+ const key2 = String(vnode2.key);
+ if (el[enterCbKey$1]) {
+ el[enterCbKey$1](
+ true
+ /* cancelled */
+ );
+ }
+ if (state2.isUnmounting) {
+ return remove2();
+ }
+ callHook2(onBeforeLeave, [el]);
+ let called = false;
+ const done = el[leaveCbKey] = (cancelled) => {
+ if (called) return;
+ called = true;
+ remove2();
+ if (cancelled) {
+ callHook2(onLeaveCancelled, [el]);
+ } else {
+ callHook2(onAfterLeave, [el]);
+ }
+ el[leaveCbKey] = void 0;
+ if (leavingVNodesCache[key2] === vnode2) {
+ delete leavingVNodesCache[key2];
+ }
+ };
+ leavingVNodesCache[key2] = vnode2;
+ if (onLeave) {
+ callAsyncHook(onLeave, [el, done]);
+ } else {
+ done();
+ }
+ },
+ clone(vnode22) {
+ const hooks2 = resolveTransitionHooks(
+ vnode22,
+ props,
+ state2,
+ instance,
+ postClone
+ );
+ if (postClone) postClone(hooks2);
+ return hooks2;
+ }
+ };
+ return hooks;
+}
+function emptyPlaceholder(vnode2) {
+ if (isKeepAlive(vnode2)) {
+ vnode2 = cloneVNode(vnode2);
+ vnode2.children = null;
+ return vnode2;
+ }
+}
+function getInnerChild$1(vnode2) {
+ if (!isKeepAlive(vnode2)) {
+ if (isTeleport(vnode2.type) && vnode2.children) {
+ return findNonCommentChild(vnode2.children);
+ }
+ return vnode2;
+ }
+ const { shapeFlag, children } = vnode2;
+ if (children) {
+ if (shapeFlag & 16) {
+ return children[0];
+ }
+ if (shapeFlag & 32 && isFunction$2(children.default)) {
+ return children.default();
+ }
+ }
+}
+function setTransitionHooks(vnode2, hooks) {
+ if (vnode2.shapeFlag & 6 && vnode2.component) {
+ vnode2.transition = hooks;
+ setTransitionHooks(vnode2.component.subTree, hooks);
+ } else if (vnode2.shapeFlag & 128) {
+ vnode2.ssContent.transition = hooks.clone(vnode2.ssContent);
+ vnode2.ssFallback.transition = hooks.clone(vnode2.ssFallback);
+ } else {
+ vnode2.transition = hooks;
+ }
+}
+function getTransitionRawChildren(children, keepComment = false, parentKey) {
+ let ret = [];
+ let keyedFragmentCount = 0;
+ for (let i = 0; i < children.length; i++) {
+ let child = children[i];
+ const key = parentKey == null ? child.key : String(parentKey) + String(child.key != null ? child.key : i);
+ if (child.type === Fragment) {
+ if (child.patchFlag & 128) keyedFragmentCount++;
+ ret = ret.concat(
+ getTransitionRawChildren(child.children, keepComment, key)
+ );
+ } else if (keepComment || child.type !== Comment) {
+ ret.push(key != null ? cloneVNode(child, { key }) : child);
+ }
+ }
+ if (keyedFragmentCount > 1) {
+ for (let i = 0; i < ret.length; i++) {
+ ret[i].patchFlag = -2;
+ }
+ }
+ return ret;
+}
+/*! #__NO_SIDE_EFFECTS__ */
+// @__NO_SIDE_EFFECTS__
+function defineComponent(options, extraOptions) {
+ return isFunction$2(options) ? (
+ // #8236: extend call and options.name access are considered side-effects
+ // by Rollup, so we have to wrap it in a pure-annotated IIFE.
+ /* @__PURE__ */ (() => extend$1({ name: options.name }, extraOptions, { setup: options }))()
+ ) : options;
+}
+function markAsyncBoundary(instance) {
+ instance.ids = [instance.ids[0] + instance.ids[2]++ + "-", 0, 0];
+}
+function useTemplateRef(key) {
+ const i = getCurrentInstance();
+ const r = shallowRef(null);
+ if (i) {
+ const refs = i.refs === EMPTY_OBJ ? i.refs = {} : i.refs;
+ {
+ Object.defineProperty(refs, key, {
+ enumerable: true,
+ get: () => r.value,
+ set: (val) => r.value = val
+ });
+ }
+ }
+ const ret = r;
+ return ret;
+}
+function setRef(rawRef, oldRawRef, parentSuspense, vnode2, isUnmount = false) {
+ if (isArray$3(rawRef)) {
+ rawRef.forEach(
+ (r, i) => setRef(
+ r,
+ oldRawRef && (isArray$3(oldRawRef) ? oldRawRef[i] : oldRawRef),
+ parentSuspense,
+ vnode2,
+ isUnmount
+ )
+ );
+ return;
+ }
+ if (isAsyncWrapper(vnode2) && !isUnmount) {
+ if (vnode2.shapeFlag & 512 && vnode2.type.__asyncResolved && vnode2.component.subTree.component) {
+ setRef(rawRef, oldRawRef, parentSuspense, vnode2.component.subTree);
+ }
+ return;
+ }
+ const refValue = vnode2.shapeFlag & 4 ? getComponentPublicInstance(vnode2.component) : vnode2.el;
+ const value = isUnmount ? null : refValue;
+ const { i: owner, r: ref3 } = rawRef;
+ const oldRef = oldRawRef && oldRawRef.r;
+ const refs = owner.refs === EMPTY_OBJ ? owner.refs = {} : owner.refs;
+ const setupState = owner.setupState;
+ const rawSetupState = toRaw(setupState);
+ const canSetSetupRef = setupState === EMPTY_OBJ ? () => false : (key) => {
+ return hasOwn(rawSetupState, key);
+ };
+ if (oldRef != null && oldRef !== ref3) {
+ if (isString$1(oldRef)) {
+ refs[oldRef] = null;
+ if (canSetSetupRef(oldRef)) {
+ setupState[oldRef] = null;
+ }
+ } else if (isRef(oldRef)) {
+ oldRef.value = null;
+ }
+ }
+ if (isFunction$2(ref3)) {
+ callWithErrorHandling(ref3, owner, 12, [value, refs]);
+ } else {
+ const _isString = isString$1(ref3);
+ const _isRef = isRef(ref3);
+ if (_isString || _isRef) {
+ const doSet = () => {
+ if (rawRef.f) {
+ const existing = _isString ? canSetSetupRef(ref3) ? setupState[ref3] : refs[ref3] : ref3.value;
+ if (isUnmount) {
+ isArray$3(existing) && remove(existing, refValue);
+ } else {
+ if (!isArray$3(existing)) {
+ if (_isString) {
+ refs[ref3] = [refValue];
+ if (canSetSetupRef(ref3)) {
+ setupState[ref3] = refs[ref3];
+ }
+ } else {
+ ref3.value = [refValue];
+ if (rawRef.k) refs[rawRef.k] = ref3.value;
+ }
+ } else if (!existing.includes(refValue)) {
+ existing.push(refValue);
+ }
+ }
+ } else if (_isString) {
+ refs[ref3] = value;
+ if (canSetSetupRef(ref3)) {
+ setupState[ref3] = value;
+ }
+ } else if (_isRef) {
+ ref3.value = value;
+ if (rawRef.k) refs[rawRef.k] = value;
+ } else ;
+ };
+ if (value) {
+ doSet.id = -1;
+ queuePostRenderEffect(doSet, parentSuspense);
+ } else {
+ doSet();
+ }
+ }
+ }
+}
+const isComment = (node) => node.nodeType === 8;
+getGlobalThis().requestIdleCallback || ((cb) => setTimeout(cb, 1));
+getGlobalThis().cancelIdleCallback || ((id) => clearTimeout(id));
+function forEachElement(node, cb) {
+ if (isComment(node) && node.data === "[") {
+ let depth = 1;
+ let next = node.nextSibling;
+ while (next) {
+ if (next.nodeType === 1) {
+ const result = cb(next);
+ if (result === false) {
+ break;
+ }
+ } else if (isComment(next)) {
+ if (next.data === "]") {
+ if (--depth === 0) break;
+ } else if (next.data === "[") {
+ depth++;
+ }
+ }
+ next = next.nextSibling;
+ }
+ } else {
+ cb(node);
+ }
+}
+const isAsyncWrapper = (i) => !!i.type.__asyncLoader;
+/*! #__NO_SIDE_EFFECTS__ */
+// @__NO_SIDE_EFFECTS__
+function defineAsyncComponent(source) {
+ if (isFunction$2(source)) {
+ source = { loader: source };
+ }
+ const {
+ loader,
+ loadingComponent,
+ errorComponent,
+ delay = 200,
+ hydrate: hydrateStrategy,
+ timeout,
+ // undefined = never times out
+ suspensible = true,
+ onError: userOnError
+ } = source;
+ let pendingRequest = null;
+ let resolvedComp;
+ let retries = 0;
+ const retry = () => {
+ retries++;
+ pendingRequest = null;
+ return load();
+ };
+ const load = () => {
+ let thisRequest;
+ return pendingRequest || (thisRequest = pendingRequest = loader().catch((err) => {
+ err = err instanceof Error ? err : new Error(String(err));
+ if (userOnError) {
+ return new Promise((resolve2, reject) => {
+ const userRetry = () => resolve2(retry());
+ const userFail = () => reject(err);
+ userOnError(err, userRetry, userFail, retries + 1);
+ });
+ } else {
+ throw err;
+ }
+ }).then((comp) => {
+ if (thisRequest !== pendingRequest && pendingRequest) {
+ return pendingRequest;
+ }
+ if (comp && (comp.__esModule || comp[Symbol.toStringTag] === "Module")) {
+ comp = comp.default;
+ }
+ resolvedComp = comp;
+ return comp;
+ }));
+ };
+ return /* @__PURE__ */ defineComponent({
+ name: "AsyncComponentWrapper",
+ __asyncLoader: load,
+ __asyncHydrate(el, instance, hydrate) {
+ const doHydrate = hydrateStrategy ? () => {
+ const teardown = hydrateStrategy(
+ hydrate,
+ (cb) => forEachElement(el, cb)
+ );
+ if (teardown) {
+ (instance.bum || (instance.bum = [])).push(teardown);
+ }
+ } : hydrate;
+ if (resolvedComp) {
+ doHydrate();
+ } else {
+ load().then(() => !instance.isUnmounted && doHydrate());
+ }
+ },
+ get __asyncResolved() {
+ return resolvedComp;
+ },
+ setup() {
+ const instance = currentInstance;
+ markAsyncBoundary(instance);
+ if (resolvedComp) {
+ return () => createInnerComp(resolvedComp, instance);
+ }
+ const onError = (err) => {
+ pendingRequest = null;
+ handleError(
+ err,
+ instance,
+ 13,
+ !errorComponent
+ );
+ };
+ if (suspensible && instance.suspense || isInSSRComponentSetup) {
+ return load().then((comp) => {
+ return () => createInnerComp(comp, instance);
+ }).catch((err) => {
+ onError(err);
+ return () => errorComponent ? createVNode(errorComponent, {
+ error: err
+ }) : null;
+ });
+ }
+ const loaded = ref(false);
+ const error = ref();
+ const delayed = ref(!!delay);
+ if (delay) {
+ setTimeout(() => {
+ delayed.value = false;
+ }, delay);
+ }
+ if (timeout != null) {
+ setTimeout(() => {
+ if (!loaded.value && !error.value) {
+ const err = new Error(
+ `Async component timed out after ${timeout}ms.`
+ );
+ onError(err);
+ error.value = err;
+ }
+ }, timeout);
+ }
+ load().then(() => {
+ loaded.value = true;
+ if (instance.parent && isKeepAlive(instance.parent.vnode)) {
+ instance.parent.update();
+ }
+ }).catch((err) => {
+ onError(err);
+ error.value = err;
+ });
+ return () => {
+ if (loaded.value && resolvedComp) {
+ return createInnerComp(resolvedComp, instance);
+ } else if (error.value && errorComponent) {
+ return createVNode(errorComponent, {
+ error: error.value
+ });
+ } else if (loadingComponent && !delayed.value) {
+ return createVNode(loadingComponent);
+ }
+ };
+ }
+ });
+}
+function createInnerComp(comp, parent) {
+ const { ref: ref22, props, children, ce } = parent.vnode;
+ const vnode2 = createVNode(comp, props, children);
+ vnode2.ref = ref22;
+ vnode2.ce = ce;
+ delete parent.vnode.ce;
+ return vnode2;
+}
+const isKeepAlive = (vnode2) => vnode2.type.__isKeepAlive;
+const KeepAliveImpl = {
+ name: `KeepAlive`,
+ // Marker for special handling inside the renderer. We are not using a ===
+ // check directly on KeepAlive in the renderer, because importing it directly
+ // would prevent it from being tree-shaken.
+ __isKeepAlive: true,
+ props: {
+ include: [String, RegExp, Array],
+ exclude: [String, RegExp, Array],
+ max: [String, Number]
+ },
+ setup(props, { slots }) {
+ const instance = getCurrentInstance();
+ const sharedContext = instance.ctx;
+ if (!sharedContext.renderer) {
+ return () => {
+ const children = slots.default && slots.default();
+ return children && children.length === 1 ? children[0] : children;
+ };
+ }
+ const cache2 = /* @__PURE__ */ new Map();
+ const keys = /* @__PURE__ */ new Set();
+ let current = null;
+ const parentSuspense = instance.suspense;
+ const {
+ renderer: {
+ p: patch,
+ m: move,
+ um: _unmount,
+ o: { createElement: createElement2 }
+ }
+ } = sharedContext;
+ const storageContainer = createElement2("div");
+ sharedContext.activate = (vnode2, container, anchor, namespace2, optimized) => {
+ const instance2 = vnode2.component;
+ move(vnode2, container, anchor, 0, parentSuspense);
+ patch(
+ instance2.vnode,
+ vnode2,
+ container,
+ anchor,
+ instance2,
+ parentSuspense,
+ namespace2,
+ vnode2.slotScopeIds,
+ optimized
+ );
+ queuePostRenderEffect(() => {
+ instance2.isDeactivated = false;
+ if (instance2.a) {
+ invokeArrayFns(instance2.a);
+ }
+ const vnodeHook = vnode2.props && vnode2.props.onVnodeMounted;
+ if (vnodeHook) {
+ invokeVNodeHook(vnodeHook, instance2.parent, vnode2);
+ }
+ }, parentSuspense);
+ };
+ sharedContext.deactivate = (vnode2) => {
+ const instance2 = vnode2.component;
+ invalidateMount(instance2.m);
+ invalidateMount(instance2.a);
+ move(vnode2, storageContainer, null, 1, parentSuspense);
+ queuePostRenderEffect(() => {
+ if (instance2.da) {
+ invokeArrayFns(instance2.da);
+ }
+ const vnodeHook = vnode2.props && vnode2.props.onVnodeUnmounted;
+ if (vnodeHook) {
+ invokeVNodeHook(vnodeHook, instance2.parent, vnode2);
+ }
+ instance2.isDeactivated = true;
+ }, parentSuspense);
+ };
+ function unmount2(vnode2) {
+ resetShapeFlag(vnode2);
+ _unmount(vnode2, instance, parentSuspense, true);
+ }
+ function pruneCache(filter2) {
+ cache2.forEach((vnode2, key) => {
+ const name2 = getComponentName(vnode2.type);
+ if (name2 && !filter2(name2)) {
+ pruneCacheEntry(key);
+ }
+ });
+ }
+ function pruneCacheEntry(key) {
+ const cached = cache2.get(key);
+ if (cached && (!current || !isSameVNodeType(cached, current))) {
+ unmount2(cached);
+ } else if (current) {
+ resetShapeFlag(current);
+ }
+ cache2.delete(key);
+ keys.delete(key);
+ }
+ watch(
+ () => [props.include, props.exclude],
+ ([include, exclude]) => {
+ include && pruneCache((name2) => matches(include, name2));
+ exclude && pruneCache((name2) => !matches(exclude, name2));
+ },
+ // prune post-render after `current` has been updated
+ { flush: "post", deep: true }
+ );
+ let pendingCacheKey = null;
+ const cacheSubtree = () => {
+ if (pendingCacheKey != null) {
+ if (isSuspense(instance.subTree.type)) {
+ queuePostRenderEffect(() => {
+ cache2.set(pendingCacheKey, getInnerChild(instance.subTree));
+ }, instance.subTree.suspense);
+ } else {
+ cache2.set(pendingCacheKey, getInnerChild(instance.subTree));
+ }
+ }
+ };
+ onMounted(cacheSubtree);
+ onUpdated(cacheSubtree);
+ onBeforeUnmount(() => {
+ cache2.forEach((cached) => {
+ const { subTree, suspense } = instance;
+ const vnode2 = getInnerChild(subTree);
+ if (cached.type === vnode2.type && cached.key === vnode2.key) {
+ resetShapeFlag(vnode2);
+ const da = vnode2.component.da;
+ da && queuePostRenderEffect(da, suspense);
+ return;
+ }
+ unmount2(cached);
+ });
+ });
+ return () => {
+ pendingCacheKey = null;
+ if (!slots.default) {
+ return current = null;
+ }
+ const children = slots.default();
+ const rawVNode = children[0];
+ if (children.length > 1) {
+ current = null;
+ return children;
+ } else if (!isVNode(rawVNode) || !(rawVNode.shapeFlag & 4) && !(rawVNode.shapeFlag & 128)) {
+ current = null;
+ return rawVNode;
+ }
+ let vnode2 = getInnerChild(rawVNode);
+ if (vnode2.type === Comment) {
+ current = null;
+ return vnode2;
+ }
+ const comp = vnode2.type;
+ const name2 = getComponentName(
+ isAsyncWrapper(vnode2) ? vnode2.type.__asyncResolved || {} : comp
+ );
+ const { include, exclude, max } = props;
+ if (include && (!name2 || !matches(include, name2)) || exclude && name2 && matches(exclude, name2)) {
+ vnode2.shapeFlag &= ~256;
+ current = vnode2;
+ return rawVNode;
+ }
+ const key = vnode2.key == null ? comp : vnode2.key;
+ const cachedVNode = cache2.get(key);
+ if (vnode2.el) {
+ vnode2 = cloneVNode(vnode2);
+ if (rawVNode.shapeFlag & 128) {
+ rawVNode.ssContent = vnode2;
+ }
+ }
+ pendingCacheKey = key;
+ if (cachedVNode) {
+ vnode2.el = cachedVNode.el;
+ vnode2.component = cachedVNode.component;
+ if (vnode2.transition) {
+ setTransitionHooks(vnode2, vnode2.transition);
+ }
+ vnode2.shapeFlag |= 512;
+ keys.delete(key);
+ keys.add(key);
+ } else {
+ keys.add(key);
+ if (max && keys.size > parseInt(max, 10)) {
+ pruneCacheEntry(keys.values().next().value);
+ }
+ }
+ vnode2.shapeFlag |= 256;
+ current = vnode2;
+ return isSuspense(rawVNode.type) ? rawVNode : vnode2;
+ };
+ }
+};
+const KeepAlive = KeepAliveImpl;
+function matches(pattern, name2) {
+ if (isArray$3(pattern)) {
+ return pattern.some((p2) => matches(p2, name2));
+ } else if (isString$1(pattern)) {
+ return pattern.split(",").includes(name2);
+ } else if (isRegExp$1(pattern)) {
+ pattern.lastIndex = 0;
+ return pattern.test(name2);
+ }
+ return false;
+}
+function onActivated(hook, target) {
+ registerKeepAliveHook(hook, "a", target);
+}
+function onDeactivated(hook, target) {
+ registerKeepAliveHook(hook, "da", target);
+}
+function registerKeepAliveHook(hook, type, target = currentInstance) {
+ const wrappedHook = hook.__wdc || (hook.__wdc = () => {
+ let current = target;
+ while (current) {
+ if (current.isDeactivated) {
+ return;
+ }
+ current = current.parent;
+ }
+ return hook();
+ });
+ injectHook(type, wrappedHook, target);
+ if (target) {
+ let current = target.parent;
+ while (current && current.parent) {
+ if (isKeepAlive(current.parent.vnode)) {
+ injectToKeepAliveRoot(wrappedHook, type, target, current);
+ }
+ current = current.parent;
+ }
+ }
+}
+function injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {
+ const injected = injectHook(
+ type,
+ hook,
+ keepAliveRoot,
+ true
+ /* prepend */
+ );
+ onUnmounted(() => {
+ remove(keepAliveRoot[type], injected);
+ }, target);
+}
+function resetShapeFlag(vnode2) {
+ vnode2.shapeFlag &= ~256;
+ vnode2.shapeFlag &= ~512;
+}
+function getInnerChild(vnode2) {
+ return vnode2.shapeFlag & 128 ? vnode2.ssContent : vnode2;
+}
+function injectHook(type, hook, target = currentInstance, prepend = false) {
+ if (target) {
+ const hooks = target[type] || (target[type] = []);
+ const wrappedHook = hook.__weh || (hook.__weh = (...args) => {
+ pauseTracking();
+ const reset = setCurrentInstance(target);
+ const res = callWithAsyncErrorHandling(hook, target, type, args);
+ reset();
+ resetTracking();
+ return res;
+ });
+ if (prepend) {
+ hooks.unshift(wrappedHook);
+ } else {
+ hooks.push(wrappedHook);
+ }
+ return wrappedHook;
+ }
+}
+const createHook = (lifecycle) => (hook, target = currentInstance) => {
+ if (!isInSSRComponentSetup || lifecycle === "sp") {
+ injectHook(lifecycle, (...args) => hook(...args), target);
+ }
+};
+const onBeforeMount = createHook("bm");
+const onMounted = createHook("m");
+const onBeforeUpdate = createHook(
+ "bu"
+);
+const onUpdated = createHook("u");
+const onBeforeUnmount = createHook(
+ "bum"
+);
+const onUnmounted = createHook("um");
+const onServerPrefetch = createHook(
+ "sp"
+);
+const onRenderTriggered = createHook("rtg");
+const onRenderTracked = createHook("rtc");
+function onErrorCaptured(hook, target = currentInstance) {
+ injectHook("ec", hook, target);
+}
+const COMPONENTS = "components";
+const DIRECTIVES = "directives";
+function resolveComponent(name2, maybeSelfReference) {
+ return resolveAsset(COMPONENTS, name2, true, maybeSelfReference) || name2;
+}
+const NULL_DYNAMIC_COMPONENT = Symbol.for("v-ndc");
+function resolveDynamicComponent(component) {
+ if (isString$1(component)) {
+ return resolveAsset(COMPONENTS, component, false) || component;
+ } else {
+ return component || NULL_DYNAMIC_COMPONENT;
+ }
+}
+function resolveDirective(name2) {
+ return resolveAsset(DIRECTIVES, name2);
+}
+function resolveAsset(type, name2, warnMissing = true, maybeSelfReference = false) {
+ const instance = currentRenderingInstance || currentInstance;
+ if (instance) {
+ const Component = instance.type;
+ if (type === COMPONENTS) {
+ const selfName = getComponentName(
+ Component,
+ false
+ );
+ if (selfName && (selfName === name2 || selfName === camelize(name2) || selfName === capitalize(camelize(name2)))) {
+ return Component;
+ }
+ }
+ const res = (
+ // local registration
+ // check instance[type] first which is resolved for options API
+ resolve(instance[type] || Component[type], name2) || // global registration
+ resolve(instance.appContext[type], name2)
+ );
+ if (!res && maybeSelfReference) {
+ return Component;
+ }
+ return res;
+ }
+}
+function resolve(registry, name2) {
+ return registry && (registry[name2] || registry[camelize(name2)] || registry[capitalize(camelize(name2))]);
+}
+function renderList(source, renderItem, cache2, index) {
+ let ret;
+ const cached = cache2;
+ const sourceIsArray = isArray$3(source);
+ if (sourceIsArray || isString$1(source)) {
+ const sourceIsReactiveArray = sourceIsArray && isReactive(source);
+ let needsWrap = false;
+ if (sourceIsReactiveArray) {
+ needsWrap = !isShallow(source);
+ source = shallowReadArray(source);
+ }
+ ret = new Array(source.length);
+ for (let i = 0, l = source.length; i < l; i++) {
+ ret[i] = renderItem(
+ needsWrap ? toReactive(source[i]) : source[i],
+ i,
+ void 0,
+ cached
+ );
+ }
+ } else if (typeof source === "number") {
+ ret = new Array(source);
+ for (let i = 0; i < source; i++) {
+ ret[i] = renderItem(i + 1, i, void 0, cached);
+ }
+ } else if (isObject$4(source)) {
+ if (source[Symbol.iterator]) {
+ ret = Array.from(
+ source,
+ (item, i) => renderItem(item, i, void 0, cached)
+ );
+ } else {
+ const keys = Object.keys(source);
+ ret = new Array(keys.length);
+ for (let i = 0, l = keys.length; i < l; i++) {
+ const key = keys[i];
+ ret[i] = renderItem(source[key], key, i, cached);
+ }
+ }
+ } else {
+ ret = [];
+ }
+ return ret;
+}
+function renderSlot(slots, name2, props = {}, fallback, noSlotted) {
+ if (currentRenderingInstance.ce || currentRenderingInstance.parent && isAsyncWrapper(currentRenderingInstance.parent) && currentRenderingInstance.parent.ce) {
+ return openBlock(), createBlock(
+ Fragment,
+ null,
+ [createVNode("slot", props, fallback && fallback())],
+ 64
+ );
+ }
+ let slot = slots[name2];
+ if (slot && slot._c) {
+ slot._d = false;
+ }
+ openBlock();
+ const validSlotContent = slot && ensureValidVNode$1(slot(props));
+ const slotKey = props.key || // slot content array of a dynamic conditional slot may have a branch
+ // key attached in the `createSlots` helper, respect that
+ validSlotContent && validSlotContent.key;
+ const rendered = createBlock(
+ Fragment,
+ {
+ key: (slotKey && !isSymbol$1(slotKey) ? slotKey : `_${name2}`) + // #7256 force differentiate fallback content from actual content
+ (!validSlotContent && fallback ? "_fb" : "")
+ },
+ validSlotContent || (fallback ? fallback() : []),
+ validSlotContent && slots._ === 1 ? 64 : -2
+ );
+ if (rendered.scopeId) {
+ rendered.slotScopeIds = [rendered.scopeId + "-s"];
+ }
+ if (slot && slot._c) {
+ slot._d = true;
+ }
+ return rendered;
+}
+function ensureValidVNode$1(vnodes) {
+ return vnodes.some((child) => {
+ if (!isVNode(child)) return true;
+ if (child.type === Comment) return false;
+ if (child.type === Fragment && !ensureValidVNode$1(child.children))
+ return false;
+ return true;
+ }) ? vnodes : null;
+}
+const getPublicInstance = (i) => {
+ if (!i) return null;
+ if (isStatefulComponent(i)) return getComponentPublicInstance(i);
+ return getPublicInstance(i.parent);
+};
+const publicPropertiesMap = (
+ // Move PURE marker to new line to workaround compiler discarding it
+ // due to type annotation
+ /* @__PURE__ */ extend$1(/* @__PURE__ */ Object.create(null), {
+ $: (i) => i,
+ $el: (i) => i.vnode.el,
+ $data: (i) => i.data,
+ $props: (i) => i.props,
+ $attrs: (i) => i.attrs,
+ $slots: (i) => i.slots,
+ $refs: (i) => i.refs,
+ $parent: (i) => getPublicInstance(i.parent),
+ $root: (i) => getPublicInstance(i.root),
+ $host: (i) => i.ce,
+ $emit: (i) => i.emit,
+ $options: (i) => resolveMergedOptions(i),
+ $forceUpdate: (i) => i.f || (i.f = () => {
+ queueJob(i.update);
+ }),
+ $nextTick: (i) => i.n || (i.n = nextTick.bind(i.proxy)),
+ $watch: (i) => instanceWatch.bind(i)
+ })
+);
+const hasSetupBinding = (state2, key) => state2 !== EMPTY_OBJ && !state2.__isScriptSetup && hasOwn(state2, key);
+const PublicInstanceProxyHandlers = {
+ get({ _: instance }, key) {
+ if (key === "__v_skip") {
+ return true;
+ }
+ const { ctx: ctx2, setupState, data, props, accessCache, type, appContext } = instance;
+ let normalizedProps;
+ if (key[0] !== "$") {
+ const n = accessCache[key];
+ if (n !== void 0) {
+ switch (n) {
+ case 1:
+ return setupState[key];
+ case 2:
+ return data[key];
+ case 4:
+ return ctx2[key];
+ case 3:
+ return props[key];
+ }
+ } else if (hasSetupBinding(setupState, key)) {
+ accessCache[key] = 1;
+ return setupState[key];
+ } else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
+ accessCache[key] = 2;
+ return data[key];
+ } else if (
+ // only cache other properties when instance has declared (thus stable)
+ // props
+ (normalizedProps = instance.propsOptions[0]) && hasOwn(normalizedProps, key)
+ ) {
+ accessCache[key] = 3;
+ return props[key];
+ } else if (ctx2 !== EMPTY_OBJ && hasOwn(ctx2, key)) {
+ accessCache[key] = 4;
+ return ctx2[key];
+ } else if (shouldCacheAccess) {
+ accessCache[key] = 0;
+ }
+ }
+ const publicGetter = publicPropertiesMap[key];
+ let cssModule, globalProperties;
+ if (publicGetter) {
+ if (key === "$attrs") {
+ track(instance.attrs, "get", "");
+ }
+ return publicGetter(instance);
+ } else if (
+ // css module (injected by vue-loader)
+ (cssModule = type.__cssModules) && (cssModule = cssModule[key])
+ ) {
+ return cssModule;
+ } else if (ctx2 !== EMPTY_OBJ && hasOwn(ctx2, key)) {
+ accessCache[key] = 4;
+ return ctx2[key];
+ } else if (
+ // global properties
+ globalProperties = appContext.config.globalProperties, hasOwn(globalProperties, key)
+ ) {
+ {
+ return globalProperties[key];
+ }
+ } else ;
+ },
+ set({ _: instance }, key, value) {
+ const { data, setupState, ctx: ctx2 } = instance;
+ if (hasSetupBinding(setupState, key)) {
+ setupState[key] = value;
+ return true;
+ } else if (data !== EMPTY_OBJ && hasOwn(data, key)) {
+ data[key] = value;
+ return true;
+ } else if (hasOwn(instance.props, key)) {
+ return false;
+ }
+ if (key[0] === "$" && key.slice(1) in instance) {
+ return false;
+ } else {
+ {
+ ctx2[key] = value;
+ }
+ }
+ return true;
+ },
+ has({
+ _: { data, setupState, accessCache, ctx: ctx2, appContext, propsOptions }
+ }, key) {
+ let normalizedProps;
+ return !!accessCache[key] || data !== EMPTY_OBJ && hasOwn(data, key) || hasSetupBinding(setupState, key) || (normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key) || hasOwn(ctx2, key) || hasOwn(publicPropertiesMap, key) || hasOwn(appContext.config.globalProperties, key);
+ },
+ defineProperty(target, key, descriptor) {
+ if (descriptor.get != null) {
+ target._.accessCache[key] = 0;
+ } else if (hasOwn(descriptor, "value")) {
+ this.set(target, key, descriptor.value, null);
+ }
+ return Reflect.defineProperty(target, key, descriptor);
+ }
+};
+function normalizePropsOrEmits(props) {
+ return isArray$3(props) ? props.reduce(
+ (normalized, p2) => (normalized[p2] = null, normalized),
+ {}
+ ) : props;
+}
+let shouldCacheAccess = true;
+function applyOptions(instance) {
+ const options = resolveMergedOptions(instance);
+ const publicThis = instance.proxy;
+ const ctx2 = instance.ctx;
+ shouldCacheAccess = false;
+ if (options.beforeCreate) {
+ callHook$1(options.beforeCreate, instance, "bc");
+ }
+ const {
+ // state
+ data: dataOptions,
+ computed: computedOptions,
+ methods,
+ watch: watchOptions,
+ provide: provideOptions,
+ inject: injectOptions,
+ // lifecycle
+ created,
+ beforeMount,
+ mounted,
+ beforeUpdate,
+ updated,
+ activated,
+ deactivated,
+ beforeDestroy,
+ beforeUnmount,
+ destroyed,
+ unmounted,
+ render: render2,
+ renderTracked,
+ renderTriggered,
+ errorCaptured,
+ serverPrefetch,
+ // public API
+ expose,
+ inheritAttrs,
+ // assets
+ components,
+ directives: directives2,
+ filters
+ } = options;
+ const checkDuplicateProperties = null;
+ if (injectOptions) {
+ resolveInjections(injectOptions, ctx2, checkDuplicateProperties);
+ }
+ if (methods) {
+ for (const key in methods) {
+ const methodHandler = methods[key];
+ if (isFunction$2(methodHandler)) {
+ {
+ ctx2[key] = methodHandler.bind(publicThis);
+ }
+ }
+ }
+ }
+ if (dataOptions) {
+ const data = dataOptions.call(publicThis, publicThis);
+ if (!isObject$4(data)) ;
+ else {
+ instance.data = reactive(data);
+ }
+ }
+ shouldCacheAccess = true;
+ if (computedOptions) {
+ for (const key in computedOptions) {
+ const opt = computedOptions[key];
+ const get2 = isFunction$2(opt) ? opt.bind(publicThis, publicThis) : isFunction$2(opt.get) ? opt.get.bind(publicThis, publicThis) : NOOP;
+ const set = !isFunction$2(opt) && isFunction$2(opt.set) ? opt.set.bind(publicThis) : NOOP;
+ const c2 = computed({
+ get: get2,
+ set
+ });
+ Object.defineProperty(ctx2, key, {
+ enumerable: true,
+ configurable: true,
+ get: () => c2.value,
+ set: (v) => c2.value = v
+ });
+ }
+ }
+ if (watchOptions) {
+ for (const key in watchOptions) {
+ createWatcher(watchOptions[key], ctx2, publicThis, key);
+ }
+ }
+ if (provideOptions) {
+ const provides = isFunction$2(provideOptions) ? provideOptions.call(publicThis) : provideOptions;
+ Reflect.ownKeys(provides).forEach((key) => {
+ provide(key, provides[key]);
+ });
+ }
+ if (created) {
+ callHook$1(created, instance, "c");
+ }
+ function registerLifecycleHook(register2, hook) {
+ if (isArray$3(hook)) {
+ hook.forEach((_hook) => register2(_hook.bind(publicThis)));
+ } else if (hook) {
+ register2(hook.bind(publicThis));
+ }
+ }
+ registerLifecycleHook(onBeforeMount, beforeMount);
+ registerLifecycleHook(onMounted, mounted);
+ registerLifecycleHook(onBeforeUpdate, beforeUpdate);
+ registerLifecycleHook(onUpdated, updated);
+ registerLifecycleHook(onActivated, activated);
+ registerLifecycleHook(onDeactivated, deactivated);
+ registerLifecycleHook(onErrorCaptured, errorCaptured);
+ registerLifecycleHook(onRenderTracked, renderTracked);
+ registerLifecycleHook(onRenderTriggered, renderTriggered);
+ registerLifecycleHook(onBeforeUnmount, beforeUnmount);
+ registerLifecycleHook(onUnmounted, unmounted);
+ registerLifecycleHook(onServerPrefetch, serverPrefetch);
+ if (isArray$3(expose)) {
+ if (expose.length) {
+ const exposed = instance.exposed || (instance.exposed = {});
+ expose.forEach((key) => {
+ Object.defineProperty(exposed, key, {
+ get: () => publicThis[key],
+ set: (val) => publicThis[key] = val
+ });
+ });
+ } else if (!instance.exposed) {
+ instance.exposed = {};
+ }
+ }
+ if (render2 && instance.render === NOOP) {
+ instance.render = render2;
+ }
+ if (inheritAttrs != null) {
+ instance.inheritAttrs = inheritAttrs;
+ }
+ if (components) instance.components = components;
+ if (directives2) instance.directives = directives2;
+ if (serverPrefetch) {
+ markAsyncBoundary(instance);
+ }
+}
+function resolveInjections(injectOptions, ctx2, checkDuplicateProperties = NOOP) {
+ if (isArray$3(injectOptions)) {
+ injectOptions = normalizeInject(injectOptions);
+ }
+ for (const key in injectOptions) {
+ const opt = injectOptions[key];
+ let injected;
+ if (isObject$4(opt)) {
+ if ("default" in opt) {
+ injected = inject(
+ opt.from || key,
+ opt.default,
+ true
+ );
+ } else {
+ injected = inject(opt.from || key);
+ }
+ } else {
+ injected = inject(opt);
+ }
+ if (isRef(injected)) {
+ Object.defineProperty(ctx2, key, {
+ enumerable: true,
+ configurable: true,
+ get: () => injected.value,
+ set: (v) => injected.value = v
+ });
+ } else {
+ ctx2[key] = injected;
+ }
+ }
+}
+function callHook$1(hook, instance, type) {
+ callWithAsyncErrorHandling(
+ isArray$3(hook) ? hook.map((h2) => h2.bind(instance.proxy)) : hook.bind(instance.proxy),
+ instance,
+ type
+ );
+}
+function createWatcher(raw, ctx2, publicThis, key) {
+ let getter = key.includes(".") ? createPathGetter(publicThis, key) : () => publicThis[key];
+ if (isString$1(raw)) {
+ const handler = ctx2[raw];
+ if (isFunction$2(handler)) {
+ {
+ watch(getter, handler);
+ }
+ }
+ } else if (isFunction$2(raw)) {
+ {
+ watch(getter, raw.bind(publicThis));
+ }
+ } else if (isObject$4(raw)) {
+ if (isArray$3(raw)) {
+ raw.forEach((r) => createWatcher(r, ctx2, publicThis, key));
+ } else {
+ const handler = isFunction$2(raw.handler) ? raw.handler.bind(publicThis) : ctx2[raw.handler];
+ if (isFunction$2(handler)) {
+ watch(getter, handler, raw);
+ }
+ }
+ } else ;
+}
+function resolveMergedOptions(instance) {
+ const base2 = instance.type;
+ const { mixins, extends: extendsOptions } = base2;
+ const {
+ mixins: globalMixins,
+ optionsCache: cache2,
+ config: { optionMergeStrategies }
+ } = instance.appContext;
+ const cached = cache2.get(base2);
+ let resolved;
+ if (cached) {
+ resolved = cached;
+ } else if (!globalMixins.length && !mixins && !extendsOptions) {
+ {
+ resolved = base2;
+ }
+ } else {
+ resolved = {};
+ if (globalMixins.length) {
+ globalMixins.forEach(
+ (m) => mergeOptions$1(resolved, m, optionMergeStrategies, true)
+ );
+ }
+ mergeOptions$1(resolved, base2, optionMergeStrategies);
+ }
+ if (isObject$4(base2)) {
+ cache2.set(base2, resolved);
+ }
+ return resolved;
+}
+function mergeOptions$1(to, from, strats, asMixin = false) {
+ const { mixins, extends: extendsOptions } = from;
+ if (extendsOptions) {
+ mergeOptions$1(to, extendsOptions, strats, true);
+ }
+ if (mixins) {
+ mixins.forEach(
+ (m) => mergeOptions$1(to, m, strats, true)
+ );
+ }
+ for (const key in from) {
+ if (asMixin && key === "expose") ;
+ else {
+ const strat = internalOptionMergeStrats[key] || strats && strats[key];
+ to[key] = strat ? strat(to[key], from[key]) : from[key];
+ }
+ }
+ return to;
+}
+const internalOptionMergeStrats = {
+ data: mergeDataFn,
+ props: mergeEmitsOrPropsOptions,
+ emits: mergeEmitsOrPropsOptions,
+ // objects
+ methods: mergeObjectOptions,
+ computed: mergeObjectOptions,
+ // lifecycle
+ beforeCreate: mergeAsArray,
+ created: mergeAsArray,
+ beforeMount: mergeAsArray,
+ mounted: mergeAsArray,
+ beforeUpdate: mergeAsArray,
+ updated: mergeAsArray,
+ beforeDestroy: mergeAsArray,
+ beforeUnmount: mergeAsArray,
+ destroyed: mergeAsArray,
+ unmounted: mergeAsArray,
+ activated: mergeAsArray,
+ deactivated: mergeAsArray,
+ errorCaptured: mergeAsArray,
+ serverPrefetch: mergeAsArray,
+ // assets
+ components: mergeObjectOptions,
+ directives: mergeObjectOptions,
+ // watch
+ watch: mergeWatchOptions,
+ // provide / inject
+ provide: mergeDataFn,
+ inject: mergeInject
+};
+function mergeDataFn(to, from) {
+ if (!from) {
+ return to;
+ }
+ if (!to) {
+ return from;
+ }
+ return function mergedDataFn() {
+ return extend$1(
+ isFunction$2(to) ? to.call(this, this) : to,
+ isFunction$2(from) ? from.call(this, this) : from
+ );
+ };
+}
+function mergeInject(to, from) {
+ return mergeObjectOptions(normalizeInject(to), normalizeInject(from));
+}
+function normalizeInject(raw) {
+ if (isArray$3(raw)) {
+ const res = {};
+ for (let i = 0; i < raw.length; i++) {
+ res[raw[i]] = raw[i];
+ }
+ return res;
+ }
+ return raw;
+}
+function mergeAsArray(to, from) {
+ return to ? [...new Set([].concat(to, from))] : from;
+}
+function mergeObjectOptions(to, from) {
+ return to ? extend$1(/* @__PURE__ */ Object.create(null), to, from) : from;
+}
+function mergeEmitsOrPropsOptions(to, from) {
+ if (to) {
+ if (isArray$3(to) && isArray$3(from)) {
+ return [.../* @__PURE__ */ new Set([...to, ...from])];
+ }
+ return extend$1(
+ /* @__PURE__ */ Object.create(null),
+ normalizePropsOrEmits(to),
+ normalizePropsOrEmits(from != null ? from : {})
+ );
+ } else {
+ return from;
+ }
+}
+function mergeWatchOptions(to, from) {
+ if (!to) return from;
+ if (!from) return to;
+ const merged = extend$1(/* @__PURE__ */ Object.create(null), to);
+ for (const key in from) {
+ merged[key] = mergeAsArray(to[key], from[key]);
+ }
+ return merged;
+}
+function createAppContext() {
+ return {
+ app: null,
+ config: {
+ isNativeTag: NO,
+ performance: false,
+ globalProperties: {},
+ optionMergeStrategies: {},
+ errorHandler: void 0,
+ warnHandler: void 0,
+ compilerOptions: {}
+ },
+ mixins: [],
+ components: {},
+ directives: {},
+ provides: /* @__PURE__ */ Object.create(null),
+ optionsCache: /* @__PURE__ */ new WeakMap(),
+ propsCache: /* @__PURE__ */ new WeakMap(),
+ emitsCache: /* @__PURE__ */ new WeakMap()
+ };
+}
+let uid$1 = 0;
+function createAppAPI(render2, hydrate) {
+ return function createApp2(rootComponent, rootProps = null) {
+ if (!isFunction$2(rootComponent)) {
+ rootComponent = extend$1({}, rootComponent);
+ }
+ if (rootProps != null && !isObject$4(rootProps)) {
+ rootProps = null;
+ }
+ const context = createAppContext();
+ const installedPlugins = /* @__PURE__ */ new WeakSet();
+ const pluginCleanupFns = [];
+ let isMounted2 = false;
+ const app2 = context.app = {
+ _uid: uid$1++,
+ _component: rootComponent,
+ _props: rootProps,
+ _container: null,
+ _context: context,
+ _instance: null,
+ version: version$1,
+ get config() {
+ return context.config;
+ },
+ set config(v) {
+ },
+ use(plugin2, ...options) {
+ if (installedPlugins.has(plugin2)) ;
+ else if (plugin2 && isFunction$2(plugin2.install)) {
+ installedPlugins.add(plugin2);
+ plugin2.install(app2, ...options);
+ } else if (isFunction$2(plugin2)) {
+ installedPlugins.add(plugin2);
+ plugin2(app2, ...options);
+ } else ;
+ return app2;
+ },
+ mixin(mixin) {
+ {
+ if (!context.mixins.includes(mixin)) {
+ context.mixins.push(mixin);
+ }
+ }
+ return app2;
+ },
+ component(name2, component) {
+ if (!component) {
+ return context.components[name2];
+ }
+ context.components[name2] = component;
+ return app2;
+ },
+ directive(name2, directive) {
+ if (!directive) {
+ return context.directives[name2];
+ }
+ context.directives[name2] = directive;
+ return app2;
+ },
+ mount(rootContainer, isHydrate, namespace2) {
+ if (!isMounted2) {
+ const vnode2 = app2._ceVNode || createVNode(rootComponent, rootProps);
+ vnode2.appContext = context;
+ if (namespace2 === true) {
+ namespace2 = "svg";
+ } else if (namespace2 === false) {
+ namespace2 = void 0;
+ }
+ {
+ render2(vnode2, rootContainer, namespace2);
+ }
+ isMounted2 = true;
+ app2._container = rootContainer;
+ rootContainer.__vue_app__ = app2;
+ return getComponentPublicInstance(vnode2.component);
+ }
+ },
+ onUnmount(cleanupFn) {
+ pluginCleanupFns.push(cleanupFn);
+ },
+ unmount() {
+ if (isMounted2) {
+ callWithAsyncErrorHandling(
+ pluginCleanupFns,
+ app2._instance,
+ 16
+ );
+ render2(null, app2._container);
+ delete app2._container.__vue_app__;
+ }
+ },
+ provide(key, value) {
+ context.provides[key] = value;
+ return app2;
+ },
+ runWithContext(fn) {
+ const lastApp = currentApp;
+ currentApp = app2;
+ try {
+ return fn();
+ } finally {
+ currentApp = lastApp;
+ }
+ }
+ };
+ return app2;
+ };
+}
+let currentApp = null;
+function provide(key, value) {
+ if (!currentInstance) ;
+ else {
+ let provides = currentInstance.provides;
+ const parentProvides = currentInstance.parent && currentInstance.parent.provides;
+ if (parentProvides === provides) {
+ provides = currentInstance.provides = Object.create(parentProvides);
+ }
+ provides[key] = value;
+ }
+}
+function inject(key, defaultValue, treatDefaultAsFactory = false) {
+ const instance = currentInstance || currentRenderingInstance;
+ if (instance || currentApp) {
+ const provides = currentApp ? currentApp._context.provides : instance ? instance.parent == null ? instance.vnode.appContext && instance.vnode.appContext.provides : instance.parent.provides : void 0;
+ if (provides && key in provides) {
+ return provides[key];
+ } else if (arguments.length > 1) {
+ return treatDefaultAsFactory && isFunction$2(defaultValue) ? defaultValue.call(instance && instance.proxy) : defaultValue;
+ } else ;
+ }
+}
+const internalObjectProto = {};
+const createInternalObject = () => Object.create(internalObjectProto);
+const isInternalObject = (obj) => Object.getPrototypeOf(obj) === internalObjectProto;
+function initProps(instance, rawProps, isStateful, isSSR = false) {
+ const props = {};
+ const attrs = createInternalObject();
+ instance.propsDefaults = /* @__PURE__ */ Object.create(null);
+ setFullProps(instance, rawProps, props, attrs);
+ for (const key in instance.propsOptions[0]) {
+ if (!(key in props)) {
+ props[key] = void 0;
+ }
+ }
+ if (isStateful) {
+ instance.props = isSSR ? props : shallowReactive(props);
+ } else {
+ if (!instance.type.props) {
+ instance.props = attrs;
+ } else {
+ instance.props = props;
+ }
+ }
+ instance.attrs = attrs;
+}
+function updateProps(instance, rawProps, rawPrevProps, optimized) {
+ const {
+ props,
+ attrs,
+ vnode: { patchFlag }
+ } = instance;
+ const rawCurrentProps = toRaw(props);
+ const [options] = instance.propsOptions;
+ let hasAttrsChanged = false;
+ if (
+ // always force full diff in dev
+ // - #1942 if hmr is enabled with sfc component
+ // - vite#872 non-sfc component used by sfc component
+ (optimized || patchFlag > 0) && !(patchFlag & 16)
+ ) {
+ if (patchFlag & 8) {
+ const propsToUpdate = instance.vnode.dynamicProps;
+ for (let i = 0; i < propsToUpdate.length; i++) {
+ let key = propsToUpdate[i];
+ if (isEmitListener(instance.emitsOptions, key)) {
+ continue;
+ }
+ const value = rawProps[key];
+ if (options) {
+ if (hasOwn(attrs, key)) {
+ if (value !== attrs[key]) {
+ attrs[key] = value;
+ hasAttrsChanged = true;
+ }
+ } else {
+ const camelizedKey = camelize(key);
+ props[camelizedKey] = resolvePropValue(
+ options,
+ rawCurrentProps,
+ camelizedKey,
+ value,
+ instance,
+ false
+ );
+ }
+ } else {
+ if (value !== attrs[key]) {
+ attrs[key] = value;
+ hasAttrsChanged = true;
+ }
+ }
+ }
+ }
+ } else {
+ if (setFullProps(instance, rawProps, props, attrs)) {
+ hasAttrsChanged = true;
+ }
+ let kebabKey;
+ for (const key in rawCurrentProps) {
+ if (!rawProps || // for camelCase
+ !hasOwn(rawProps, key) && // it's possible the original props was passed in as kebab-case
+ // and converted to camelCase (#955)
+ ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey))) {
+ if (options) {
+ if (rawPrevProps && // for camelCase
+ (rawPrevProps[key] !== void 0 || // for kebab-case
+ rawPrevProps[kebabKey] !== void 0)) {
+ props[key] = resolvePropValue(
+ options,
+ rawCurrentProps,
+ key,
+ void 0,
+ instance,
+ true
+ );
+ }
+ } else {
+ delete props[key];
+ }
+ }
+ }
+ if (attrs !== rawCurrentProps) {
+ for (const key in attrs) {
+ if (!rawProps || !hasOwn(rawProps, key) && true) {
+ delete attrs[key];
+ hasAttrsChanged = true;
+ }
+ }
+ }
+ }
+ if (hasAttrsChanged) {
+ trigger$1(instance.attrs, "set", "");
+ }
+}
+function setFullProps(instance, rawProps, props, attrs) {
+ const [options, needCastKeys] = instance.propsOptions;
+ let hasAttrsChanged = false;
+ let rawCastValues;
+ if (rawProps) {
+ for (let key in rawProps) {
+ if (isReservedProp(key)) {
+ continue;
+ }
+ const value = rawProps[key];
+ let camelKey;
+ if (options && hasOwn(options, camelKey = camelize(key))) {
+ if (!needCastKeys || !needCastKeys.includes(camelKey)) {
+ props[camelKey] = value;
+ } else {
+ (rawCastValues || (rawCastValues = {}))[camelKey] = value;
+ }
+ } else if (!isEmitListener(instance.emitsOptions, key)) {
+ if (!(key in attrs) || value !== attrs[key]) {
+ attrs[key] = value;
+ hasAttrsChanged = true;
+ }
+ }
+ }
+ }
+ if (needCastKeys) {
+ const rawCurrentProps = toRaw(props);
+ const castValues = rawCastValues || EMPTY_OBJ;
+ for (let i = 0; i < needCastKeys.length; i++) {
+ const key = needCastKeys[i];
+ props[key] = resolvePropValue(
+ options,
+ rawCurrentProps,
+ key,
+ castValues[key],
+ instance,
+ !hasOwn(castValues, key)
+ );
+ }
+ }
+ return hasAttrsChanged;
+}
+function resolvePropValue(options, props, key, value, instance, isAbsent) {
+ const opt = options[key];
+ if (opt != null) {
+ const hasDefault = hasOwn(opt, "default");
+ if (hasDefault && value === void 0) {
+ const defaultValue = opt.default;
+ if (opt.type !== Function && !opt.skipFactory && isFunction$2(defaultValue)) {
+ const { propsDefaults } = instance;
+ if (key in propsDefaults) {
+ value = propsDefaults[key];
+ } else {
+ const reset = setCurrentInstance(instance);
+ value = propsDefaults[key] = defaultValue.call(
+ null,
+ props
+ );
+ reset();
+ }
+ } else {
+ value = defaultValue;
+ }
+ if (instance.ce) {
+ instance.ce._setProp(key, value);
+ }
+ }
+ if (opt[
+ 0
+ /* shouldCast */
+ ]) {
+ if (isAbsent && !hasDefault) {
+ value = false;
+ } else if (opt[
+ 1
+ /* shouldCastTrue */
+ ] && (value === "" || value === hyphenate(key))) {
+ value = true;
+ }
+ }
+ }
+ return value;
+}
+const mixinPropsCache = /* @__PURE__ */ new WeakMap();
+function normalizePropsOptions(comp, appContext, asMixin = false) {
+ const cache2 = asMixin ? mixinPropsCache : appContext.propsCache;
+ const cached = cache2.get(comp);
+ if (cached) {
+ return cached;
+ }
+ const raw = comp.props;
+ const normalized = {};
+ const needCastKeys = [];
+ let hasExtends = false;
+ if (!isFunction$2(comp)) {
+ const extendProps = (raw2) => {
+ hasExtends = true;
+ const [props, keys] = normalizePropsOptions(raw2, appContext, true);
+ extend$1(normalized, props);
+ if (keys) needCastKeys.push(...keys);
+ };
+ if (!asMixin && appContext.mixins.length) {
+ appContext.mixins.forEach(extendProps);
+ }
+ if (comp.extends) {
+ extendProps(comp.extends);
+ }
+ if (comp.mixins) {
+ comp.mixins.forEach(extendProps);
+ }
+ }
+ if (!raw && !hasExtends) {
+ if (isObject$4(comp)) {
+ cache2.set(comp, EMPTY_ARR);
+ }
+ return EMPTY_ARR;
+ }
+ if (isArray$3(raw)) {
+ for (let i = 0; i < raw.length; i++) {
+ const normalizedKey = camelize(raw[i]);
+ if (validatePropName(normalizedKey)) {
+ normalized[normalizedKey] = EMPTY_OBJ;
+ }
+ }
+ } else if (raw) {
+ for (const key in raw) {
+ const normalizedKey = camelize(key);
+ if (validatePropName(normalizedKey)) {
+ const opt = raw[key];
+ const prop = normalized[normalizedKey] = isArray$3(opt) || isFunction$2(opt) ? { type: opt } : extend$1({}, opt);
+ const propType = prop.type;
+ let shouldCast = false;
+ let shouldCastTrue = true;
+ if (isArray$3(propType)) {
+ for (let index = 0; index < propType.length; ++index) {
+ const type = propType[index];
+ const typeName = isFunction$2(type) && type.name;
+ if (typeName === "Boolean") {
+ shouldCast = true;
+ break;
+ } else if (typeName === "String") {
+ shouldCastTrue = false;
+ }
+ }
+ } else {
+ shouldCast = isFunction$2(propType) && propType.name === "Boolean";
+ }
+ prop[
+ 0
+ /* shouldCast */
+ ] = shouldCast;
+ prop[
+ 1
+ /* shouldCastTrue */
+ ] = shouldCastTrue;
+ if (shouldCast || hasOwn(prop, "default")) {
+ needCastKeys.push(normalizedKey);
+ }
+ }
+ }
+ }
+ const res = [normalized, needCastKeys];
+ if (isObject$4(comp)) {
+ cache2.set(comp, res);
+ }
+ return res;
+}
+function validatePropName(key) {
+ if (key[0] !== "$" && !isReservedProp(key)) {
+ return true;
+ }
+ return false;
+}
+const isInternalKey = (key) => key[0] === "_" || key === "$stable";
+const normalizeSlotValue = (value) => isArray$3(value) ? value.map(normalizeVNode) : [normalizeVNode(value)];
+const normalizeSlot$1 = (key, rawSlot, ctx2) => {
+ if (rawSlot._n) {
+ return rawSlot;
+ }
+ const normalized = withCtx((...args) => {
+ if (false) ;
+ return normalizeSlotValue(rawSlot(...args));
+ }, ctx2);
+ normalized._c = false;
+ return normalized;
+};
+const normalizeObjectSlots = (rawSlots, slots, instance) => {
+ const ctx2 = rawSlots._ctx;
+ for (const key in rawSlots) {
+ if (isInternalKey(key)) continue;
+ const value = rawSlots[key];
+ if (isFunction$2(value)) {
+ slots[key] = normalizeSlot$1(key, value, ctx2);
+ } else if (value != null) {
+ const normalized = normalizeSlotValue(value);
+ slots[key] = () => normalized;
+ }
+ }
+};
+const normalizeVNodeSlots = (instance, children) => {
+ const normalized = normalizeSlotValue(children);
+ instance.slots.default = () => normalized;
+};
+const assignSlots = (slots, children, optimized) => {
+ for (const key in children) {
+ if (optimized || key !== "_") {
+ slots[key] = children[key];
+ }
+ }
+};
+const initSlots = (instance, children, optimized) => {
+ const slots = instance.slots = createInternalObject();
+ if (instance.vnode.shapeFlag & 32) {
+ const type = children._;
+ if (type) {
+ assignSlots(slots, children, optimized);
+ if (optimized) {
+ def$1(slots, "_", type, true);
+ }
+ } else {
+ normalizeObjectSlots(children, slots);
+ }
+ } else if (children) {
+ normalizeVNodeSlots(instance, children);
+ }
+};
+const updateSlots = (instance, children, optimized) => {
+ const { vnode: vnode2, slots } = instance;
+ let needDeletionCheck = true;
+ let deletionComparisonTarget = EMPTY_OBJ;
+ if (vnode2.shapeFlag & 32) {
+ const type = children._;
+ if (type) {
+ if (optimized && type === 1) {
+ needDeletionCheck = false;
+ } else {
+ assignSlots(slots, children, optimized);
+ }
+ } else {
+ needDeletionCheck = !children.$stable;
+ normalizeObjectSlots(children, slots);
+ }
+ deletionComparisonTarget = children;
+ } else if (children) {
+ normalizeVNodeSlots(instance, children);
+ deletionComparisonTarget = { default: 1 };
+ }
+ if (needDeletionCheck) {
+ for (const key in slots) {
+ if (!isInternalKey(key) && deletionComparisonTarget[key] == null) {
+ delete slots[key];
+ }
+ }
+ }
+};
+const queuePostRenderEffect = queueEffectWithSuspense;
+function createRenderer(options) {
+ return baseCreateRenderer(options);
+}
+function baseCreateRenderer(options, createHydrationFns) {
+ const target = getGlobalThis();
+ target.__VUE__ = true;
+ const {
+ insert: hostInsert,
+ remove: hostRemove,
+ patchProp: hostPatchProp,
+ createElement: hostCreateElement,
+ createText: hostCreateText,
+ createComment: hostCreateComment,
+ setText: hostSetText,
+ setElementText: hostSetElementText,
+ parentNode: hostParentNode,
+ nextSibling: hostNextSibling,
+ setScopeId: hostSetScopeId = NOOP,
+ insertStaticContent: hostInsertStaticContent
+ } = options;
+ const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, namespace2 = void 0, slotScopeIds = null, optimized = !!n2.dynamicChildren) => {
+ if (n1 === n2) {
+ return;
+ }
+ if (n1 && !isSameVNodeType(n1, n2)) {
+ anchor = getNextHostNode(n1);
+ unmount2(n1, parentComponent, parentSuspense, true);
+ n1 = null;
+ }
+ if (n2.patchFlag === -2) {
+ optimized = false;
+ n2.dynamicChildren = null;
+ }
+ const { type, ref: ref3, shapeFlag } = n2;
+ switch (type) {
+ case Text:
+ processText(n1, n2, container, anchor);
+ break;
+ case Comment:
+ processCommentNode(n1, n2, container, anchor);
+ break;
+ case Static:
+ if (n1 == null) {
+ mountStaticNode(n2, container, anchor, namespace2);
+ }
+ break;
+ case Fragment:
+ processFragment(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ break;
+ default:
+ if (shapeFlag & 1) {
+ processElement(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else if (shapeFlag & 6) {
+ processComponent(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else if (shapeFlag & 64) {
+ type.process(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized,
+ internals
+ );
+ } else if (shapeFlag & 128) {
+ type.process(
+ n1,
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized,
+ internals
+ );
+ } else ;
+ }
+ if (ref3 != null && parentComponent) {
+ setRef(ref3, n1 && n1.ref, parentSuspense, n2 || n1, !n2);
+ }
+ };
+ const processText = (n1, n2, container, anchor) => {
+ if (n1 == null) {
+ hostInsert(
+ n2.el = hostCreateText(n2.children),
+ container,
+ anchor
+ );
+ } else {
+ const el = n2.el = n1.el;
+ if (n2.children !== n1.children) {
+ hostSetText(el, n2.children);
+ }
+ }
+ };
+ const processCommentNode = (n1, n2, container, anchor) => {
+ if (n1 == null) {
+ hostInsert(
+ n2.el = hostCreateComment(n2.children || ""),
+ container,
+ anchor
+ );
+ } else {
+ n2.el = n1.el;
+ }
+ };
+ const mountStaticNode = (n2, container, anchor, namespace2) => {
+ [n2.el, n2.anchor] = hostInsertStaticContent(
+ n2.children,
+ container,
+ anchor,
+ namespace2,
+ n2.el,
+ n2.anchor
+ );
+ };
+ const moveStaticNode = ({ el, anchor }, container, nextSibling) => {
+ let next;
+ while (el && el !== anchor) {
+ next = hostNextSibling(el);
+ hostInsert(el, container, nextSibling);
+ el = next;
+ }
+ hostInsert(anchor, container, nextSibling);
+ };
+ const removeStaticNode = ({ el, anchor }) => {
+ let next;
+ while (el && el !== anchor) {
+ next = hostNextSibling(el);
+ hostRemove(el);
+ el = next;
+ }
+ hostRemove(anchor);
+ };
+ const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ if (n2.type === "svg") {
+ namespace2 = "svg";
+ } else if (n2.type === "math") {
+ namespace2 = "mathml";
+ }
+ if (n1 == null) {
+ mountElement(
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else {
+ patchElement(
+ n1,
+ n2,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ };
+ const mountElement = (vnode2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ let el;
+ let vnodeHook;
+ const { props, shapeFlag, transition, dirs } = vnode2;
+ el = vnode2.el = hostCreateElement(
+ vnode2.type,
+ namespace2,
+ props && props.is,
+ props
+ );
+ if (shapeFlag & 8) {
+ hostSetElementText(el, vnode2.children);
+ } else if (shapeFlag & 16) {
+ mountChildren(
+ vnode2.children,
+ el,
+ null,
+ parentComponent,
+ parentSuspense,
+ resolveChildrenNamespace(vnode2, namespace2),
+ slotScopeIds,
+ optimized
+ );
+ }
+ if (dirs) {
+ invokeDirectiveHook(vnode2, null, parentComponent, "created");
+ }
+ setScopeId(el, vnode2, vnode2.scopeId, slotScopeIds, parentComponent);
+ if (props) {
+ for (const key in props) {
+ if (key !== "value" && !isReservedProp(key)) {
+ hostPatchProp(el, key, null, props[key], namespace2, parentComponent);
+ }
+ }
+ if ("value" in props) {
+ hostPatchProp(el, "value", null, props.value, namespace2);
+ }
+ if (vnodeHook = props.onVnodeBeforeMount) {
+ invokeVNodeHook(vnodeHook, parentComponent, vnode2);
+ }
+ }
+ if (dirs) {
+ invokeDirectiveHook(vnode2, null, parentComponent, "beforeMount");
+ }
+ const needCallTransitionHooks = needTransition(parentSuspense, transition);
+ if (needCallTransitionHooks) {
+ transition.beforeEnter(el);
+ }
+ hostInsert(el, container, anchor);
+ if ((vnodeHook = props && props.onVnodeMounted) || needCallTransitionHooks || dirs) {
+ queuePostRenderEffect(() => {
+ vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode2);
+ needCallTransitionHooks && transition.enter(el);
+ dirs && invokeDirectiveHook(vnode2, null, parentComponent, "mounted");
+ }, parentSuspense);
+ }
+ };
+ const setScopeId = (el, vnode2, scopeId, slotScopeIds, parentComponent) => {
+ if (scopeId) {
+ hostSetScopeId(el, scopeId);
+ }
+ if (slotScopeIds) {
+ for (let i = 0; i < slotScopeIds.length; i++) {
+ hostSetScopeId(el, slotScopeIds[i]);
+ }
+ }
+ if (parentComponent) {
+ let subTree = parentComponent.subTree;
+ if (vnode2 === subTree || isSuspense(subTree.type) && (subTree.ssContent === vnode2 || subTree.ssFallback === vnode2)) {
+ const parentVNode = parentComponent.vnode;
+ setScopeId(
+ el,
+ parentVNode,
+ parentVNode.scopeId,
+ parentVNode.slotScopeIds,
+ parentComponent.parent
+ );
+ }
+ }
+ };
+ const mountChildren = (children, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized, start = 0) => {
+ for (let i = start; i < children.length; i++) {
+ const child = children[i] = optimized ? cloneIfMounted(children[i]) : normalizeVNode(children[i]);
+ patch(
+ null,
+ child,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ };
+ const patchElement = (n1, n2, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ const el = n2.el = n1.el;
+ let { patchFlag, dynamicChildren, dirs } = n2;
+ patchFlag |= n1.patchFlag & 16;
+ const oldProps = n1.props || EMPTY_OBJ;
+ const newProps = n2.props || EMPTY_OBJ;
+ let vnodeHook;
+ parentComponent && toggleRecurse(parentComponent, false);
+ if (vnodeHook = newProps.onVnodeBeforeUpdate) {
+ invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
+ }
+ if (dirs) {
+ invokeDirectiveHook(n2, n1, parentComponent, "beforeUpdate");
+ }
+ parentComponent && toggleRecurse(parentComponent, true);
+ if (oldProps.innerHTML && newProps.innerHTML == null || oldProps.textContent && newProps.textContent == null) {
+ hostSetElementText(el, "");
+ }
+ if (dynamicChildren) {
+ patchBlockChildren(
+ n1.dynamicChildren,
+ dynamicChildren,
+ el,
+ parentComponent,
+ parentSuspense,
+ resolveChildrenNamespace(n2, namespace2),
+ slotScopeIds
+ );
+ } else if (!optimized) {
+ patchChildren(
+ n1,
+ n2,
+ el,
+ null,
+ parentComponent,
+ parentSuspense,
+ resolveChildrenNamespace(n2, namespace2),
+ slotScopeIds,
+ false
+ );
+ }
+ if (patchFlag > 0) {
+ if (patchFlag & 16) {
+ patchProps(el, oldProps, newProps, parentComponent, namespace2);
+ } else {
+ if (patchFlag & 2) {
+ if (oldProps.class !== newProps.class) {
+ hostPatchProp(el, "class", null, newProps.class, namespace2);
+ }
+ }
+ if (patchFlag & 4) {
+ hostPatchProp(el, "style", oldProps.style, newProps.style, namespace2);
+ }
+ if (patchFlag & 8) {
+ const propsToUpdate = n2.dynamicProps;
+ for (let i = 0; i < propsToUpdate.length; i++) {
+ const key = propsToUpdate[i];
+ const prev = oldProps[key];
+ const next = newProps[key];
+ if (next !== prev || key === "value") {
+ hostPatchProp(el, key, prev, next, namespace2, parentComponent);
+ }
+ }
+ }
+ }
+ if (patchFlag & 1) {
+ if (n1.children !== n2.children) {
+ hostSetElementText(el, n2.children);
+ }
+ }
+ } else if (!optimized && dynamicChildren == null) {
+ patchProps(el, oldProps, newProps, parentComponent, namespace2);
+ }
+ if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {
+ queuePostRenderEffect(() => {
+ vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);
+ dirs && invokeDirectiveHook(n2, n1, parentComponent, "updated");
+ }, parentSuspense);
+ }
+ };
+ const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, namespace2, slotScopeIds) => {
+ for (let i = 0; i < newChildren.length; i++) {
+ const oldVNode = oldChildren[i];
+ const newVNode = newChildren[i];
+ const container = (
+ // oldVNode may be an errored async setup() component inside Suspense
+ // which will not have a mounted element
+ oldVNode.el && // - In the case of a Fragment, we need to provide the actual parent
+ // of the Fragment itself so it can move its children.
+ (oldVNode.type === Fragment || // - In the case of different nodes, there is going to be a replacement
+ // which also requires the correct parent container
+ !isSameVNodeType(oldVNode, newVNode) || // - In the case of a component, it could contain anything.
+ oldVNode.shapeFlag & (6 | 64)) ? hostParentNode(oldVNode.el) : (
+ // In other cases, the parent container is not actually used so we
+ // just pass the block element here to avoid a DOM parentNode call.
+ fallbackContainer
+ )
+ );
+ patch(
+ oldVNode,
+ newVNode,
+ container,
+ null,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ true
+ );
+ }
+ };
+ const patchProps = (el, oldProps, newProps, parentComponent, namespace2) => {
+ if (oldProps !== newProps) {
+ if (oldProps !== EMPTY_OBJ) {
+ for (const key in oldProps) {
+ if (!isReservedProp(key) && !(key in newProps)) {
+ hostPatchProp(
+ el,
+ key,
+ oldProps[key],
+ null,
+ namespace2,
+ parentComponent
+ );
+ }
+ }
+ }
+ for (const key in newProps) {
+ if (isReservedProp(key)) continue;
+ const next = newProps[key];
+ const prev = oldProps[key];
+ if (next !== prev && key !== "value") {
+ hostPatchProp(el, key, prev, next, namespace2, parentComponent);
+ }
+ }
+ if ("value" in newProps) {
+ hostPatchProp(el, "value", oldProps.value, newProps.value, namespace2);
+ }
+ }
+ };
+ const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ const fragmentStartAnchor = n2.el = n1 ? n1.el : hostCreateText("");
+ const fragmentEndAnchor = n2.anchor = n1 ? n1.anchor : hostCreateText("");
+ let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;
+ if (fragmentSlotScopeIds) {
+ slotScopeIds = slotScopeIds ? slotScopeIds.concat(fragmentSlotScopeIds) : fragmentSlotScopeIds;
+ }
+ if (n1 == null) {
+ hostInsert(fragmentStartAnchor, container, anchor);
+ hostInsert(fragmentEndAnchor, container, anchor);
+ mountChildren(
+ // #10007
+ // such fragment like `<>>` will be compiled into
+ // a fragment which doesn't have a children.
+ // In this case fallback to an empty array
+ n2.children || [],
+ container,
+ fragmentEndAnchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else {
+ if (patchFlag > 0 && patchFlag & 64 && dynamicChildren && // #2715 the previous fragment could've been a BAILed one as a result
+ // of renderSlot() with no valid children
+ n1.dynamicChildren) {
+ patchBlockChildren(
+ n1.dynamicChildren,
+ dynamicChildren,
+ container,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds
+ );
+ if (
+ // #2080 if the stable fragment has a key, it's a that may
+ // get moved around. Make sure all root level vnodes inherit el.
+ // #2134 or if it's a component root, it may also get moved around
+ // as the component is being moved.
+ n2.key != null || parentComponent && n2 === parentComponent.subTree
+ ) {
+ traverseStaticChildren(
+ n1,
+ n2,
+ true
+ /* shallow */
+ );
+ }
+ } else {
+ patchChildren(
+ n1,
+ n2,
+ container,
+ fragmentEndAnchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ }
+ };
+ const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ n2.slotScopeIds = slotScopeIds;
+ if (n1 == null) {
+ if (n2.shapeFlag & 512) {
+ parentComponent.ctx.activate(
+ n2,
+ container,
+ anchor,
+ namespace2,
+ optimized
+ );
+ } else {
+ mountComponent(
+ n2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ optimized
+ );
+ }
+ } else {
+ updateComponent(n1, n2, optimized);
+ }
+ };
+ const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, namespace2, optimized) => {
+ const instance = initialVNode.component = createComponentInstance(
+ initialVNode,
+ parentComponent,
+ parentSuspense
+ );
+ if (isKeepAlive(initialVNode)) {
+ instance.ctx.renderer = internals;
+ }
+ {
+ setupComponent(instance, false, optimized);
+ }
+ if (instance.asyncDep) {
+ parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect, optimized);
+ if (!initialVNode.el) {
+ const placeholder = instance.subTree = createVNode(Comment);
+ processCommentNode(null, placeholder, container, anchor);
+ }
+ } else {
+ setupRenderEffect(
+ instance,
+ initialVNode,
+ container,
+ anchor,
+ parentSuspense,
+ namespace2,
+ optimized
+ );
+ }
+ };
+ const updateComponent = (n1, n2, optimized) => {
+ const instance = n2.component = n1.component;
+ if (shouldUpdateComponent(n1, n2, optimized)) {
+ if (instance.asyncDep && !instance.asyncResolved) {
+ updateComponentPreRender(instance, n2, optimized);
+ return;
+ } else {
+ instance.next = n2;
+ instance.update();
+ }
+ } else {
+ n2.el = n1.el;
+ instance.vnode = n2;
+ }
+ };
+ const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, namespace2, optimized) => {
+ const componentUpdateFn = () => {
+ if (!instance.isMounted) {
+ let vnodeHook;
+ const { el, props } = initialVNode;
+ const { bm, m, parent, root: root2, type } = instance;
+ const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);
+ toggleRecurse(instance, false);
+ if (bm) {
+ invokeArrayFns(bm);
+ }
+ if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeBeforeMount)) {
+ invokeVNodeHook(vnodeHook, parent, initialVNode);
+ }
+ toggleRecurse(instance, true);
+ {
+ if (root2.ce) {
+ root2.ce._injectChildStyle(type);
+ }
+ const subTree = instance.subTree = renderComponentRoot(instance);
+ patch(
+ null,
+ subTree,
+ container,
+ anchor,
+ instance,
+ parentSuspense,
+ namespace2
+ );
+ initialVNode.el = subTree.el;
+ }
+ if (m) {
+ queuePostRenderEffect(m, parentSuspense);
+ }
+ if (!isAsyncWrapperVNode && (vnodeHook = props && props.onVnodeMounted)) {
+ const scopedInitialVNode = initialVNode;
+ queuePostRenderEffect(
+ () => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode),
+ parentSuspense
+ );
+ }
+ if (initialVNode.shapeFlag & 256 || parent && isAsyncWrapper(parent.vnode) && parent.vnode.shapeFlag & 256) {
+ instance.a && queuePostRenderEffect(instance.a, parentSuspense);
+ }
+ instance.isMounted = true;
+ initialVNode = container = anchor = null;
+ } else {
+ let { next, bu, u, parent, vnode: vnode2 } = instance;
+ {
+ const nonHydratedAsyncRoot = locateNonHydratedAsyncRoot(instance);
+ if (nonHydratedAsyncRoot) {
+ if (next) {
+ next.el = vnode2.el;
+ updateComponentPreRender(instance, next, optimized);
+ }
+ nonHydratedAsyncRoot.asyncDep.then(() => {
+ if (!instance.isUnmounted) {
+ componentUpdateFn();
+ }
+ });
+ return;
+ }
+ }
+ let originNext = next;
+ let vnodeHook;
+ toggleRecurse(instance, false);
+ if (next) {
+ next.el = vnode2.el;
+ updateComponentPreRender(instance, next, optimized);
+ } else {
+ next = vnode2;
+ }
+ if (bu) {
+ invokeArrayFns(bu);
+ }
+ if (vnodeHook = next.props && next.props.onVnodeBeforeUpdate) {
+ invokeVNodeHook(vnodeHook, parent, next, vnode2);
+ }
+ toggleRecurse(instance, true);
+ const nextTree = renderComponentRoot(instance);
+ const prevTree = instance.subTree;
+ instance.subTree = nextTree;
+ patch(
+ prevTree,
+ nextTree,
+ // parent may have changed if it's in a teleport
+ hostParentNode(prevTree.el),
+ // anchor may have changed if it's in a fragment
+ getNextHostNode(prevTree),
+ instance,
+ parentSuspense,
+ namespace2
+ );
+ next.el = nextTree.el;
+ if (originNext === null) {
+ updateHOCHostEl(instance, nextTree.el);
+ }
+ if (u) {
+ queuePostRenderEffect(u, parentSuspense);
+ }
+ if (vnodeHook = next.props && next.props.onVnodeUpdated) {
+ queuePostRenderEffect(
+ () => invokeVNodeHook(vnodeHook, parent, next, vnode2),
+ parentSuspense
+ );
+ }
+ }
+ };
+ instance.scope.on();
+ const effect2 = instance.effect = new ReactiveEffect(componentUpdateFn);
+ instance.scope.off();
+ const update3 = instance.update = effect2.run.bind(effect2);
+ const job = instance.job = effect2.runIfDirty.bind(effect2);
+ job.i = instance;
+ job.id = instance.uid;
+ effect2.scheduler = () => queueJob(job);
+ toggleRecurse(instance, true);
+ update3();
+ };
+ const updateComponentPreRender = (instance, nextVNode, optimized) => {
+ nextVNode.component = instance;
+ const prevProps = instance.vnode.props;
+ instance.vnode = nextVNode;
+ instance.next = null;
+ updateProps(instance, nextVNode.props, prevProps, optimized);
+ updateSlots(instance, nextVNode.children, optimized);
+ pauseTracking();
+ flushPreFlushCbs(instance);
+ resetTracking();
+ };
+ const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized = false) => {
+ const c1 = n1 && n1.children;
+ const prevShapeFlag = n1 ? n1.shapeFlag : 0;
+ const c2 = n2.children;
+ const { patchFlag, shapeFlag } = n2;
+ if (patchFlag > 0) {
+ if (patchFlag & 128) {
+ patchKeyedChildren(
+ c1,
+ c2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ return;
+ } else if (patchFlag & 256) {
+ patchUnkeyedChildren(
+ c1,
+ c2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ return;
+ }
+ }
+ if (shapeFlag & 8) {
+ if (prevShapeFlag & 16) {
+ unmountChildren(c1, parentComponent, parentSuspense);
+ }
+ if (c2 !== c1) {
+ hostSetElementText(container, c2);
+ }
+ } else {
+ if (prevShapeFlag & 16) {
+ if (shapeFlag & 16) {
+ patchKeyedChildren(
+ c1,
+ c2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else {
+ unmountChildren(c1, parentComponent, parentSuspense, true);
+ }
+ } else {
+ if (prevShapeFlag & 8) {
+ hostSetElementText(container, "");
+ }
+ if (shapeFlag & 16) {
+ mountChildren(
+ c2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ }
+ }
+ };
+ const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ c1 = c1 || EMPTY_ARR;
+ c2 = c2 || EMPTY_ARR;
+ const oldLength = c1.length;
+ const newLength = c2.length;
+ const commonLength = Math.min(oldLength, newLength);
+ let i;
+ for (i = 0; i < commonLength; i++) {
+ const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
+ patch(
+ c1[i],
+ nextChild,
+ container,
+ null,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ }
+ if (oldLength > newLength) {
+ unmountChildren(
+ c1,
+ parentComponent,
+ parentSuspense,
+ true,
+ false,
+ commonLength
+ );
+ } else {
+ mountChildren(
+ c2,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized,
+ commonLength
+ );
+ }
+ };
+ const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, namespace2, slotScopeIds, optimized) => {
+ let i = 0;
+ const l2 = c2.length;
+ let e1 = c1.length - 1;
+ let e2 = l2 - 1;
+ while (i <= e1 && i <= e2) {
+ const n1 = c1[i];
+ const n2 = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
+ if (isSameVNodeType(n1, n2)) {
+ patch(
+ n1,
+ n2,
+ container,
+ null,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else {
+ break;
+ }
+ i++;
+ }
+ while (i <= e1 && i <= e2) {
+ const n1 = c1[e1];
+ const n2 = c2[e2] = optimized ? cloneIfMounted(c2[e2]) : normalizeVNode(c2[e2]);
+ if (isSameVNodeType(n1, n2)) {
+ patch(
+ n1,
+ n2,
+ container,
+ null,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else {
+ break;
+ }
+ e1--;
+ e2--;
+ }
+ if (i > e1) {
+ if (i <= e2) {
+ const nextPos = e2 + 1;
+ const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;
+ while (i <= e2) {
+ patch(
+ null,
+ c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]),
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ i++;
+ }
+ }
+ } else if (i > e2) {
+ while (i <= e1) {
+ unmount2(c1[i], parentComponent, parentSuspense, true);
+ i++;
+ }
+ } else {
+ const s1 = i;
+ const s2 = i;
+ const keyToNewIndexMap = /* @__PURE__ */ new Map();
+ for (i = s2; i <= e2; i++) {
+ const nextChild = c2[i] = optimized ? cloneIfMounted(c2[i]) : normalizeVNode(c2[i]);
+ if (nextChild.key != null) {
+ keyToNewIndexMap.set(nextChild.key, i);
+ }
+ }
+ let j;
+ let patched = 0;
+ const toBePatched = e2 - s2 + 1;
+ let moved = false;
+ let maxNewIndexSoFar = 0;
+ const newIndexToOldIndexMap = new Array(toBePatched);
+ for (i = 0; i < toBePatched; i++) newIndexToOldIndexMap[i] = 0;
+ for (i = s1; i <= e1; i++) {
+ const prevChild = c1[i];
+ if (patched >= toBePatched) {
+ unmount2(prevChild, parentComponent, parentSuspense, true);
+ continue;
+ }
+ let newIndex;
+ if (prevChild.key != null) {
+ newIndex = keyToNewIndexMap.get(prevChild.key);
+ } else {
+ for (j = s2; j <= e2; j++) {
+ if (newIndexToOldIndexMap[j - s2] === 0 && isSameVNodeType(prevChild, c2[j])) {
+ newIndex = j;
+ break;
+ }
+ }
+ }
+ if (newIndex === void 0) {
+ unmount2(prevChild, parentComponent, parentSuspense, true);
+ } else {
+ newIndexToOldIndexMap[newIndex - s2] = i + 1;
+ if (newIndex >= maxNewIndexSoFar) {
+ maxNewIndexSoFar = newIndex;
+ } else {
+ moved = true;
+ }
+ patch(
+ prevChild,
+ c2[newIndex],
+ container,
+ null,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ patched++;
+ }
+ }
+ const increasingNewIndexSequence = moved ? getSequence(newIndexToOldIndexMap) : EMPTY_ARR;
+ j = increasingNewIndexSequence.length - 1;
+ for (i = toBePatched - 1; i >= 0; i--) {
+ const nextIndex = s2 + i;
+ const nextChild = c2[nextIndex];
+ const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;
+ if (newIndexToOldIndexMap[i] === 0) {
+ patch(
+ null,
+ nextChild,
+ container,
+ anchor,
+ parentComponent,
+ parentSuspense,
+ namespace2,
+ slotScopeIds,
+ optimized
+ );
+ } else if (moved) {
+ if (j < 0 || i !== increasingNewIndexSequence[j]) {
+ move(nextChild, container, anchor, 2);
+ } else {
+ j--;
+ }
+ }
+ }
+ }
+ };
+ const move = (vnode2, container, anchor, moveType, parentSuspense = null) => {
+ const { el, type, transition, children, shapeFlag } = vnode2;
+ if (shapeFlag & 6) {
+ move(vnode2.component.subTree, container, anchor, moveType);
+ return;
+ }
+ if (shapeFlag & 128) {
+ vnode2.suspense.move(container, anchor, moveType);
+ return;
+ }
+ if (shapeFlag & 64) {
+ type.move(vnode2, container, anchor, internals);
+ return;
+ }
+ if (type === Fragment) {
+ hostInsert(el, container, anchor);
+ for (let i = 0; i < children.length; i++) {
+ move(children[i], container, anchor, moveType);
+ }
+ hostInsert(vnode2.anchor, container, anchor);
+ return;
+ }
+ if (type === Static) {
+ moveStaticNode(vnode2, container, anchor);
+ return;
+ }
+ const needTransition2 = moveType !== 2 && shapeFlag & 1 && transition;
+ if (needTransition2) {
+ if (moveType === 0) {
+ transition.beforeEnter(el);
+ hostInsert(el, container, anchor);
+ queuePostRenderEffect(() => transition.enter(el), parentSuspense);
+ } else {
+ const { leave, delayLeave, afterLeave } = transition;
+ const remove22 = () => hostInsert(el, container, anchor);
+ const performLeave = () => {
+ leave(el, () => {
+ remove22();
+ afterLeave && afterLeave();
+ });
+ };
+ if (delayLeave) {
+ delayLeave(el, remove22, performLeave);
+ } else {
+ performLeave();
+ }
+ }
+ } else {
+ hostInsert(el, container, anchor);
+ }
+ };
+ const unmount2 = (vnode2, parentComponent, parentSuspense, doRemove = false, optimized = false) => {
+ const {
+ type,
+ props,
+ ref: ref3,
+ children,
+ dynamicChildren,
+ shapeFlag,
+ patchFlag,
+ dirs,
+ cacheIndex
+ } = vnode2;
+ if (patchFlag === -2) {
+ optimized = false;
+ }
+ if (ref3 != null) {
+ setRef(ref3, null, parentSuspense, vnode2, true);
+ }
+ if (cacheIndex != null) {
+ parentComponent.renderCache[cacheIndex] = void 0;
+ }
+ if (shapeFlag & 256) {
+ parentComponent.ctx.deactivate(vnode2);
+ return;
+ }
+ const shouldInvokeDirs = shapeFlag & 1 && dirs;
+ const shouldInvokeVnodeHook = !isAsyncWrapper(vnode2);
+ let vnodeHook;
+ if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeBeforeUnmount)) {
+ invokeVNodeHook(vnodeHook, parentComponent, vnode2);
+ }
+ if (shapeFlag & 6) {
+ unmountComponent(vnode2.component, parentSuspense, doRemove);
+ } else {
+ if (shapeFlag & 128) {
+ vnode2.suspense.unmount(parentSuspense, doRemove);
+ return;
+ }
+ if (shouldInvokeDirs) {
+ invokeDirectiveHook(vnode2, null, parentComponent, "beforeUnmount");
+ }
+ if (shapeFlag & 64) {
+ vnode2.type.remove(
+ vnode2,
+ parentComponent,
+ parentSuspense,
+ internals,
+ doRemove
+ );
+ } else if (dynamicChildren && // #5154
+ // when v-once is used inside a block, setBlockTracking(-1) marks the
+ // parent block with hasOnce: true
+ // so that it doesn't take the fast path during unmount - otherwise
+ // components nested in v-once are never unmounted.
+ !dynamicChildren.hasOnce && // #1153: fast path should not be taken for non-stable (v-for) fragments
+ (type !== Fragment || patchFlag > 0 && patchFlag & 64)) {
+ unmountChildren(
+ dynamicChildren,
+ parentComponent,
+ parentSuspense,
+ false,
+ true
+ );
+ } else if (type === Fragment && patchFlag & (128 | 256) || !optimized && shapeFlag & 16) {
+ unmountChildren(children, parentComponent, parentSuspense);
+ }
+ if (doRemove) {
+ remove2(vnode2);
+ }
+ }
+ if (shouldInvokeVnodeHook && (vnodeHook = props && props.onVnodeUnmounted) || shouldInvokeDirs) {
+ queuePostRenderEffect(() => {
+ vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode2);
+ shouldInvokeDirs && invokeDirectiveHook(vnode2, null, parentComponent, "unmounted");
+ }, parentSuspense);
+ }
+ };
+ const remove2 = (vnode2) => {
+ const { type, el, anchor, transition } = vnode2;
+ if (type === Fragment) {
+ {
+ removeFragment(el, anchor);
+ }
+ return;
+ }
+ if (type === Static) {
+ removeStaticNode(vnode2);
+ return;
+ }
+ const performRemove = () => {
+ hostRemove(el);
+ if (transition && !transition.persisted && transition.afterLeave) {
+ transition.afterLeave();
+ }
+ };
+ if (vnode2.shapeFlag & 1 && transition && !transition.persisted) {
+ const { leave, delayLeave } = transition;
+ const performLeave = () => leave(el, performRemove);
+ if (delayLeave) {
+ delayLeave(vnode2.el, performRemove, performLeave);
+ } else {
+ performLeave();
+ }
+ } else {
+ performRemove();
+ }
+ };
+ const removeFragment = (cur, end) => {
+ let next;
+ while (cur !== end) {
+ next = hostNextSibling(cur);
+ hostRemove(cur);
+ cur = next;
+ }
+ hostRemove(end);
+ };
+ const unmountComponent = (instance, parentSuspense, doRemove) => {
+ const { bum, scope, job, subTree, um, m, a } = instance;
+ invalidateMount(m);
+ invalidateMount(a);
+ if (bum) {
+ invokeArrayFns(bum);
+ }
+ scope.stop();
+ if (job) {
+ job.flags |= 8;
+ unmount2(subTree, instance, parentSuspense, doRemove);
+ }
+ if (um) {
+ queuePostRenderEffect(um, parentSuspense);
+ }
+ queuePostRenderEffect(() => {
+ instance.isUnmounted = true;
+ }, parentSuspense);
+ if (parentSuspense && parentSuspense.pendingBranch && !parentSuspense.isUnmounted && instance.asyncDep && !instance.asyncResolved && instance.suspenseId === parentSuspense.pendingId) {
+ parentSuspense.deps--;
+ if (parentSuspense.deps === 0) {
+ parentSuspense.resolve();
+ }
+ }
+ };
+ const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {
+ for (let i = start; i < children.length; i++) {
+ unmount2(children[i], parentComponent, parentSuspense, doRemove, optimized);
+ }
+ };
+ const getNextHostNode = (vnode2) => {
+ if (vnode2.shapeFlag & 6) {
+ return getNextHostNode(vnode2.component.subTree);
+ }
+ if (vnode2.shapeFlag & 128) {
+ return vnode2.suspense.next();
+ }
+ const el = hostNextSibling(vnode2.anchor || vnode2.el);
+ const teleportEnd = el && el[TeleportEndKey];
+ return teleportEnd ? hostNextSibling(teleportEnd) : el;
+ };
+ let isFlushing = false;
+ const render2 = (vnode2, container, namespace2) => {
+ if (vnode2 == null) {
+ if (container._vnode) {
+ unmount2(container._vnode, null, null, true);
+ }
+ } else {
+ patch(
+ container._vnode || null,
+ vnode2,
+ container,
+ null,
+ null,
+ null,
+ namespace2
+ );
+ }
+ container._vnode = vnode2;
+ if (!isFlushing) {
+ isFlushing = true;
+ flushPreFlushCbs();
+ flushPostFlushCbs();
+ isFlushing = false;
+ }
+ };
+ const internals = {
+ p: patch,
+ um: unmount2,
+ m: move,
+ r: remove2,
+ mt: mountComponent,
+ mc: mountChildren,
+ pc: patchChildren,
+ pbc: patchBlockChildren,
+ n: getNextHostNode,
+ o: options
+ };
+ let hydrate;
+ return {
+ render: render2,
+ hydrate,
+ createApp: createAppAPI(render2)
+ };
+}
+function resolveChildrenNamespace({ type, props }, currentNamespace) {
+ return currentNamespace === "svg" && type === "foreignObject" || currentNamespace === "mathml" && type === "annotation-xml" && props && props.encoding && props.encoding.includes("html") ? void 0 : currentNamespace;
+}
+function toggleRecurse({ effect: effect2, job }, allowed) {
+ if (allowed) {
+ effect2.flags |= 32;
+ job.flags |= 4;
+ } else {
+ effect2.flags &= ~32;
+ job.flags &= ~4;
+ }
+}
+function needTransition(parentSuspense, transition) {
+ return (!parentSuspense || parentSuspense && !parentSuspense.pendingBranch) && transition && !transition.persisted;
+}
+function traverseStaticChildren(n1, n2, shallow = false) {
+ const ch1 = n1.children;
+ const ch2 = n2.children;
+ if (isArray$3(ch1) && isArray$3(ch2)) {
+ for (let i = 0; i < ch1.length; i++) {
+ const c1 = ch1[i];
+ let c2 = ch2[i];
+ if (c2.shapeFlag & 1 && !c2.dynamicChildren) {
+ if (c2.patchFlag <= 0 || c2.patchFlag === 32) {
+ c2 = ch2[i] = cloneIfMounted(ch2[i]);
+ c2.el = c1.el;
+ }
+ if (!shallow && c2.patchFlag !== -2)
+ traverseStaticChildren(c1, c2);
+ }
+ if (c2.type === Text) {
+ c2.el = c1.el;
+ }
+ }
+ }
+}
+function getSequence(arr) {
+ const p2 = arr.slice();
+ const result = [0];
+ let i, j, u, v, c2;
+ const len = arr.length;
+ for (i = 0; i < len; i++) {
+ const arrI = arr[i];
+ if (arrI !== 0) {
+ j = result[result.length - 1];
+ if (arr[j] < arrI) {
+ p2[i] = j;
+ result.push(i);
+ continue;
+ }
+ u = 0;
+ v = result.length - 1;
+ while (u < v) {
+ c2 = u + v >> 1;
+ if (arr[result[c2]] < arrI) {
+ u = c2 + 1;
+ } else {
+ v = c2;
+ }
+ }
+ if (arrI < arr[result[u]]) {
+ if (u > 0) {
+ p2[i] = result[u - 1];
+ }
+ result[u] = i;
+ }
+ }
+ }
+ u = result.length;
+ v = result[u - 1];
+ while (u-- > 0) {
+ result[u] = v;
+ v = p2[v];
+ }
+ return result;
+}
+function locateNonHydratedAsyncRoot(instance) {
+ const subComponent = instance.subTree.component;
+ if (subComponent) {
+ if (subComponent.asyncDep && !subComponent.asyncResolved) {
+ return subComponent;
+ } else {
+ return locateNonHydratedAsyncRoot(subComponent);
+ }
+ }
+}
+function invalidateMount(hooks) {
+ if (hooks) {
+ for (let i = 0; i < hooks.length; i++)
+ hooks[i].flags |= 8;
+ }
+}
+const ssrContextKey$1 = Symbol.for("v-scx");
+const useSSRContext = () => {
+ {
+ const ctx2 = inject(ssrContextKey$1);
+ return ctx2;
+ }
+};
+function watchEffect(effect2, options) {
+ return doWatch(effect2, null, options);
+}
+function watch(source, cb, options) {
+ return doWatch(source, cb, options);
+}
+function doWatch(source, cb, options = EMPTY_OBJ) {
+ const { immediate, deep, flush, once } = options;
+ const baseWatchOptions = extend$1({}, options);
+ const runsImmediately = cb && immediate || !cb && flush !== "post";
+ let ssrCleanup;
+ if (isInSSRComponentSetup) {
+ if (flush === "sync") {
+ const ctx2 = useSSRContext();
+ ssrCleanup = ctx2.__watcherHandles || (ctx2.__watcherHandles = []);
+ } else if (!runsImmediately) {
+ const watchStopHandle = () => {
+ };
+ watchStopHandle.stop = NOOP;
+ watchStopHandle.resume = NOOP;
+ watchStopHandle.pause = NOOP;
+ return watchStopHandle;
+ }
+ }
+ const instance = currentInstance;
+ baseWatchOptions.call = (fn, type, args) => callWithAsyncErrorHandling(fn, instance, type, args);
+ let isPre = false;
+ if (flush === "post") {
+ baseWatchOptions.scheduler = (job) => {
+ queuePostRenderEffect(job, instance && instance.suspense);
+ };
+ } else if (flush !== "sync") {
+ isPre = true;
+ baseWatchOptions.scheduler = (job, isFirstRun) => {
+ if (isFirstRun) {
+ job();
+ } else {
+ queueJob(job);
+ }
+ };
+ }
+ baseWatchOptions.augmentJob = (job) => {
+ if (cb) {
+ job.flags |= 4;
+ }
+ if (isPre) {
+ job.flags |= 2;
+ if (instance) {
+ job.id = instance.uid;
+ job.i = instance;
+ }
+ }
+ };
+ const watchHandle = watch$1(source, cb, baseWatchOptions);
+ if (isInSSRComponentSetup) {
+ if (ssrCleanup) {
+ ssrCleanup.push(watchHandle);
+ } else if (runsImmediately) {
+ watchHandle();
+ }
+ }
+ return watchHandle;
+}
+function instanceWatch(source, value, options) {
+ const publicThis = this.proxy;
+ const getter = isString$1(source) ? source.includes(".") ? createPathGetter(publicThis, source) : () => publicThis[source] : source.bind(publicThis, publicThis);
+ let cb;
+ if (isFunction$2(value)) {
+ cb = value;
+ } else {
+ cb = value.handler;
+ options = value;
+ }
+ const reset = setCurrentInstance(this);
+ const res = doWatch(getter, cb.bind(publicThis), options);
+ reset();
+ return res;
+}
+function createPathGetter(ctx2, path) {
+ const segments = path.split(".");
+ return () => {
+ let cur = ctx2;
+ for (let i = 0; i < segments.length && cur; i++) {
+ cur = cur[segments[i]];
+ }
+ return cur;
+ };
+}
+const getModelModifiers = (props, modelName) => {
+ return modelName === "modelValue" || modelName === "model-value" ? props.modelModifiers : props[`${modelName}Modifiers`] || props[`${camelize(modelName)}Modifiers`] || props[`${hyphenate(modelName)}Modifiers`];
+};
+function emit(instance, event, ...rawArgs) {
+ if (instance.isUnmounted) return;
+ const props = instance.vnode.props || EMPTY_OBJ;
+ let args = rawArgs;
+ const isModelListener2 = event.startsWith("update:");
+ const modifiers = isModelListener2 && getModelModifiers(props, event.slice(7));
+ if (modifiers) {
+ if (modifiers.trim) {
+ args = rawArgs.map((a) => isString$1(a) ? a.trim() : a);
+ }
+ if (modifiers.number) {
+ args = rawArgs.map(looseToNumber);
+ }
+ }
+ let handlerName;
+ let handler = props[handlerName = toHandlerKey(event)] || // also try camelCase event handler (#2249)
+ props[handlerName = toHandlerKey(camelize(event))];
+ if (!handler && isModelListener2) {
+ handler = props[handlerName = toHandlerKey(hyphenate(event))];
+ }
+ if (handler) {
+ callWithAsyncErrorHandling(
+ handler,
+ instance,
+ 6,
+ args
+ );
+ }
+ const onceHandler = props[handlerName + `Once`];
+ if (onceHandler) {
+ if (!instance.emitted) {
+ instance.emitted = {};
+ } else if (instance.emitted[handlerName]) {
+ return;
+ }
+ instance.emitted[handlerName] = true;
+ callWithAsyncErrorHandling(
+ onceHandler,
+ instance,
+ 6,
+ args
+ );
+ }
+}
+function normalizeEmitsOptions(comp, appContext, asMixin = false) {
+ const cache2 = appContext.emitsCache;
+ const cached = cache2.get(comp);
+ if (cached !== void 0) {
+ return cached;
+ }
+ const raw = comp.emits;
+ let normalized = {};
+ let hasExtends = false;
+ if (!isFunction$2(comp)) {
+ const extendEmits = (raw2) => {
+ const normalizedFromExtend = normalizeEmitsOptions(raw2, appContext, true);
+ if (normalizedFromExtend) {
+ hasExtends = true;
+ extend$1(normalized, normalizedFromExtend);
+ }
+ };
+ if (!asMixin && appContext.mixins.length) {
+ appContext.mixins.forEach(extendEmits);
+ }
+ if (comp.extends) {
+ extendEmits(comp.extends);
+ }
+ if (comp.mixins) {
+ comp.mixins.forEach(extendEmits);
+ }
+ }
+ if (!raw && !hasExtends) {
+ if (isObject$4(comp)) {
+ cache2.set(comp, null);
+ }
+ return null;
+ }
+ if (isArray$3(raw)) {
+ raw.forEach((key) => normalized[key] = null);
+ } else {
+ extend$1(normalized, raw);
+ }
+ if (isObject$4(comp)) {
+ cache2.set(comp, normalized);
+ }
+ return normalized;
+}
+function isEmitListener(options, key) {
+ if (!options || !isOn(key)) {
+ return false;
+ }
+ key = key.slice(2).replace(/Once$/, "");
+ return hasOwn(options, key[0].toLowerCase() + key.slice(1)) || hasOwn(options, hyphenate(key)) || hasOwn(options, key);
+}
+function markAttrsAccessed() {
+}
+function renderComponentRoot(instance) {
+ const {
+ type: Component,
+ vnode: vnode2,
+ proxy,
+ withProxy,
+ propsOptions: [propsOptions],
+ slots,
+ attrs,
+ emit: emit2,
+ render: render2,
+ renderCache,
+ props,
+ data,
+ setupState,
+ ctx: ctx2,
+ inheritAttrs
+ } = instance;
+ const prev = setCurrentRenderingInstance(instance);
+ let result;
+ let fallthroughAttrs;
+ try {
+ if (vnode2.shapeFlag & 4) {
+ const proxyToUse = withProxy || proxy;
+ const thisProxy = false ? new Proxy(proxyToUse, {
+ get(target, key, receiver) {
+ warn$1$1(
+ `Property '${String(
+ key
+ )}' was accessed via 'this'. Avoid using 'this' in templates.`
+ );
+ return Reflect.get(target, key, receiver);
+ }
+ }) : proxyToUse;
+ result = normalizeVNode(
+ render2.call(
+ thisProxy,
+ proxyToUse,
+ renderCache,
+ false ? shallowReadonly(props) : props,
+ setupState,
+ data,
+ ctx2
+ )
+ );
+ fallthroughAttrs = attrs;
+ } else {
+ const render22 = Component;
+ if (false) ;
+ result = normalizeVNode(
+ render22.length > 1 ? render22(
+ false ? shallowReadonly(props) : props,
+ false ? {
+ get attrs() {
+ markAttrsAccessed();
+ return shallowReadonly(attrs);
+ },
+ slots,
+ emit: emit2
+ } : { attrs, slots, emit: emit2 }
+ ) : render22(
+ false ? shallowReadonly(props) : props,
+ null
+ )
+ );
+ fallthroughAttrs = Component.props ? attrs : getFunctionalFallthrough(attrs);
+ }
+ } catch (err) {
+ blockStack.length = 0;
+ handleError(err, instance, 1);
+ result = createVNode(Comment);
+ }
+ let root2 = result;
+ if (fallthroughAttrs && inheritAttrs !== false) {
+ const keys = Object.keys(fallthroughAttrs);
+ const { shapeFlag } = root2;
+ if (keys.length) {
+ if (shapeFlag & (1 | 6)) {
+ if (propsOptions && keys.some(isModelListener)) {
+ fallthroughAttrs = filterModelListeners(
+ fallthroughAttrs,
+ propsOptions
+ );
+ }
+ root2 = cloneVNode(root2, fallthroughAttrs, false, true);
+ }
+ }
+ }
+ if (vnode2.dirs) {
+ root2 = cloneVNode(root2, null, false, true);
+ root2.dirs = root2.dirs ? root2.dirs.concat(vnode2.dirs) : vnode2.dirs;
+ }
+ if (vnode2.transition) {
+ setTransitionHooks(root2, vnode2.transition);
+ }
+ {
+ result = root2;
+ }
+ setCurrentRenderingInstance(prev);
+ return result;
+}
+const getFunctionalFallthrough = (attrs) => {
+ let res;
+ for (const key in attrs) {
+ if (key === "class" || key === "style" || isOn(key)) {
+ (res || (res = {}))[key] = attrs[key];
+ }
+ }
+ return res;
+};
+const filterModelListeners = (attrs, props) => {
+ const res = {};
+ for (const key in attrs) {
+ if (!isModelListener(key) || !(key.slice(9) in props)) {
+ res[key] = attrs[key];
+ }
+ }
+ return res;
+};
+function shouldUpdateComponent(prevVNode, nextVNode, optimized) {
+ const { props: prevProps, children: prevChildren, component } = prevVNode;
+ const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;
+ const emits = component.emitsOptions;
+ if (nextVNode.dirs || nextVNode.transition) {
+ return true;
+ }
+ if (optimized && patchFlag >= 0) {
+ if (patchFlag & 1024) {
+ return true;
+ }
+ if (patchFlag & 16) {
+ if (!prevProps) {
+ return !!nextProps;
+ }
+ return hasPropsChanged(prevProps, nextProps, emits);
+ } else if (patchFlag & 8) {
+ const dynamicProps = nextVNode.dynamicProps;
+ for (let i = 0; i < dynamicProps.length; i++) {
+ const key = dynamicProps[i];
+ if (nextProps[key] !== prevProps[key] && !isEmitListener(emits, key)) {
+ return true;
+ }
+ }
+ }
+ } else {
+ if (prevChildren || nextChildren) {
+ if (!nextChildren || !nextChildren.$stable) {
+ return true;
+ }
+ }
+ if (prevProps === nextProps) {
+ return false;
+ }
+ if (!prevProps) {
+ return !!nextProps;
+ }
+ if (!nextProps) {
+ return true;
+ }
+ return hasPropsChanged(prevProps, nextProps, emits);
+ }
+ return false;
+}
+function hasPropsChanged(prevProps, nextProps, emitsOptions) {
+ const nextKeys = Object.keys(nextProps);
+ if (nextKeys.length !== Object.keys(prevProps).length) {
+ return true;
+ }
+ for (let i = 0; i < nextKeys.length; i++) {
+ const key = nextKeys[i];
+ if (nextProps[key] !== prevProps[key] && !isEmitListener(emitsOptions, key)) {
+ return true;
+ }
+ }
+ return false;
+}
+function updateHOCHostEl({ vnode: vnode2, parent }, el) {
+ while (parent) {
+ const root2 = parent.subTree;
+ if (root2.suspense && root2.suspense.activeBranch === vnode2) {
+ root2.el = vnode2.el;
+ }
+ if (root2 === vnode2) {
+ (vnode2 = parent.vnode).el = el;
+ parent = parent.parent;
+ } else {
+ break;
+ }
+ }
+}
+const isSuspense = (type) => type.__isSuspense;
+function queueEffectWithSuspense(fn, suspense) {
+ if (suspense && suspense.pendingBranch) {
+ if (isArray$3(fn)) {
+ suspense.effects.push(...fn);
+ } else {
+ suspense.effects.push(fn);
+ }
+ } else {
+ queuePostFlushCb(fn);
+ }
+}
+const Fragment = Symbol.for("v-fgt");
+const Text = Symbol.for("v-txt");
+const Comment = Symbol.for("v-cmt");
+const Static = Symbol.for("v-stc");
+const blockStack = [];
+let currentBlock = null;
+function openBlock(disableTracking = false) {
+ blockStack.push(currentBlock = disableTracking ? null : []);
+}
+function closeBlock() {
+ blockStack.pop();
+ currentBlock = blockStack[blockStack.length - 1] || null;
+}
+let isBlockTreeEnabled = 1;
+function setBlockTracking(value, inVOnce = false) {
+ isBlockTreeEnabled += value;
+ if (value < 0 && currentBlock && inVOnce) {
+ currentBlock.hasOnce = true;
+ }
+}
+function setupBlock(vnode2) {
+ vnode2.dynamicChildren = isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;
+ closeBlock();
+ if (isBlockTreeEnabled > 0 && currentBlock) {
+ currentBlock.push(vnode2);
+ }
+ return vnode2;
+}
+function createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {
+ return setupBlock(
+ createBaseVNode(
+ type,
+ props,
+ children,
+ patchFlag,
+ dynamicProps,
+ shapeFlag,
+ true
+ )
+ );
+}
+function createBlock(type, props, children, patchFlag, dynamicProps) {
+ return setupBlock(
+ createVNode(
+ type,
+ props,
+ children,
+ patchFlag,
+ dynamicProps,
+ true
+ )
+ );
+}
+function isVNode(value) {
+ return value ? value.__v_isVNode === true : false;
+}
+function isSameVNodeType(n1, n2) {
+ return n1.type === n2.type && n1.key === n2.key;
+}
+const normalizeKey = ({ key }) => key != null ? key : null;
+const normalizeRef = ({
+ ref: ref3,
+ ref_key,
+ ref_for
+}) => {
+ if (typeof ref3 === "number") {
+ ref3 = "" + ref3;
+ }
+ return ref3 != null ? isString$1(ref3) || isRef(ref3) || isFunction$2(ref3) ? { i: currentRenderingInstance, r: ref3, k: ref_key, f: !!ref_for } : ref3 : null;
+};
+function createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1, isBlockNode = false, needFullChildrenNormalization = false) {
+ const vnode2 = {
+ __v_isVNode: true,
+ __v_skip: true,
+ type,
+ props,
+ key: props && normalizeKey(props),
+ ref: props && normalizeRef(props),
+ scopeId: currentScopeId,
+ slotScopeIds: null,
+ children,
+ component: null,
+ suspense: null,
+ ssContent: null,
+ ssFallback: null,
+ dirs: null,
+ transition: null,
+ el: null,
+ anchor: null,
+ target: null,
+ targetStart: null,
+ targetAnchor: null,
+ staticCount: 0,
+ shapeFlag,
+ patchFlag,
+ dynamicProps,
+ dynamicChildren: null,
+ appContext: null,
+ ctx: currentRenderingInstance
+ };
+ if (needFullChildrenNormalization) {
+ normalizeChildren(vnode2, children);
+ if (shapeFlag & 128) {
+ type.normalize(vnode2);
+ }
+ } else if (children) {
+ vnode2.shapeFlag |= isString$1(children) ? 8 : 16;
+ }
+ if (isBlockTreeEnabled > 0 && // avoid a block node from tracking itself
+ !isBlockNode && // has current parent block
+ currentBlock && // presence of a patch flag indicates this node needs patching on updates.
+ // component nodes also should always be patched, because even if the
+ // component doesn't need to update, it needs to persist the instance on to
+ // the next vnode so that it can be properly unmounted later.
+ (vnode2.patchFlag > 0 || shapeFlag & 6) && // the EVENTS flag is only for hydration and if it is the only flag, the
+ // vnode should not be considered dynamic due to handler caching.
+ vnode2.patchFlag !== 32) {
+ currentBlock.push(vnode2);
+ }
+ return vnode2;
+}
+const createVNode = _createVNode;
+function _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {
+ if (!type || type === NULL_DYNAMIC_COMPONENT) {
+ type = Comment;
+ }
+ if (isVNode(type)) {
+ const cloned = cloneVNode(
+ type,
+ props,
+ true
+ /* mergeRef: true */
+ );
+ if (children) {
+ normalizeChildren(cloned, children);
+ }
+ if (isBlockTreeEnabled > 0 && !isBlockNode && currentBlock) {
+ if (cloned.shapeFlag & 6) {
+ currentBlock[currentBlock.indexOf(type)] = cloned;
+ } else {
+ currentBlock.push(cloned);
+ }
+ }
+ cloned.patchFlag = -2;
+ return cloned;
+ }
+ if (isClassComponent(type)) {
+ type = type.__vccOpts;
+ }
+ if (props) {
+ props = guardReactiveProps(props);
+ let { class: klass, style: style2 } = props;
+ if (klass && !isString$1(klass)) {
+ props.class = normalizeClass(klass);
+ }
+ if (isObject$4(style2)) {
+ if (isProxy(style2) && !isArray$3(style2)) {
+ style2 = extend$1({}, style2);
+ }
+ props.style = normalizeStyle(style2);
+ }
+ }
+ const shapeFlag = isString$1(type) ? 1 : isSuspense(type) ? 128 : isTeleport(type) ? 64 : isObject$4(type) ? 4 : isFunction$2(type) ? 2 : 0;
+ return createBaseVNode(
+ type,
+ props,
+ children,
+ patchFlag,
+ dynamicProps,
+ shapeFlag,
+ isBlockNode,
+ true
+ );
+}
+function guardReactiveProps(props) {
+ if (!props) return null;
+ return isProxy(props) || isInternalObject(props) ? extend$1({}, props) : props;
+}
+function cloneVNode(vnode2, extraProps, mergeRef = false, cloneTransition = false) {
+ const { props, ref: ref3, patchFlag, children, transition } = vnode2;
+ const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;
+ const cloned = {
+ __v_isVNode: true,
+ __v_skip: true,
+ type: vnode2.type,
+ props: mergedProps,
+ key: mergedProps && normalizeKey(mergedProps),
+ ref: extraProps && extraProps.ref ? (
+ // #2078 in the case of
+ // if the vnode itself already has a ref, cloneVNode will need to merge
+ // the refs so the single vnode can be set on multiple refs
+ mergeRef && ref3 ? isArray$3(ref3) ? ref3.concat(normalizeRef(extraProps)) : [ref3, normalizeRef(extraProps)] : normalizeRef(extraProps)
+ ) : ref3,
+ scopeId: vnode2.scopeId,
+ slotScopeIds: vnode2.slotScopeIds,
+ children,
+ target: vnode2.target,
+ targetStart: vnode2.targetStart,
+ targetAnchor: vnode2.targetAnchor,
+ staticCount: vnode2.staticCount,
+ shapeFlag: vnode2.shapeFlag,
+ // if the vnode is cloned with extra props, we can no longer assume its
+ // existing patch flag to be reliable and need to add the FULL_PROPS flag.
+ // note: preserve flag for fragments since they use the flag for children
+ // fast paths only.
+ patchFlag: extraProps && vnode2.type !== Fragment ? patchFlag === -1 ? 16 : patchFlag | 16 : patchFlag,
+ dynamicProps: vnode2.dynamicProps,
+ dynamicChildren: vnode2.dynamicChildren,
+ appContext: vnode2.appContext,
+ dirs: vnode2.dirs,
+ transition,
+ // These should technically only be non-null on mounted VNodes. However,
+ // they *should* be copied for kept-alive vnodes. So we just always copy
+ // them since them being non-null during a mount doesn't affect the logic as
+ // they will simply be overwritten.
+ component: vnode2.component,
+ suspense: vnode2.suspense,
+ ssContent: vnode2.ssContent && cloneVNode(vnode2.ssContent),
+ ssFallback: vnode2.ssFallback && cloneVNode(vnode2.ssFallback),
+ el: vnode2.el,
+ anchor: vnode2.anchor,
+ ctx: vnode2.ctx,
+ ce: vnode2.ce
+ };
+ if (transition && cloneTransition) {
+ setTransitionHooks(
+ cloned,
+ transition.clone(cloned)
+ );
+ }
+ return cloned;
+}
+function createTextVNode(text = " ", flag = 0) {
+ return createVNode(Text, null, text, flag);
+}
+function createCommentVNode(text = "", asBlock = false) {
+ return asBlock ? (openBlock(), createBlock(Comment, null, text)) : createVNode(Comment, null, text);
+}
+function normalizeVNode(child) {
+ if (child == null || typeof child === "boolean") {
+ return createVNode(Comment);
+ } else if (isArray$3(child)) {
+ return createVNode(
+ Fragment,
+ null,
+ // #3666, avoid reference pollution when reusing vnode
+ child.slice()
+ );
+ } else if (isVNode(child)) {
+ return cloneIfMounted(child);
+ } else {
+ return createVNode(Text, null, String(child));
+ }
+}
+function cloneIfMounted(child) {
+ return child.el === null && child.patchFlag !== -1 || child.memo ? child : cloneVNode(child);
+}
+function normalizeChildren(vnode2, children) {
+ let type = 0;
+ const { shapeFlag } = vnode2;
+ if (children == null) {
+ children = null;
+ } else if (isArray$3(children)) {
+ type = 16;
+ } else if (typeof children === "object") {
+ if (shapeFlag & (1 | 64)) {
+ const slot = children.default;
+ if (slot) {
+ slot._c && (slot._d = false);
+ normalizeChildren(vnode2, slot());
+ slot._c && (slot._d = true);
+ }
+ return;
+ } else {
+ type = 32;
+ const slotFlag = children._;
+ if (!slotFlag && !isInternalObject(children)) {
+ children._ctx = currentRenderingInstance;
+ } else if (slotFlag === 3 && currentRenderingInstance) {
+ if (currentRenderingInstance.slots._ === 1) {
+ children._ = 1;
+ } else {
+ children._ = 2;
+ vnode2.patchFlag |= 1024;
+ }
+ }
+ }
+ } else if (isFunction$2(children)) {
+ children = { default: children, _ctx: currentRenderingInstance };
+ type = 32;
+ } else {
+ children = String(children);
+ if (shapeFlag & 64) {
+ type = 16;
+ children = [createTextVNode(children)];
+ } else {
+ type = 8;
+ }
+ }
+ vnode2.children = children;
+ vnode2.shapeFlag |= type;
+}
+function mergeProps(...args) {
+ const ret = {};
+ for (let i = 0; i < args.length; i++) {
+ const toMerge = args[i];
+ for (const key in toMerge) {
+ if (key === "class") {
+ if (ret.class !== toMerge.class) {
+ ret.class = normalizeClass([ret.class, toMerge.class]);
+ }
+ } else if (key === "style") {
+ ret.style = normalizeStyle([ret.style, toMerge.style]);
+ } else if (isOn(key)) {
+ const existing = ret[key];
+ const incoming = toMerge[key];
+ if (incoming && existing !== incoming && !(isArray$3(existing) && existing.includes(incoming))) {
+ ret[key] = existing ? [].concat(existing, incoming) : incoming;
+ }
+ } else if (key !== "") {
+ ret[key] = toMerge[key];
+ }
+ }
+ }
+ return ret;
+}
+function invokeVNodeHook(hook, instance, vnode2, prevVNode = null) {
+ callWithAsyncErrorHandling(hook, instance, 7, [
+ vnode2,
+ prevVNode
+ ]);
+}
+const emptyAppContext = createAppContext();
+let uid = 0;
+function createComponentInstance(vnode2, parent, suspense) {
+ const type = vnode2.type;
+ const appContext = (parent ? parent.appContext : vnode2.appContext) || emptyAppContext;
+ const instance = {
+ uid: uid++,
+ vnode: vnode2,
+ type,
+ parent,
+ appContext,
+ root: null,
+ // to be immediately set
+ next: null,
+ subTree: null,
+ // will be set synchronously right after creation
+ effect: null,
+ update: null,
+ // will be set synchronously right after creation
+ job: null,
+ scope: new EffectScope(
+ true
+ /* detached */
+ ),
+ render: null,
+ proxy: null,
+ exposed: null,
+ exposeProxy: null,
+ withProxy: null,
+ provides: parent ? parent.provides : Object.create(appContext.provides),
+ ids: parent ? parent.ids : ["", 0, 0],
+ accessCache: null,
+ renderCache: [],
+ // local resolved assets
+ components: null,
+ directives: null,
+ // resolved props and emits options
+ propsOptions: normalizePropsOptions(type, appContext),
+ emitsOptions: normalizeEmitsOptions(type, appContext),
+ // emit
+ emit: null,
+ // to be set immediately
+ emitted: null,
+ // props default value
+ propsDefaults: EMPTY_OBJ,
+ // inheritAttrs
+ inheritAttrs: type.inheritAttrs,
+ // state
+ ctx: EMPTY_OBJ,
+ data: EMPTY_OBJ,
+ props: EMPTY_OBJ,
+ attrs: EMPTY_OBJ,
+ slots: EMPTY_OBJ,
+ refs: EMPTY_OBJ,
+ setupState: EMPTY_OBJ,
+ setupContext: null,
+ // suspense related
+ suspense,
+ suspenseId: suspense ? suspense.pendingId : 0,
+ asyncDep: null,
+ asyncResolved: false,
+ // lifecycle hooks
+ // not using enums here because it results in computed properties
+ isMounted: false,
+ isUnmounted: false,
+ isDeactivated: false,
+ bc: null,
+ c: null,
+ bm: null,
+ m: null,
+ bu: null,
+ u: null,
+ um: null,
+ bum: null,
+ da: null,
+ a: null,
+ rtg: null,
+ rtc: null,
+ ec: null,
+ sp: null
+ };
+ {
+ instance.ctx = { _: instance };
+ }
+ instance.root = parent ? parent.root : instance;
+ instance.emit = emit.bind(null, instance);
+ if (vnode2.ce) {
+ vnode2.ce(instance);
+ }
+ return instance;
+}
+let currentInstance = null;
+const getCurrentInstance = () => currentInstance || currentRenderingInstance;
+let internalSetCurrentInstance;
+let setInSSRSetupState;
+{
+ const g = getGlobalThis();
+ const registerGlobalSetter = (key, setter) => {
+ let setters;
+ if (!(setters = g[key])) setters = g[key] = [];
+ setters.push(setter);
+ return (v) => {
+ if (setters.length > 1) setters.forEach((set) => set(v));
+ else setters[0](v);
+ };
+ };
+ internalSetCurrentInstance = registerGlobalSetter(
+ `__VUE_INSTANCE_SETTERS__`,
+ (v) => currentInstance = v
+ );
+ setInSSRSetupState = registerGlobalSetter(
+ `__VUE_SSR_SETTERS__`,
+ (v) => isInSSRComponentSetup = v
+ );
+}
+const setCurrentInstance = (instance) => {
+ const prev = currentInstance;
+ internalSetCurrentInstance(instance);
+ instance.scope.on();
+ return () => {
+ instance.scope.off();
+ internalSetCurrentInstance(prev);
+ };
+};
+const unsetCurrentInstance = () => {
+ currentInstance && currentInstance.scope.off();
+ internalSetCurrentInstance(null);
+};
+function isStatefulComponent(instance) {
+ return instance.vnode.shapeFlag & 4;
+}
+let isInSSRComponentSetup = false;
+function setupComponent(instance, isSSR = false, optimized = false) {
+ isSSR && setInSSRSetupState(isSSR);
+ const { props, children } = instance.vnode;
+ const isStateful = isStatefulComponent(instance);
+ initProps(instance, props, isStateful, isSSR);
+ initSlots(instance, children, optimized);
+ const setupResult = isStateful ? setupStatefulComponent(instance, isSSR) : void 0;
+ isSSR && setInSSRSetupState(false);
+ return setupResult;
+}
+function setupStatefulComponent(instance, isSSR) {
+ const Component = instance.type;
+ instance.accessCache = /* @__PURE__ */ Object.create(null);
+ instance.proxy = new Proxy(instance.ctx, PublicInstanceProxyHandlers);
+ const { setup } = Component;
+ if (setup) {
+ pauseTracking();
+ const setupContext = instance.setupContext = setup.length > 1 ? createSetupContext(instance) : null;
+ const reset = setCurrentInstance(instance);
+ const setupResult = callWithErrorHandling(
+ setup,
+ instance,
+ 0,
+ [
+ instance.props,
+ setupContext
+ ]
+ );
+ const isAsyncSetup = isPromise$1(setupResult);
+ resetTracking();
+ reset();
+ if ((isAsyncSetup || instance.sp) && !isAsyncWrapper(instance)) {
+ markAsyncBoundary(instance);
+ }
+ if (isAsyncSetup) {
+ setupResult.then(unsetCurrentInstance, unsetCurrentInstance);
+ if (isSSR) {
+ return setupResult.then((resolvedResult) => {
+ handleSetupResult(instance, resolvedResult);
+ }).catch((e) => {
+ handleError(e, instance, 0);
+ });
+ } else {
+ instance.asyncDep = setupResult;
+ }
+ } else {
+ handleSetupResult(instance, setupResult);
+ }
+ } else {
+ finishComponentSetup(instance);
+ }
+}
+function handleSetupResult(instance, setupResult, isSSR) {
+ if (isFunction$2(setupResult)) {
+ if (instance.type.__ssrInlineRender) {
+ instance.ssrRender = setupResult;
+ } else {
+ instance.render = setupResult;
+ }
+ } else if (isObject$4(setupResult)) {
+ instance.setupState = proxyRefs(setupResult);
+ } else ;
+ finishComponentSetup(instance);
+}
+function finishComponentSetup(instance, isSSR, skipOptions) {
+ const Component = instance.type;
+ if (!instance.render) {
+ instance.render = Component.render || NOOP;
+ }
+ {
+ const reset = setCurrentInstance(instance);
+ pauseTracking();
+ try {
+ applyOptions(instance);
+ } finally {
+ resetTracking();
+ reset();
+ }
+ }
+}
+const attrsProxyHandlers = {
+ get(target, key) {
+ track(target, "get", "");
+ return target[key];
+ }
+};
+function createSetupContext(instance) {
+ const expose = (exposed) => {
+ instance.exposed = exposed || {};
+ };
+ {
+ return {
+ attrs: new Proxy(instance.attrs, attrsProxyHandlers),
+ slots: instance.slots,
+ emit: instance.emit,
+ expose
+ };
+ }
+}
+function getComponentPublicInstance(instance) {
+ if (instance.exposed) {
+ return instance.exposeProxy || (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {
+ get(target, key) {
+ if (key in target) {
+ return target[key];
+ } else if (key in publicPropertiesMap) {
+ return publicPropertiesMap[key](instance);
+ }
+ },
+ has(target, key) {
+ return key in target || key in publicPropertiesMap;
+ }
+ }));
+ } else {
+ return instance.proxy;
+ }
+}
+const classifyRE = /(?:^|[-_])(\w)/g;
+const classify = (str) => str.replace(classifyRE, (c2) => c2.toUpperCase()).replace(/[-_]/g, "");
+function getComponentName(Component, includeInferred = true) {
+ return isFunction$2(Component) ? Component.displayName || Component.name : Component.name || includeInferred && Component.__name;
+}
+function formatComponentName(instance, Component, isRoot = false) {
+ let name2 = getComponentName(Component);
+ if (!name2 && Component.__file) {
+ const match = Component.__file.match(/([^/\\]+)\.\w+$/);
+ if (match) {
+ name2 = match[1];
+ }
+ }
+ if (!name2 && instance && instance.parent) {
+ const inferFromRegistry = (registry) => {
+ for (const key in registry) {
+ if (registry[key] === Component) {
+ return key;
+ }
+ }
+ };
+ name2 = inferFromRegistry(
+ instance.components || instance.parent.type.components
+ ) || inferFromRegistry(instance.appContext.components);
+ }
+ return name2 ? classify(name2) : isRoot ? `App` : `Anonymous`;
+}
+function isClassComponent(value) {
+ return isFunction$2(value) && "__vccOpts" in value;
+}
+const computed = (getterOrOptions, debugOptions) => {
+ const c2 = computed$1(getterOrOptions, debugOptions, isInSSRComponentSetup);
+ return c2;
+};
+function h(type, propsOrChildren, children) {
+ const l = arguments.length;
+ if (l === 2) {
+ if (isObject$4(propsOrChildren) && !isArray$3(propsOrChildren)) {
+ if (isVNode(propsOrChildren)) {
+ return createVNode(type, null, [propsOrChildren]);
+ }
+ return createVNode(type, propsOrChildren);
+ } else {
+ return createVNode(type, null, propsOrChildren);
+ }
+ } else {
+ if (l > 3) {
+ children = Array.prototype.slice.call(arguments, 2);
+ } else if (l === 3 && isVNode(children)) {
+ children = [children];
+ }
+ return createVNode(type, propsOrChildren, children);
+ }
+}
+const version$1 = "3.5.13";
+/**
+* @vue/runtime-dom v3.5.13
+* (c) 2018-present Yuxi (Evan) You and Vue contributors
+* @license MIT
+**/
+let policy = void 0;
+const tt = typeof window !== "undefined" && window.trustedTypes;
+if (tt) {
+ try {
+ policy = /* @__PURE__ */ tt.createPolicy("vue", {
+ createHTML: (val) => val
+ });
+ } catch (e) {
+ }
+}
+const unsafeToTrustedHTML = policy ? (val) => policy.createHTML(val) : (val) => val;
+const svgNS = "http://www.w3.org/2000/svg";
+const mathmlNS = "http://www.w3.org/1998/Math/MathML";
+const doc = typeof document !== "undefined" ? document : null;
+const templateContainer = doc && /* @__PURE__ */ doc.createElement("template");
+const nodeOps = {
+ insert: (child, parent, anchor) => {
+ parent.insertBefore(child, anchor || null);
+ },
+ remove: (child) => {
+ const parent = child.parentNode;
+ if (parent) {
+ parent.removeChild(child);
+ }
+ },
+ createElement: (tag2, namespace2, is, props) => {
+ const el = namespace2 === "svg" ? doc.createElementNS(svgNS, tag2) : namespace2 === "mathml" ? doc.createElementNS(mathmlNS, tag2) : is ? doc.createElement(tag2, { is }) : doc.createElement(tag2);
+ if (tag2 === "select" && props && props.multiple != null) {
+ el.setAttribute("multiple", props.multiple);
+ }
+ return el;
+ },
+ createText: (text) => doc.createTextNode(text),
+ createComment: (text) => doc.createComment(text),
+ setText: (node, text) => {
+ node.nodeValue = text;
+ },
+ setElementText: (el, text) => {
+ el.textContent = text;
+ },
+ parentNode: (node) => node.parentNode,
+ nextSibling: (node) => node.nextSibling,
+ querySelector: (selector) => doc.querySelector(selector),
+ setScopeId(el, id) {
+ el.setAttribute(id, "");
+ },
+ // __UNSAFE__
+ // Reason: innerHTML.
+ // Static content here can only come from compiled templates.
+ // As long as the user only uses trusted templates, this is safe.
+ insertStaticContent(content, parent, anchor, namespace2, start, end) {
+ const before = anchor ? anchor.previousSibling : parent.lastChild;
+ if (start && (start === end || start.nextSibling)) {
+ while (true) {
+ parent.insertBefore(start.cloneNode(true), anchor);
+ if (start === end || !(start = start.nextSibling)) break;
+ }
+ } else {
+ templateContainer.innerHTML = unsafeToTrustedHTML(
+ namespace2 === "svg" ? `` : namespace2 === "mathml" ? `` : content
+ );
+ const template = templateContainer.content;
+ if (namespace2 === "svg" || namespace2 === "mathml") {
+ const wrapper = template.firstChild;
+ while (wrapper.firstChild) {
+ template.appendChild(wrapper.firstChild);
+ }
+ template.removeChild(wrapper);
+ }
+ parent.insertBefore(template, anchor);
+ }
+ return [
+ // first
+ before ? before.nextSibling : parent.firstChild,
+ // last
+ anchor ? anchor.previousSibling : parent.lastChild
+ ];
+ }
+};
+const TRANSITION = "transition";
+const ANIMATION = "animation";
+const vtcKey = Symbol("_vtc");
+const DOMTransitionPropsValidators = {
+ name: String,
+ type: String,
+ css: {
+ type: Boolean,
+ default: true
+ },
+ duration: [String, Number, Object],
+ enterFromClass: String,
+ enterActiveClass: String,
+ enterToClass: String,
+ appearFromClass: String,
+ appearActiveClass: String,
+ appearToClass: String,
+ leaveFromClass: String,
+ leaveActiveClass: String,
+ leaveToClass: String
+};
+const TransitionPropsValidators = /* @__PURE__ */ extend$1(
+ {},
+ BaseTransitionPropsValidators,
+ DOMTransitionPropsValidators
+);
+const decorate$1 = (t) => {
+ t.displayName = "Transition";
+ t.props = TransitionPropsValidators;
+ return t;
+};
+const Transition = /* @__PURE__ */ decorate$1(
+ (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots)
+);
+const callHook = (hook, args = []) => {
+ if (isArray$3(hook)) {
+ hook.forEach((h2) => h2(...args));
+ } else if (hook) {
+ hook(...args);
+ }
+};
+const hasExplicitCallback = (hook) => {
+ return hook ? isArray$3(hook) ? hook.some((h2) => h2.length > 1) : hook.length > 1 : false;
+};
+function resolveTransitionProps(rawProps) {
+ const baseProps = {};
+ for (const key in rawProps) {
+ if (!(key in DOMTransitionPropsValidators)) {
+ baseProps[key] = rawProps[key];
+ }
+ }
+ if (rawProps.css === false) {
+ return baseProps;
+ }
+ const {
+ name: name2 = "v",
+ type,
+ duration: duration2,
+ enterFromClass = `${name2}-enter-from`,
+ enterActiveClass = `${name2}-enter-active`,
+ enterToClass = `${name2}-enter-to`,
+ appearFromClass = enterFromClass,
+ appearActiveClass = enterActiveClass,
+ appearToClass = enterToClass,
+ leaveFromClass = `${name2}-leave-from`,
+ leaveActiveClass = `${name2}-leave-active`,
+ leaveToClass = `${name2}-leave-to`
+ } = rawProps;
+ const durations = normalizeDuration(duration2);
+ const enterDuration = durations && durations[0];
+ const leaveDuration = durations && durations[1];
+ const {
+ onBeforeEnter,
+ onEnter,
+ onEnterCancelled,
+ onLeave,
+ onLeaveCancelled,
+ onBeforeAppear = onBeforeEnter,
+ onAppear = onEnter,
+ onAppearCancelled = onEnterCancelled
+ } = baseProps;
+ const finishEnter = (el, isAppear, done, isCancelled) => {
+ el._enterCancelled = isCancelled;
+ removeTransitionClass(el, isAppear ? appearToClass : enterToClass);
+ removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);
+ done && done();
+ };
+ const finishLeave = (el, done) => {
+ el._isLeaving = false;
+ removeTransitionClass(el, leaveFromClass);
+ removeTransitionClass(el, leaveToClass);
+ removeTransitionClass(el, leaveActiveClass);
+ done && done();
+ };
+ const makeEnterHook = (isAppear) => {
+ return (el, done) => {
+ const hook = isAppear ? onAppear : onEnter;
+ const resolve2 = () => finishEnter(el, isAppear, done);
+ callHook(hook, [el, resolve2]);
+ nextFrame(() => {
+ removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);
+ addTransitionClass(el, isAppear ? appearToClass : enterToClass);
+ if (!hasExplicitCallback(hook)) {
+ whenTransitionEnds(el, type, enterDuration, resolve2);
+ }
+ });
+ };
+ };
+ return extend$1(baseProps, {
+ onBeforeEnter(el) {
+ callHook(onBeforeEnter, [el]);
+ addTransitionClass(el, enterFromClass);
+ addTransitionClass(el, enterActiveClass);
+ },
+ onBeforeAppear(el) {
+ callHook(onBeforeAppear, [el]);
+ addTransitionClass(el, appearFromClass);
+ addTransitionClass(el, appearActiveClass);
+ },
+ onEnter: makeEnterHook(false),
+ onAppear: makeEnterHook(true),
+ onLeave(el, done) {
+ el._isLeaving = true;
+ const resolve2 = () => finishLeave(el, done);
+ addTransitionClass(el, leaveFromClass);
+ if (!el._enterCancelled) {
+ forceReflow();
+ addTransitionClass(el, leaveActiveClass);
+ } else {
+ addTransitionClass(el, leaveActiveClass);
+ forceReflow();
+ }
+ nextFrame(() => {
+ if (!el._isLeaving) {
+ return;
+ }
+ removeTransitionClass(el, leaveFromClass);
+ addTransitionClass(el, leaveToClass);
+ if (!hasExplicitCallback(onLeave)) {
+ whenTransitionEnds(el, type, leaveDuration, resolve2);
+ }
+ });
+ callHook(onLeave, [el, resolve2]);
+ },
+ onEnterCancelled(el) {
+ finishEnter(el, false, void 0, true);
+ callHook(onEnterCancelled, [el]);
+ },
+ onAppearCancelled(el) {
+ finishEnter(el, true, void 0, true);
+ callHook(onAppearCancelled, [el]);
+ },
+ onLeaveCancelled(el) {
+ finishLeave(el);
+ callHook(onLeaveCancelled, [el]);
+ }
+ });
+}
+function normalizeDuration(duration2) {
+ if (duration2 == null) {
+ return null;
+ } else if (isObject$4(duration2)) {
+ return [NumberOf(duration2.enter), NumberOf(duration2.leave)];
+ } else {
+ const n = NumberOf(duration2);
+ return [n, n];
+ }
+}
+function NumberOf(val) {
+ const res = toNumber(val);
+ return res;
+}
+function addTransitionClass(el, cls) {
+ cls.split(/\s+/).forEach((c2) => c2 && el.classList.add(c2));
+ (el[vtcKey] || (el[vtcKey] = /* @__PURE__ */ new Set())).add(cls);
+}
+function removeTransitionClass(el, cls) {
+ cls.split(/\s+/).forEach((c2) => c2 && el.classList.remove(c2));
+ const _vtc = el[vtcKey];
+ if (_vtc) {
+ _vtc.delete(cls);
+ if (!_vtc.size) {
+ el[vtcKey] = void 0;
+ }
+ }
+}
+function nextFrame(cb) {
+ requestAnimationFrame(() => {
+ requestAnimationFrame(cb);
+ });
+}
+let endId = 0;
+function whenTransitionEnds(el, expectedType, explicitTimeout, resolve2) {
+ const id = el._endId = ++endId;
+ const resolveIfNotStale = () => {
+ if (id === el._endId) {
+ resolve2();
+ }
+ };
+ if (explicitTimeout != null) {
+ return setTimeout(resolveIfNotStale, explicitTimeout);
+ }
+ const { type, timeout, propCount } = getTransitionInfo(el, expectedType);
+ if (!type) {
+ return resolve2();
+ }
+ const endEvent = type + "end";
+ let ended = 0;
+ const end = () => {
+ el.removeEventListener(endEvent, onEnd);
+ resolveIfNotStale();
+ };
+ const onEnd = (e) => {
+ if (e.target === el && ++ended >= propCount) {
+ end();
+ }
+ };
+ setTimeout(() => {
+ if (ended < propCount) {
+ end();
+ }
+ }, timeout + 1);
+ el.addEventListener(endEvent, onEnd);
+}
+function getTransitionInfo(el, expectedType) {
+ const styles = window.getComputedStyle(el);
+ const getStyleProperties = (key) => (styles[key] || "").split(", ");
+ const transitionDelays = getStyleProperties(`${TRANSITION}Delay`);
+ const transitionDurations = getStyleProperties(`${TRANSITION}Duration`);
+ const transitionTimeout = getTimeout(transitionDelays, transitionDurations);
+ const animationDelays = getStyleProperties(`${ANIMATION}Delay`);
+ const animationDurations = getStyleProperties(`${ANIMATION}Duration`);
+ const animationTimeout = getTimeout(animationDelays, animationDurations);
+ let type = null;
+ let timeout = 0;
+ let propCount = 0;
+ if (expectedType === TRANSITION) {
+ if (transitionTimeout > 0) {
+ type = TRANSITION;
+ timeout = transitionTimeout;
+ propCount = transitionDurations.length;
+ }
+ } else if (expectedType === ANIMATION) {
+ if (animationTimeout > 0) {
+ type = ANIMATION;
+ timeout = animationTimeout;
+ propCount = animationDurations.length;
+ }
+ } else {
+ timeout = Math.max(transitionTimeout, animationTimeout);
+ type = timeout > 0 ? transitionTimeout > animationTimeout ? TRANSITION : ANIMATION : null;
+ propCount = type ? type === TRANSITION ? transitionDurations.length : animationDurations.length : 0;
+ }
+ const hasTransform = type === TRANSITION && /\b(transform|all)(,|$)/.test(
+ getStyleProperties(`${TRANSITION}Property`).toString()
+ );
+ return {
+ type,
+ timeout,
+ propCount,
+ hasTransform
+ };
+}
+function getTimeout(delays, durations) {
+ while (delays.length < durations.length) {
+ delays = delays.concat(delays);
+ }
+ return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));
+}
+function toMs(s) {
+ if (s === "auto") return 0;
+ return Number(s.slice(0, -1).replace(",", ".")) * 1e3;
+}
+function forceReflow() {
+ return document.body.offsetHeight;
+}
+function patchClass(el, value, isSVG2) {
+ const transitionClasses = el[vtcKey];
+ if (transitionClasses) {
+ value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(" ");
+ }
+ if (value == null) {
+ el.removeAttribute("class");
+ } else if (isSVG2) {
+ el.setAttribute("class", value);
+ } else {
+ el.className = value;
+ }
+}
+const vShowOriginalDisplay = Symbol("_vod");
+const vShowHidden = Symbol("_vsh");
+const vShow = {
+ beforeMount(el, { value }, { transition }) {
+ el[vShowOriginalDisplay] = el.style.display === "none" ? "" : el.style.display;
+ if (transition && value) {
+ transition.beforeEnter(el);
+ } else {
+ setDisplay(el, value);
+ }
+ },
+ mounted(el, { value }, { transition }) {
+ if (transition && value) {
+ transition.enter(el);
+ }
+ },
+ updated(el, { value, oldValue }, { transition }) {
+ if (!value === !oldValue) return;
+ if (transition) {
+ if (value) {
+ transition.beforeEnter(el);
+ setDisplay(el, true);
+ transition.enter(el);
+ } else {
+ transition.leave(el, () => {
+ setDisplay(el, false);
+ });
+ }
+ } else {
+ setDisplay(el, value);
+ }
+ },
+ beforeUnmount(el, { value }) {
+ setDisplay(el, value);
+ }
+};
+function setDisplay(el, value) {
+ el.style.display = value ? el[vShowOriginalDisplay] : "none";
+ el[vShowHidden] = !value;
+}
+const CSS_VAR_TEXT = Symbol("");
+const displayRE = /(^|;)\s*display\s*:/;
+function patchStyle(el, prev, next) {
+ const style2 = el.style;
+ const isCssString = isString$1(next);
+ let hasControlledDisplay = false;
+ if (next && !isCssString) {
+ if (prev) {
+ if (!isString$1(prev)) {
+ for (const key in prev) {
+ if (next[key] == null) {
+ setStyle(style2, key, "");
+ }
+ }
+ } else {
+ for (const prevStyle of prev.split(";")) {
+ const key = prevStyle.slice(0, prevStyle.indexOf(":")).trim();
+ if (next[key] == null) {
+ setStyle(style2, key, "");
+ }
+ }
+ }
+ }
+ for (const key in next) {
+ if (key === "display") {
+ hasControlledDisplay = true;
+ }
+ setStyle(style2, key, next[key]);
+ }
+ } else {
+ if (isCssString) {
+ if (prev !== next) {
+ const cssVarText = style2[CSS_VAR_TEXT];
+ if (cssVarText) {
+ next += ";" + cssVarText;
+ }
+ style2.cssText = next;
+ hasControlledDisplay = displayRE.test(next);
+ }
+ } else if (prev) {
+ el.removeAttribute("style");
+ }
+ }
+ if (vShowOriginalDisplay in el) {
+ el[vShowOriginalDisplay] = hasControlledDisplay ? style2.display : "";
+ if (el[vShowHidden]) {
+ style2.display = "none";
+ }
+ }
+}
+const importantRE = /\s*!important$/;
+function setStyle(style2, name2, val) {
+ if (isArray$3(val)) {
+ val.forEach((v) => setStyle(style2, name2, v));
+ } else {
+ if (val == null) val = "";
+ if (name2.startsWith("--")) {
+ style2.setProperty(name2, val);
+ } else {
+ const prefixed = autoPrefix(style2, name2);
+ if (importantRE.test(val)) {
+ style2.setProperty(
+ hyphenate(prefixed),
+ val.replace(importantRE, ""),
+ "important"
+ );
+ } else {
+ style2[prefixed] = val;
+ }
+ }
+ }
+}
+const prefixes = ["Webkit", "Moz", "ms"];
+const prefixCache = {};
+function autoPrefix(style2, rawName) {
+ const cached = prefixCache[rawName];
+ if (cached) {
+ return cached;
+ }
+ let name2 = camelize(rawName);
+ if (name2 !== "filter" && name2 in style2) {
+ return prefixCache[rawName] = name2;
+ }
+ name2 = capitalize(name2);
+ for (let i = 0; i < prefixes.length; i++) {
+ const prefixed = prefixes[i] + name2;
+ if (prefixed in style2) {
+ return prefixCache[rawName] = prefixed;
+ }
+ }
+ return rawName;
+}
+const xlinkNS = "http://www.w3.org/1999/xlink";
+function patchAttr(el, key, value, isSVG2, instance, isBoolean2 = isSpecialBooleanAttr(key)) {
+ if (isSVG2 && key.startsWith("xlink:")) {
+ if (value == null) {
+ el.removeAttributeNS(xlinkNS, key.slice(6, key.length));
+ } else {
+ el.setAttributeNS(xlinkNS, key, value);
+ }
+ } else {
+ if (value == null || isBoolean2 && !includeBooleanAttr(value)) {
+ el.removeAttribute(key);
+ } else {
+ el.setAttribute(
+ key,
+ isBoolean2 ? "" : isSymbol$1(value) ? String(value) : value
+ );
+ }
+ }
+}
+function patchDOMProp(el, key, value, parentComponent, attrName) {
+ if (key === "innerHTML" || key === "textContent") {
+ if (value != null) {
+ el[key] = key === "innerHTML" ? unsafeToTrustedHTML(value) : value;
+ }
+ return;
+ }
+ const tag2 = el.tagName;
+ if (key === "value" && tag2 !== "PROGRESS" && // custom elements may use _value internally
+ !tag2.includes("-")) {
+ const oldValue = tag2 === "OPTION" ? el.getAttribute("value") || "" : el.value;
+ const newValue = value == null ? (
+ // #11647: value should be set as empty string for null and undefined,
+ // but should be set as 'on'.
+ el.type === "checkbox" ? "on" : ""
+ ) : String(value);
+ if (oldValue !== newValue || !("_value" in el)) {
+ el.value = newValue;
+ }
+ if (value == null) {
+ el.removeAttribute(key);
+ }
+ el._value = value;
+ return;
+ }
+ let needRemove = false;
+ if (value === "" || value == null) {
+ const type = typeof el[key];
+ if (type === "boolean") {
+ value = includeBooleanAttr(value);
+ } else if (value == null && type === "string") {
+ value = "";
+ needRemove = true;
+ } else if (type === "number") {
+ value = 0;
+ needRemove = true;
+ }
+ }
+ try {
+ el[key] = value;
+ } catch (e) {
+ }
+ needRemove && el.removeAttribute(attrName || key);
+}
+function addEventListener(el, event, handler, options) {
+ el.addEventListener(event, handler, options);
+}
+function removeEventListener(el, event, handler, options) {
+ el.removeEventListener(event, handler, options);
+}
+const veiKey = Symbol("_vei");
+function patchEvent(el, rawName, prevValue, nextValue, instance = null) {
+ const invokers = el[veiKey] || (el[veiKey] = {});
+ const existingInvoker = invokers[rawName];
+ if (nextValue && existingInvoker) {
+ existingInvoker.value = nextValue;
+ } else {
+ const [name2, options] = parseName(rawName);
+ if (nextValue) {
+ const invoker = invokers[rawName] = createInvoker(
+ nextValue,
+ instance
+ );
+ addEventListener(el, name2, invoker, options);
+ } else if (existingInvoker) {
+ removeEventListener(el, name2, existingInvoker, options);
+ invokers[rawName] = void 0;
+ }
+ }
+}
+const optionsModifierRE = /(?:Once|Passive|Capture)$/;
+function parseName(name2) {
+ let options;
+ if (optionsModifierRE.test(name2)) {
+ options = {};
+ let m;
+ while (m = name2.match(optionsModifierRE)) {
+ name2 = name2.slice(0, name2.length - m[0].length);
+ options[m[0].toLowerCase()] = true;
+ }
+ }
+ const event = name2[2] === ":" ? name2.slice(3) : hyphenate(name2.slice(2));
+ return [event, options];
+}
+let cachedNow = 0;
+const p = /* @__PURE__ */ Promise.resolve();
+const getNow = () => cachedNow || (p.then(() => cachedNow = 0), cachedNow = Date.now());
+function createInvoker(initialValue, instance) {
+ const invoker = (e) => {
+ if (!e._vts) {
+ e._vts = Date.now();
+ } else if (e._vts <= invoker.attached) {
+ return;
+ }
+ callWithAsyncErrorHandling(
+ patchStopImmediatePropagation(e, invoker.value),
+ instance,
+ 5,
+ [e]
+ );
+ };
+ invoker.value = initialValue;
+ invoker.attached = getNow();
+ return invoker;
+}
+function patchStopImmediatePropagation(e, value) {
+ if (isArray$3(value)) {
+ const originalStop = e.stopImmediatePropagation;
+ e.stopImmediatePropagation = () => {
+ originalStop.call(e);
+ e._stopped = true;
+ };
+ return value.map(
+ (fn) => (e2) => !e2._stopped && fn && fn(e2)
+ );
+ } else {
+ return value;
+ }
+}
+const isNativeOn = (key) => key.charCodeAt(0) === 111 && key.charCodeAt(1) === 110 && // lowercase letter
+key.charCodeAt(2) > 96 && key.charCodeAt(2) < 123;
+const patchProp = (el, key, prevValue, nextValue, namespace2, parentComponent) => {
+ const isSVG2 = namespace2 === "svg";
+ if (key === "class") {
+ patchClass(el, nextValue, isSVG2);
+ } else if (key === "style") {
+ patchStyle(el, prevValue, nextValue);
+ } else if (isOn(key)) {
+ if (!isModelListener(key)) {
+ patchEvent(el, key, prevValue, nextValue, parentComponent);
+ }
+ } else if (key[0] === "." ? (key = key.slice(1), true) : key[0] === "^" ? (key = key.slice(1), false) : shouldSetAsProp(el, key, nextValue, isSVG2)) {
+ patchDOMProp(el, key, nextValue);
+ if (!el.tagName.includes("-") && (key === "value" || key === "checked" || key === "selected")) {
+ patchAttr(el, key, nextValue, isSVG2, parentComponent, key !== "value");
+ }
+ } else if (
+ // #11081 force set props for possible async custom element
+ el._isVueCE && (/[A-Z]/.test(key) || !isString$1(nextValue))
+ ) {
+ patchDOMProp(el, camelize(key), nextValue, parentComponent, key);
+ } else {
+ if (key === "true-value") {
+ el._trueValue = nextValue;
+ } else if (key === "false-value") {
+ el._falseValue = nextValue;
+ }
+ patchAttr(el, key, nextValue, isSVG2);
+ }
+};
+function shouldSetAsProp(el, key, value, isSVG2) {
+ if (isSVG2) {
+ if (key === "innerHTML" || key === "textContent") {
+ return true;
+ }
+ if (key in el && isNativeOn(key) && isFunction$2(value)) {
+ return true;
+ }
+ return false;
+ }
+ if (key === "spellcheck" || key === "draggable" || key === "translate") {
+ return false;
+ }
+ if (key === "form") {
+ return false;
+ }
+ if (key === "list" && el.tagName === "INPUT") {
+ return false;
+ }
+ if (key === "type" && el.tagName === "TEXTAREA") {
+ return false;
+ }
+ if (key === "width" || key === "height") {
+ const tag2 = el.tagName;
+ if (tag2 === "IMG" || tag2 === "VIDEO" || tag2 === "CANVAS" || tag2 === "SOURCE") {
+ return false;
+ }
+ }
+ if (isNativeOn(key) && isString$1(value)) {
+ return false;
+ }
+ return key in el;
+}
+const positionMap = /* @__PURE__ */ new WeakMap();
+const newPositionMap = /* @__PURE__ */ new WeakMap();
+const moveCbKey = Symbol("_moveCb");
+const enterCbKey = Symbol("_enterCb");
+const decorate = (t) => {
+ delete t.props.mode;
+ return t;
+};
+const TransitionGroupImpl = /* @__PURE__ */ decorate({
+ name: "TransitionGroup",
+ props: /* @__PURE__ */ extend$1({}, TransitionPropsValidators, {
+ tag: String,
+ moveClass: String
+ }),
+ setup(props, { slots }) {
+ const instance = getCurrentInstance();
+ const state2 = useTransitionState();
+ let prevChildren;
+ let children;
+ onUpdated(() => {
+ if (!prevChildren.length) {
+ return;
+ }
+ const moveClass = props.moveClass || `${props.name || "v"}-move`;
+ if (!hasCSSTransform(
+ prevChildren[0].el,
+ instance.vnode.el,
+ moveClass
+ )) {
+ return;
+ }
+ prevChildren.forEach(callPendingCbs);
+ prevChildren.forEach(recordPosition);
+ const movedChildren = prevChildren.filter(applyTranslation);
+ forceReflow();
+ movedChildren.forEach((c2) => {
+ const el = c2.el;
+ const style2 = el.style;
+ addTransitionClass(el, moveClass);
+ style2.transform = style2.webkitTransform = style2.transitionDuration = "";
+ const cb = el[moveCbKey] = (e) => {
+ if (e && e.target !== el) {
+ return;
+ }
+ if (!e || /transform$/.test(e.propertyName)) {
+ el.removeEventListener("transitionend", cb);
+ el[moveCbKey] = null;
+ removeTransitionClass(el, moveClass);
+ }
+ };
+ el.addEventListener("transitionend", cb);
+ });
+ });
+ return () => {
+ const rawProps = toRaw(props);
+ const cssTransitionProps = resolveTransitionProps(rawProps);
+ let tag2 = rawProps.tag || Fragment;
+ prevChildren = [];
+ if (children) {
+ for (let i = 0; i < children.length; i++) {
+ const child = children[i];
+ if (child.el && child.el instanceof Element) {
+ prevChildren.push(child);
+ setTransitionHooks(
+ child,
+ resolveTransitionHooks(
+ child,
+ cssTransitionProps,
+ state2,
+ instance
+ )
+ );
+ positionMap.set(
+ child,
+ child.el.getBoundingClientRect()
+ );
+ }
+ }
+ }
+ children = slots.default ? getTransitionRawChildren(slots.default()) : [];
+ for (let i = 0; i < children.length; i++) {
+ const child = children[i];
+ if (child.key != null) {
+ setTransitionHooks(
+ child,
+ resolveTransitionHooks(child, cssTransitionProps, state2, instance)
+ );
+ }
+ }
+ return createVNode(tag2, null, children);
+ };
+ }
+});
+const TransitionGroup = TransitionGroupImpl;
+function callPendingCbs(c2) {
+ const el = c2.el;
+ if (el[moveCbKey]) {
+ el[moveCbKey]();
+ }
+ if (el[enterCbKey]) {
+ el[enterCbKey]();
+ }
+}
+function recordPosition(c2) {
+ newPositionMap.set(c2, c2.el.getBoundingClientRect());
+}
+function applyTranslation(c2) {
+ const oldPos = positionMap.get(c2);
+ const newPos = newPositionMap.get(c2);
+ const dx = oldPos.left - newPos.left;
+ const dy = oldPos.top - newPos.top;
+ if (dx || dy) {
+ const s = c2.el.style;
+ s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;
+ s.transitionDuration = "0s";
+ return c2;
+ }
+}
+function hasCSSTransform(el, root2, moveClass) {
+ const clone = el.cloneNode();
+ const _vtc = el[vtcKey];
+ if (_vtc) {
+ _vtc.forEach((cls) => {
+ cls.split(/\s+/).forEach((c2) => c2 && clone.classList.remove(c2));
+ });
+ }
+ moveClass.split(/\s+/).forEach((c2) => c2 && clone.classList.add(c2));
+ clone.style.display = "none";
+ const container = root2.nodeType === 1 ? root2 : root2.parentNode;
+ container.appendChild(clone);
+ const { hasTransform } = getTransitionInfo(clone);
+ container.removeChild(clone);
+ return hasTransform;
+}
+const getModelAssigner = (vnode2) => {
+ const fn = vnode2.props["onUpdate:modelValue"] || false;
+ return isArray$3(fn) ? (value) => invokeArrayFns(fn, value) : fn;
+};
+function onCompositionStart(e) {
+ e.target.composing = true;
+}
+function onCompositionEnd(e) {
+ const target = e.target;
+ if (target.composing) {
+ target.composing = false;
+ target.dispatchEvent(new Event("input"));
+ }
+}
+const assignKey = Symbol("_assign");
+const vModelText = {
+ created(el, { modifiers: { lazy, trim: trim2, number } }, vnode2) {
+ el[assignKey] = getModelAssigner(vnode2);
+ const castToNumber = number || vnode2.props && vnode2.props.type === "number";
+ addEventListener(el, lazy ? "change" : "input", (e) => {
+ if (e.target.composing) return;
+ let domValue = el.value;
+ if (trim2) {
+ domValue = domValue.trim();
+ }
+ if (castToNumber) {
+ domValue = looseToNumber(domValue);
+ }
+ el[assignKey](domValue);
+ });
+ if (trim2) {
+ addEventListener(el, "change", () => {
+ el.value = el.value.trim();
+ });
+ }
+ if (!lazy) {
+ addEventListener(el, "compositionstart", onCompositionStart);
+ addEventListener(el, "compositionend", onCompositionEnd);
+ addEventListener(el, "change", onCompositionEnd);
+ }
+ },
+ // set value on mounted so it's after min/max for type="range"
+ mounted(el, { value }) {
+ el.value = value == null ? "" : value;
+ },
+ beforeUpdate(el, { value, oldValue, modifiers: { lazy, trim: trim2, number } }, vnode2) {
+ el[assignKey] = getModelAssigner(vnode2);
+ if (el.composing) return;
+ const elValue = (number || el.type === "number") && !/^0\d/.test(el.value) ? looseToNumber(el.value) : el.value;
+ const newValue = value == null ? "" : value;
+ if (elValue === newValue) {
+ return;
+ }
+ if (document.activeElement === el && el.type !== "range") {
+ if (lazy && value === oldValue) {
+ return;
+ }
+ if (trim2 && el.value.trim() === newValue) {
+ return;
+ }
+ }
+ el.value = newValue;
+ }
+};
+const systemModifiers = ["ctrl", "shift", "alt", "meta"];
+const modifierGuards = {
+ stop: (e) => e.stopPropagation(),
+ prevent: (e) => e.preventDefault(),
+ self: (e) => e.target !== e.currentTarget,
+ ctrl: (e) => !e.ctrlKey,
+ shift: (e) => !e.shiftKey,
+ alt: (e) => !e.altKey,
+ meta: (e) => !e.metaKey,
+ left: (e) => "button" in e && e.button !== 0,
+ middle: (e) => "button" in e && e.button !== 1,
+ right: (e) => "button" in e && e.button !== 2,
+ exact: (e, modifiers) => systemModifiers.some((m) => e[`${m}Key`] && !modifiers.includes(m))
+};
+const withModifiers = (fn, modifiers) => {
+ const cache2 = fn._withMods || (fn._withMods = {});
+ const cacheKey = modifiers.join(".");
+ return cache2[cacheKey] || (cache2[cacheKey] = (event, ...args) => {
+ for (let i = 0; i < modifiers.length; i++) {
+ const guard = modifierGuards[modifiers[i]];
+ if (guard && guard(event, modifiers)) return;
+ }
+ return fn(event, ...args);
+ });
+};
+const keyNames = {
+ esc: "escape",
+ space: " ",
+ up: "arrow-up",
+ left: "arrow-left",
+ right: "arrow-right",
+ down: "arrow-down",
+ delete: "backspace"
+};
+const withKeys = (fn, modifiers) => {
+ const cache2 = fn._withKeys || (fn._withKeys = {});
+ const cacheKey = modifiers.join(".");
+ return cache2[cacheKey] || (cache2[cacheKey] = (event) => {
+ if (!("key" in event)) {
+ return;
+ }
+ const eventKey = hyphenate(event.key);
+ if (modifiers.some(
+ (k) => k === eventKey || keyNames[k] === eventKey
+ )) {
+ return fn(event);
+ }
+ });
+};
+const rendererOptions = /* @__PURE__ */ extend$1({ patchProp }, nodeOps);
+let renderer;
+function ensureRenderer() {
+ return renderer || (renderer = createRenderer(rendererOptions));
+}
+const render$2 = (...args) => {
+ ensureRenderer().render(...args);
+};
+const createApp = (...args) => {
+ const app2 = ensureRenderer().createApp(...args);
+ const { mount: mount2 } = app2;
+ app2.mount = (containerOrSelector) => {
+ const container = normalizeContainer(containerOrSelector);
+ if (!container) return;
+ const component = app2._component;
+ if (!isFunction$2(component) && !component.render && !component.template) {
+ component.template = container.innerHTML;
+ }
+ if (container.nodeType === 1) {
+ container.textContent = "";
+ }
+ const proxy = mount2(container, false, resolveRootNamespace(container));
+ if (container instanceof Element) {
+ container.removeAttribute("v-cloak");
+ container.setAttribute("data-v-app", "");
+ }
+ return proxy;
+ };
+ return app2;
+};
+function resolveRootNamespace(container) {
+ if (container instanceof SVGElement) {
+ return "svg";
+ }
+ if (typeof MathMLElement === "function" && container instanceof MathMLElement) {
+ return "mathml";
+ }
+}
+function normalizeContainer(container) {
+ if (isString$1(container)) {
+ const res = document.querySelector(container);
+ return res;
+ }
+ return container;
+}
+const scriptRel = function detectScriptRel() {
+ const relList = typeof document !== "undefined" && document.createElement("link").relList;
+ return relList && relList.supports && relList.supports("modulepreload") ? "modulepreload" : "preload";
+}();
+const assetsURL = function(dep, importerUrl) {
+ return new URL(dep, importerUrl).href;
+};
+const seen = {};
+const __vitePreload = function preload(baseModule, deps, importerUrl) {
+ let promise = Promise.resolve();
+ if (deps && deps.length > 0) {
+ const links = document.getElementsByTagName("link");
+ const cspNonceMeta = document.querySelector(
+ "meta[property=csp-nonce]"
+ );
+ const cspNonce = cspNonceMeta?.nonce || cspNonceMeta?.getAttribute("nonce");
+ promise = Promise.allSettled(
+ deps.map((dep) => {
+ dep = assetsURL(dep, importerUrl);
+ if (dep in seen) return;
+ seen[dep] = true;
+ const isCss = dep.endsWith(".css");
+ const cssSelector = isCss ? '[rel="stylesheet"]' : "";
+ const isBaseRelative = !!importerUrl;
+ if (isBaseRelative) {
+ for (let i = links.length - 1; i >= 0; i--) {
+ const link22 = links[i];
+ if (link22.href === dep && (!isCss || link22.rel === "stylesheet")) {
+ return;
+ }
+ }
+ } else if (document.querySelector(`link[href="${dep}"]${cssSelector}`)) {
+ return;
+ }
+ const link2 = document.createElement("link");
+ link2.rel = isCss ? "stylesheet" : scriptRel;
+ if (!isCss) {
+ link2.as = "script";
+ }
+ link2.crossOrigin = "";
+ link2.href = dep;
+ if (cspNonce) {
+ link2.setAttribute("nonce", cspNonce);
+ }
+ document.head.appendChild(link2);
+ if (isCss) {
+ return new Promise((res, rej) => {
+ link2.addEventListener("load", res);
+ link2.addEventListener(
+ "error",
+ () => rej(new Error(`Unable to preload CSS for ${dep}`))
+ );
+ });
+ }
+ })
+ );
+ }
+ function handlePreloadError(err) {
+ const e = new Event("vite:preloadError", {
+ cancelable: true
+ });
+ e.payload = err;
+ window.dispatchEvent(e);
+ if (!e.defaultPrevented) {
+ throw err;
+ }
+ }
+ return promise.then((res) => {
+ for (const item of res || []) {
+ if (item.status !== "rejected") continue;
+ handlePreloadError(item.reason);
+ }
+ return baseModule().catch(handlePreloadError);
+ });
+};
+function getDevtoolsGlobalHook() {
+ return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;
+}
+function getTarget() {
+ return typeof navigator !== "undefined" && typeof window !== "undefined" ? window : typeof globalThis !== "undefined" ? globalThis : {};
+}
+const isProxyAvailable = typeof Proxy === "function";
+const HOOK_SETUP = "devtools-plugin:setup";
+const HOOK_PLUGIN_SETTINGS_SET = "plugin:settings:set";
+let supported;
+let perf;
+function isPerformanceSupported() {
+ var _a;
+ if (supported !== void 0) {
+ return supported;
+ }
+ if (typeof window !== "undefined" && window.performance) {
+ supported = true;
+ perf = window.performance;
+ } else if (typeof globalThis !== "undefined" && ((_a = globalThis.perf_hooks) === null || _a === void 0 ? void 0 : _a.performance)) {
+ supported = true;
+ perf = globalThis.perf_hooks.performance;
+ } else {
+ supported = false;
+ }
+ return supported;
+}
+function now() {
+ return isPerformanceSupported() ? perf.now() : Date.now();
+}
+class ApiProxy {
+ constructor(plugin2, hook) {
+ this.target = null;
+ this.targetQueue = [];
+ this.onQueue = [];
+ this.plugin = plugin2;
+ this.hook = hook;
+ const defaultSettings2 = {};
+ if (plugin2.settings) {
+ for (const id in plugin2.settings) {
+ const item = plugin2.settings[id];
+ defaultSettings2[id] = item.defaultValue;
+ }
+ }
+ const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin2.id}`;
+ let currentSettings = Object.assign({}, defaultSettings2);
+ try {
+ const raw = localStorage.getItem(localSettingsSaveId);
+ const data = JSON.parse(raw);
+ Object.assign(currentSettings, data);
+ } catch (e) {
+ }
+ this.fallbacks = {
+ getSettings() {
+ return currentSettings;
+ },
+ setSettings(value) {
+ try {
+ localStorage.setItem(localSettingsSaveId, JSON.stringify(value));
+ } catch (e) {
+ }
+ currentSettings = value;
+ },
+ now() {
+ return now();
+ }
+ };
+ if (hook) {
+ hook.on(HOOK_PLUGIN_SETTINGS_SET, (pluginId, value) => {
+ if (pluginId === this.plugin.id) {
+ this.fallbacks.setSettings(value);
+ }
+ });
+ }
+ this.proxiedOn = new Proxy({}, {
+ get: (_target, prop) => {
+ if (this.target) {
+ return this.target.on[prop];
+ } else {
+ return (...args) => {
+ this.onQueue.push({
+ method: prop,
+ args
+ });
+ };
+ }
+ }
+ });
+ this.proxiedTarget = new Proxy({}, {
+ get: (_target, prop) => {
+ if (this.target) {
+ return this.target[prop];
+ } else if (prop === "on") {
+ return this.proxiedOn;
+ } else if (Object.keys(this.fallbacks).includes(prop)) {
+ return (...args) => {
+ this.targetQueue.push({
+ method: prop,
+ args,
+ resolve: () => {
+ }
+ });
+ return this.fallbacks[prop](...args);
+ };
+ } else {
+ return (...args) => {
+ return new Promise((resolve2) => {
+ this.targetQueue.push({
+ method: prop,
+ args,
+ resolve: resolve2
+ });
+ });
+ };
+ }
+ }
+ });
+ }
+ async setRealTarget(target) {
+ this.target = target;
+ for (const item of this.onQueue) {
+ this.target.on[item.method](...item.args);
+ }
+ for (const item of this.targetQueue) {
+ item.resolve(await this.target[item.method](...item.args));
+ }
+ }
+}
+function setupDevtoolsPlugin(pluginDescriptor, setupFn) {
+ const descriptor = pluginDescriptor;
+ const target = getTarget();
+ const hook = getDevtoolsGlobalHook();
+ const enableProxy = isProxyAvailable && descriptor.enableEarlyProxy;
+ if (hook && (target.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) {
+ hook.emit(HOOK_SETUP, pluginDescriptor, setupFn);
+ } else {
+ const proxy = enableProxy ? new ApiProxy(descriptor, hook) : null;
+ const list2 = target.__VUE_DEVTOOLS_PLUGINS__ = target.__VUE_DEVTOOLS_PLUGINS__ || [];
+ list2.push({
+ pluginDescriptor: descriptor,
+ setupFn,
+ proxy
+ });
+ if (proxy) {
+ setupFn(proxy.proxiedTarget);
+ }
+ }
+}
+/*!
+ * vue-router v4.5.0
+ * (c) 2024 Eduardo San Martin Morote
+ * @license MIT
+ */
+const isBrowser$3 = typeof document !== "undefined";
+function isRouteComponent(component) {
+ return typeof component === "object" || "displayName" in component || "props" in component || "__vccOpts" in component;
+}
+function isESModule(obj) {
+ return obj.__esModule || obj[Symbol.toStringTag] === "Module" || // support CF with dynamic imports that do not
+ // add the Module string tag
+ obj.default && isRouteComponent(obj.default);
+}
+const assign = Object.assign;
+function applyToParams(fn, params) {
+ const newParams = {};
+ for (const key in params) {
+ const value = params[key];
+ newParams[key] = isArray$2(value) ? value.map(fn) : fn(value);
+ }
+ return newParams;
+}
+const noop$2 = () => {
+};
+const isArray$2 = Array.isArray;
+const HASH_RE = /#/g;
+const AMPERSAND_RE = /&/g;
+const SLASH_RE = /\//g;
+const EQUAL_RE = /=/g;
+const IM_RE = /\?/g;
+const PLUS_RE = /\+/g;
+const ENC_BRACKET_OPEN_RE = /%5B/g;
+const ENC_BRACKET_CLOSE_RE = /%5D/g;
+const ENC_CARET_RE = /%5E/g;
+const ENC_BACKTICK_RE = /%60/g;
+const ENC_CURLY_OPEN_RE = /%7B/g;
+const ENC_PIPE_RE = /%7C/g;
+const ENC_CURLY_CLOSE_RE = /%7D/g;
+const ENC_SPACE_RE = /%20/g;
+function commonEncode(text) {
+ return encodeURI("" + text).replace(ENC_PIPE_RE, "|").replace(ENC_BRACKET_OPEN_RE, "[").replace(ENC_BRACKET_CLOSE_RE, "]");
+}
+function encodeHash(text) {
+ return commonEncode(text).replace(ENC_CURLY_OPEN_RE, "{").replace(ENC_CURLY_CLOSE_RE, "}").replace(ENC_CARET_RE, "^");
+}
+function encodeQueryValue(text) {
+ return commonEncode(text).replace(PLUS_RE, "%2B").replace(ENC_SPACE_RE, "+").replace(HASH_RE, "%23").replace(AMPERSAND_RE, "%26").replace(ENC_BACKTICK_RE, "`").replace(ENC_CURLY_OPEN_RE, "{").replace(ENC_CURLY_CLOSE_RE, "}").replace(ENC_CARET_RE, "^");
+}
+function encodeQueryKey(text) {
+ return encodeQueryValue(text).replace(EQUAL_RE, "%3D");
+}
+function encodePath(text) {
+ return commonEncode(text).replace(HASH_RE, "%23").replace(IM_RE, "%3F");
+}
+function encodeParam(text) {
+ return text == null ? "" : encodePath(text).replace(SLASH_RE, "%2F");
+}
+function decode(text) {
+ try {
+ return decodeURIComponent("" + text);
+ } catch (err) {
+ }
+ return "" + text;
+}
+const TRAILING_SLASH_RE = /\/$/;
+const removeTrailingSlash = (path) => path.replace(TRAILING_SLASH_RE, "");
+function parseURL(parseQuery2, location2, currentLocation = "/") {
+ let path, query = {}, searchString = "", hash = "";
+ const hashPos = location2.indexOf("#");
+ let searchPos = location2.indexOf("?");
+ if (hashPos < searchPos && hashPos >= 0) {
+ searchPos = -1;
+ }
+ if (searchPos > -1) {
+ path = location2.slice(0, searchPos);
+ searchString = location2.slice(searchPos + 1, hashPos > -1 ? hashPos : location2.length);
+ query = parseQuery2(searchString);
+ }
+ if (hashPos > -1) {
+ path = path || location2.slice(0, hashPos);
+ hash = location2.slice(hashPos, location2.length);
+ }
+ path = resolveRelativePath(path != null ? path : location2, currentLocation);
+ return {
+ fullPath: path + (searchString && "?") + searchString + hash,
+ path,
+ query,
+ hash: decode(hash)
+ };
+}
+function stringifyURL(stringifyQuery2, location2) {
+ const query = location2.query ? stringifyQuery2(location2.query) : "";
+ return location2.path + (query && "?") + query + (location2.hash || "");
+}
+function stripBase(pathname, base2) {
+ if (!base2 || !pathname.toLowerCase().startsWith(base2.toLowerCase()))
+ return pathname;
+ return pathname.slice(base2.length) || "/";
+}
+function isSameRouteLocation(stringifyQuery2, a, b) {
+ const aLastIndex = a.matched.length - 1;
+ const bLastIndex = b.matched.length - 1;
+ return aLastIndex > -1 && aLastIndex === bLastIndex && isSameRouteRecord(a.matched[aLastIndex], b.matched[bLastIndex]) && isSameRouteLocationParams(a.params, b.params) && stringifyQuery2(a.query) === stringifyQuery2(b.query) && a.hash === b.hash;
+}
+function isSameRouteRecord(a, b) {
+ return (a.aliasOf || a) === (b.aliasOf || b);
+}
+function isSameRouteLocationParams(a, b) {
+ if (Object.keys(a).length !== Object.keys(b).length)
+ return false;
+ for (const key in a) {
+ if (!isSameRouteLocationParamsValue(a[key], b[key]))
+ return false;
+ }
+ return true;
+}
+function isSameRouteLocationParamsValue(a, b) {
+ return isArray$2(a) ? isEquivalentArray(a, b) : isArray$2(b) ? isEquivalentArray(b, a) : a === b;
+}
+function isEquivalentArray(a, b) {
+ return isArray$2(b) ? a.length === b.length && a.every((value, i) => value === b[i]) : a.length === 1 && a[0] === b;
+}
+function resolveRelativePath(to, from) {
+ if (to.startsWith("/"))
+ return to;
+ if (!to)
+ return from;
+ const fromSegments = from.split("/");
+ const toSegments = to.split("/");
+ const lastToSegment = toSegments[toSegments.length - 1];
+ if (lastToSegment === ".." || lastToSegment === ".") {
+ toSegments.push("");
+ }
+ let position = fromSegments.length - 1;
+ let toPosition;
+ let segment;
+ for (toPosition = 0; toPosition < toSegments.length; toPosition++) {
+ segment = toSegments[toPosition];
+ if (segment === ".")
+ continue;
+ if (segment === "..") {
+ if (position > 1)
+ position--;
+ } else
+ break;
+ }
+ return fromSegments.slice(0, position).join("/") + "/" + toSegments.slice(toPosition).join("/");
+}
+const START_LOCATION_NORMALIZED = {
+ path: "/",
+ // TODO: could we use a symbol in the future?
+ name: void 0,
+ params: {},
+ query: {},
+ hash: "",
+ fullPath: "/",
+ matched: [],
+ meta: {},
+ redirectedFrom: void 0
+};
+var NavigationType;
+(function(NavigationType2) {
+ NavigationType2["pop"] = "pop";
+ NavigationType2["push"] = "push";
+})(NavigationType || (NavigationType = {}));
+var NavigationDirection;
+(function(NavigationDirection2) {
+ NavigationDirection2["back"] = "back";
+ NavigationDirection2["forward"] = "forward";
+ NavigationDirection2["unknown"] = "";
+})(NavigationDirection || (NavigationDirection = {}));
+function normalizeBase(base2) {
+ if (!base2) {
+ if (isBrowser$3) {
+ const baseEl = document.querySelector("base");
+ base2 = baseEl && baseEl.getAttribute("href") || "/";
+ base2 = base2.replace(/^\w+:\/\/[^\/]+/, "");
+ } else {
+ base2 = "/";
+ }
+ }
+ if (base2[0] !== "/" && base2[0] !== "#")
+ base2 = "/" + base2;
+ return removeTrailingSlash(base2);
+}
+const BEFORE_HASH_RE = /^[^#]+#/;
+function createHref(base2, location2) {
+ return base2.replace(BEFORE_HASH_RE, "#") + location2;
+}
+function getElementPosition(el, offset) {
+ const docRect = document.documentElement.getBoundingClientRect();
+ const elRect = el.getBoundingClientRect();
+ return {
+ behavior: offset.behavior,
+ left: elRect.left - docRect.left - (offset.left || 0),
+ top: elRect.top - docRect.top - (offset.top || 0)
+ };
+}
+const computeScrollPosition = () => ({
+ left: window.scrollX,
+ top: window.scrollY
+});
+function scrollToPosition(position) {
+ let scrollToOptions;
+ if ("el" in position) {
+ const positionEl = position.el;
+ const isIdSelector = typeof positionEl === "string" && positionEl.startsWith("#");
+ const el = typeof positionEl === "string" ? isIdSelector ? document.getElementById(positionEl.slice(1)) : document.querySelector(positionEl) : positionEl;
+ if (!el) {
+ return;
+ }
+ scrollToOptions = getElementPosition(el, position);
+ } else {
+ scrollToOptions = position;
+ }
+ if ("scrollBehavior" in document.documentElement.style)
+ window.scrollTo(scrollToOptions);
+ else {
+ window.scrollTo(scrollToOptions.left != null ? scrollToOptions.left : window.scrollX, scrollToOptions.top != null ? scrollToOptions.top : window.scrollY);
+ }
+}
+function getScrollKey(path, delta) {
+ const position = history.state ? history.state.position - delta : -1;
+ return position + path;
+}
+const scrollPositions = /* @__PURE__ */ new Map();
+function saveScrollPosition(key, scrollPosition) {
+ scrollPositions.set(key, scrollPosition);
+}
+function getSavedScrollPosition(key) {
+ const scroll = scrollPositions.get(key);
+ scrollPositions.delete(key);
+ return scroll;
+}
+let createBaseLocation = () => location.protocol + "//" + location.host;
+function createCurrentLocation(base2, location2) {
+ const { pathname, search, hash } = location2;
+ const hashPos = base2.indexOf("#");
+ if (hashPos > -1) {
+ let slicePos = hash.includes(base2.slice(hashPos)) ? base2.slice(hashPos).length : 1;
+ let pathFromHash = hash.slice(slicePos);
+ if (pathFromHash[0] !== "/")
+ pathFromHash = "/" + pathFromHash;
+ return stripBase(pathFromHash, "");
+ }
+ const path = stripBase(pathname, base2);
+ return path + search + hash;
+}
+function useHistoryListeners(base2, historyState, currentLocation, replace) {
+ let listeners = [];
+ let teardowns = [];
+ let pauseState = null;
+ const popStateHandler = ({ state: state2 }) => {
+ const to = createCurrentLocation(base2, location);
+ const from = currentLocation.value;
+ const fromState = historyState.value;
+ let delta = 0;
+ if (state2) {
+ currentLocation.value = to;
+ historyState.value = state2;
+ if (pauseState && pauseState === from) {
+ pauseState = null;
+ return;
+ }
+ delta = fromState ? state2.position - fromState.position : 0;
+ } else {
+ replace(to);
+ }
+ listeners.forEach((listener) => {
+ listener(currentLocation.value, from, {
+ delta,
+ type: NavigationType.pop,
+ direction: delta ? delta > 0 ? NavigationDirection.forward : NavigationDirection.back : NavigationDirection.unknown
+ });
+ });
+ };
+ function pauseListeners() {
+ pauseState = currentLocation.value;
+ }
+ function listen(callback) {
+ listeners.push(callback);
+ const teardown = () => {
+ const index = listeners.indexOf(callback);
+ if (index > -1)
+ listeners.splice(index, 1);
+ };
+ teardowns.push(teardown);
+ return teardown;
+ }
+ function beforeUnloadListener() {
+ const { history: history2 } = window;
+ if (!history2.state)
+ return;
+ history2.replaceState(assign({}, history2.state, { scroll: computeScrollPosition() }), "");
+ }
+ function destroy() {
+ for (const teardown of teardowns)
+ teardown();
+ teardowns = [];
+ window.removeEventListener("popstate", popStateHandler);
+ window.removeEventListener("beforeunload", beforeUnloadListener);
+ }
+ window.addEventListener("popstate", popStateHandler);
+ window.addEventListener("beforeunload", beforeUnloadListener, {
+ passive: true
+ });
+ return {
+ pauseListeners,
+ listen,
+ destroy
+ };
+}
+function buildState(back, current, forward, replaced = false, computeScroll = false) {
+ return {
+ back,
+ current,
+ forward,
+ replaced,
+ position: window.history.length,
+ scroll: computeScroll ? computeScrollPosition() : null
+ };
+}
+function useHistoryStateNavigation(base2) {
+ const { history: history2, location: location2 } = window;
+ const currentLocation = {
+ value: createCurrentLocation(base2, location2)
+ };
+ const historyState = { value: history2.state };
+ if (!historyState.value) {
+ changeLocation(currentLocation.value, {
+ back: null,
+ current: currentLocation.value,
+ forward: null,
+ // the length is off by one, we need to decrease it
+ position: history2.length - 1,
+ replaced: true,
+ // don't add a scroll as the user may have an anchor, and we want
+ // scrollBehavior to be triggered without a saved position
+ scroll: null
+ }, true);
+ }
+ function changeLocation(to, state2, replace2) {
+ const hashIndex = base2.indexOf("#");
+ const url = hashIndex > -1 ? (location2.host && document.querySelector("base") ? base2 : base2.slice(hashIndex)) + to : createBaseLocation() + base2 + to;
+ try {
+ history2[replace2 ? "replaceState" : "pushState"](state2, "", url);
+ historyState.value = state2;
+ } catch (err) {
+ {
+ console.error(err);
+ }
+ location2[replace2 ? "replace" : "assign"](url);
+ }
+ }
+ function replace(to, data) {
+ const state2 = assign({}, history2.state, buildState(
+ historyState.value.back,
+ // keep back and forward entries but override current position
+ to,
+ historyState.value.forward,
+ true
+ ), data, { position: historyState.value.position });
+ changeLocation(to, state2, true);
+ currentLocation.value = to;
+ }
+ function push(to, data) {
+ const currentState = assign(
+ {},
+ // use current history state to gracefully handle a wrong call to
+ // history.replaceState
+ // https://github.com/vuejs/router/issues/366
+ historyState.value,
+ history2.state,
+ {
+ forward: to,
+ scroll: computeScrollPosition()
+ }
+ );
+ changeLocation(currentState.current, currentState, true);
+ const state2 = assign({}, buildState(currentLocation.value, to, null), { position: currentState.position + 1 }, data);
+ changeLocation(to, state2, false);
+ currentLocation.value = to;
+ }
+ return {
+ location: currentLocation,
+ state: historyState,
+ push,
+ replace
+ };
+}
+function createWebHistory(base2) {
+ base2 = normalizeBase(base2);
+ const historyNavigation = useHistoryStateNavigation(base2);
+ const historyListeners = useHistoryListeners(base2, historyNavigation.state, historyNavigation.location, historyNavigation.replace);
+ function go(delta, triggerListeners = true) {
+ if (!triggerListeners)
+ historyListeners.pauseListeners();
+ history.go(delta);
+ }
+ const routerHistory = assign({
+ // it's overridden right after
+ location: "",
+ base: base2,
+ go,
+ createHref: createHref.bind(null, base2)
+ }, historyNavigation, historyListeners);
+ Object.defineProperty(routerHistory, "location", {
+ enumerable: true,
+ get: () => historyNavigation.location.value
+ });
+ Object.defineProperty(routerHistory, "state", {
+ enumerable: true,
+ get: () => historyNavigation.state.value
+ });
+ return routerHistory;
+}
+function createWebHashHistory(base2) {
+ base2 = location.host ? base2 || location.pathname + location.search : "";
+ if (!base2.includes("#"))
+ base2 += "#";
+ return createWebHistory(base2);
+}
+function isRouteLocation(route) {
+ return typeof route === "string" || route && typeof route === "object";
+}
+function isRouteName(name2) {
+ return typeof name2 === "string" || typeof name2 === "symbol";
+}
+const NavigationFailureSymbol = Symbol("");
+var NavigationFailureType;
+(function(NavigationFailureType2) {
+ NavigationFailureType2[NavigationFailureType2["aborted"] = 4] = "aborted";
+ NavigationFailureType2[NavigationFailureType2["cancelled"] = 8] = "cancelled";
+ NavigationFailureType2[NavigationFailureType2["duplicated"] = 16] = "duplicated";
+})(NavigationFailureType || (NavigationFailureType = {}));
+function createRouterError(type, params) {
+ {
+ return assign(new Error(), {
+ type,
+ [NavigationFailureSymbol]: true
+ }, params);
+ }
+}
+function isNavigationFailure(error, type) {
+ return error instanceof Error && NavigationFailureSymbol in error && (type == null || !!(error.type & type));
+}
+const BASE_PARAM_PATTERN = "[^/]+?";
+const BASE_PATH_PARSER_OPTIONS = {
+ sensitive: false,
+ strict: false,
+ start: true,
+ end: true
+};
+const REGEX_CHARS_RE = /[.+*?^${}()[\]/\\]/g;
+function tokensToParser(segments, extraOptions) {
+ const options = assign({}, BASE_PATH_PARSER_OPTIONS, extraOptions);
+ const score = [];
+ let pattern = options.start ? "^" : "";
+ const keys = [];
+ for (const segment of segments) {
+ const segmentScores = segment.length ? [] : [
+ 90
+ /* PathScore.Root */
+ ];
+ if (options.strict && !segment.length)
+ pattern += "/";
+ for (let tokenIndex = 0; tokenIndex < segment.length; tokenIndex++) {
+ const token = segment[tokenIndex];
+ let subSegmentScore = 40 + (options.sensitive ? 0.25 : 0);
+ if (token.type === 0) {
+ if (!tokenIndex)
+ pattern += "/";
+ pattern += token.value.replace(REGEX_CHARS_RE, "\\$&");
+ subSegmentScore += 40;
+ } else if (token.type === 1) {
+ const { value, repeatable, optional, regexp } = token;
+ keys.push({
+ name: value,
+ repeatable,
+ optional
+ });
+ const re2 = regexp ? regexp : BASE_PARAM_PATTERN;
+ if (re2 !== BASE_PARAM_PATTERN) {
+ subSegmentScore += 10;
+ try {
+ new RegExp(`(${re2})`);
+ } catch (err) {
+ throw new Error(`Invalid custom RegExp for param "${value}" (${re2}): ` + err.message);
+ }
+ }
+ let subPattern = repeatable ? `((?:${re2})(?:/(?:${re2}))*)` : `(${re2})`;
+ if (!tokenIndex)
+ subPattern = // avoid an optional / if there are more segments e.g. /:p?-static
+ // or /:p?-:p2
+ optional && segment.length < 2 ? `(?:/${subPattern})` : "/" + subPattern;
+ if (optional)
+ subPattern += "?";
+ pattern += subPattern;
+ subSegmentScore += 20;
+ if (optional)
+ subSegmentScore += -8;
+ if (repeatable)
+ subSegmentScore += -20;
+ if (re2 === ".*")
+ subSegmentScore += -50;
+ }
+ segmentScores.push(subSegmentScore);
+ }
+ score.push(segmentScores);
+ }
+ if (options.strict && options.end) {
+ const i = score.length - 1;
+ score[i][score[i].length - 1] += 0.7000000000000001;
+ }
+ if (!options.strict)
+ pattern += "/?";
+ if (options.end)
+ pattern += "$";
+ else if (options.strict && !pattern.endsWith("/"))
+ pattern += "(?:/|$)";
+ const re = new RegExp(pattern, options.sensitive ? "" : "i");
+ function parse(path) {
+ const match = path.match(re);
+ const params = {};
+ if (!match)
+ return null;
+ for (let i = 1; i < match.length; i++) {
+ const value = match[i] || "";
+ const key = keys[i - 1];
+ params[key.name] = value && key.repeatable ? value.split("/") : value;
+ }
+ return params;
+ }
+ function stringify(params) {
+ let path = "";
+ let avoidDuplicatedSlash = false;
+ for (const segment of segments) {
+ if (!avoidDuplicatedSlash || !path.endsWith("/"))
+ path += "/";
+ avoidDuplicatedSlash = false;
+ for (const token of segment) {
+ if (token.type === 0) {
+ path += token.value;
+ } else if (token.type === 1) {
+ const { value, repeatable, optional } = token;
+ const param = value in params ? params[value] : "";
+ if (isArray$2(param) && !repeatable) {
+ throw new Error(`Provided param "${value}" is an array but it is not repeatable (* or + modifiers)`);
+ }
+ const text = isArray$2(param) ? param.join("/") : param;
+ if (!text) {
+ if (optional) {
+ if (segment.length < 2) {
+ if (path.endsWith("/"))
+ path = path.slice(0, -1);
+ else
+ avoidDuplicatedSlash = true;
+ }
+ } else
+ throw new Error(`Missing required param "${value}"`);
+ }
+ path += text;
+ }
+ }
+ }
+ return path || "/";
+ }
+ return {
+ re,
+ score,
+ keys,
+ parse,
+ stringify
+ };
+}
+function compareScoreArray(a, b) {
+ let i = 0;
+ while (i < a.length && i < b.length) {
+ const diff = b[i] - a[i];
+ if (diff)
+ return diff;
+ i++;
+ }
+ if (a.length < b.length) {
+ return a.length === 1 && a[0] === 40 + 40 ? -1 : 1;
+ } else if (a.length > b.length) {
+ return b.length === 1 && b[0] === 40 + 40 ? 1 : -1;
+ }
+ return 0;
+}
+function comparePathParserScore(a, b) {
+ let i = 0;
+ const aScore = a.score;
+ const bScore = b.score;
+ while (i < aScore.length && i < bScore.length) {
+ const comp = compareScoreArray(aScore[i], bScore[i]);
+ if (comp)
+ return comp;
+ i++;
+ }
+ if (Math.abs(bScore.length - aScore.length) === 1) {
+ if (isLastScoreNegative(aScore))
+ return 1;
+ if (isLastScoreNegative(bScore))
+ return -1;
+ }
+ return bScore.length - aScore.length;
+}
+function isLastScoreNegative(score) {
+ const last = score[score.length - 1];
+ return score.length > 0 && last[last.length - 1] < 0;
+}
+const ROOT_TOKEN = {
+ type: 0,
+ value: ""
+};
+const VALID_PARAM_RE = /[a-zA-Z0-9_]/;
+function tokenizePath(path) {
+ if (!path)
+ return [[]];
+ if (path === "/")
+ return [[ROOT_TOKEN]];
+ if (!path.startsWith("/")) {
+ throw new Error(`Invalid path "${path}"`);
+ }
+ function crash(message) {
+ throw new Error(`ERR (${state2})/"${buffer}": ${message}`);
+ }
+ let state2 = 0;
+ let previousState = state2;
+ const tokens = [];
+ let segment;
+ function finalizeSegment() {
+ if (segment)
+ tokens.push(segment);
+ segment = [];
+ }
+ let i = 0;
+ let char;
+ let buffer = "";
+ let customRe = "";
+ function consumeBuffer() {
+ if (!buffer)
+ return;
+ if (state2 === 0) {
+ segment.push({
+ type: 0,
+ value: buffer
+ });
+ } else if (state2 === 1 || state2 === 2 || state2 === 3) {
+ if (segment.length > 1 && (char === "*" || char === "+"))
+ crash(`A repeatable param (${buffer}) must be alone in its segment. eg: '/:ids+.`);
+ segment.push({
+ type: 1,
+ value: buffer,
+ regexp: customRe,
+ repeatable: char === "*" || char === "+",
+ optional: char === "*" || char === "?"
+ });
+ } else {
+ crash("Invalid state to consume buffer");
+ }
+ buffer = "";
+ }
+ function addCharToBuffer() {
+ buffer += char;
+ }
+ while (i < path.length) {
+ char = path[i++];
+ if (char === "\\" && state2 !== 2) {
+ previousState = state2;
+ state2 = 4;
+ continue;
+ }
+ switch (state2) {
+ case 0:
+ if (char === "/") {
+ if (buffer) {
+ consumeBuffer();
+ }
+ finalizeSegment();
+ } else if (char === ":") {
+ consumeBuffer();
+ state2 = 1;
+ } else {
+ addCharToBuffer();
+ }
+ break;
+ case 4:
+ addCharToBuffer();
+ state2 = previousState;
+ break;
+ case 1:
+ if (char === "(") {
+ state2 = 2;
+ } else if (VALID_PARAM_RE.test(char)) {
+ addCharToBuffer();
+ } else {
+ consumeBuffer();
+ state2 = 0;
+ if (char !== "*" && char !== "?" && char !== "+")
+ i--;
+ }
+ break;
+ case 2:
+ if (char === ")") {
+ if (customRe[customRe.length - 1] == "\\")
+ customRe = customRe.slice(0, -1) + char;
+ else
+ state2 = 3;
+ } else {
+ customRe += char;
+ }
+ break;
+ case 3:
+ consumeBuffer();
+ state2 = 0;
+ if (char !== "*" && char !== "?" && char !== "+")
+ i--;
+ customRe = "";
+ break;
+ default:
+ crash("Unknown state");
+ break;
+ }
+ }
+ if (state2 === 2)
+ crash(`Unfinished custom RegExp for param "${buffer}"`);
+ consumeBuffer();
+ finalizeSegment();
+ return tokens;
+}
+function createRouteRecordMatcher(record, parent, options) {
+ const parser = tokensToParser(tokenizePath(record.path), options);
+ const matcher = assign(parser, {
+ record,
+ parent,
+ // these needs to be populated by the parent
+ children: [],
+ alias: []
+ });
+ if (parent) {
+ if (!matcher.record.aliasOf === !parent.record.aliasOf)
+ parent.children.push(matcher);
+ }
+ return matcher;
+}
+function createRouterMatcher(routes2, globalOptions) {
+ const matchers = [];
+ const matcherMap = /* @__PURE__ */ new Map();
+ globalOptions = mergeOptions({ strict: false, end: true, sensitive: false }, globalOptions);
+ function getRecordMatcher(name2) {
+ return matcherMap.get(name2);
+ }
+ function addRoute(record, parent, originalRecord) {
+ const isRootAdd = !originalRecord;
+ const mainNormalizedRecord = normalizeRouteRecord(record);
+ mainNormalizedRecord.aliasOf = originalRecord && originalRecord.record;
+ const options = mergeOptions(globalOptions, record);
+ const normalizedRecords = [mainNormalizedRecord];
+ if ("alias" in record) {
+ const aliases = typeof record.alias === "string" ? [record.alias] : record.alias;
+ for (const alias of aliases) {
+ normalizedRecords.push(
+ // we need to normalize again to ensure the `mods` property
+ // being non enumerable
+ normalizeRouteRecord(assign({}, mainNormalizedRecord, {
+ // this allows us to hold a copy of the `components` option
+ // so that async components cache is hold on the original record
+ components: originalRecord ? originalRecord.record.components : mainNormalizedRecord.components,
+ path: alias,
+ // we might be the child of an alias
+ aliasOf: originalRecord ? originalRecord.record : mainNormalizedRecord
+ // the aliases are always of the same kind as the original since they
+ // are defined on the same record
+ }))
+ );
+ }
+ }
+ let matcher;
+ let originalMatcher;
+ for (const normalizedRecord of normalizedRecords) {
+ const { path } = normalizedRecord;
+ if (parent && path[0] !== "/") {
+ const parentPath = parent.record.path;
+ const connectingSlash = parentPath[parentPath.length - 1] === "/" ? "" : "/";
+ normalizedRecord.path = parent.record.path + (path && connectingSlash + path);
+ }
+ matcher = createRouteRecordMatcher(normalizedRecord, parent, options);
+ if (originalRecord) {
+ originalRecord.alias.push(matcher);
+ } else {
+ originalMatcher = originalMatcher || matcher;
+ if (originalMatcher !== matcher)
+ originalMatcher.alias.push(matcher);
+ if (isRootAdd && record.name && !isAliasRecord(matcher)) {
+ removeRoute(record.name);
+ }
+ }
+ if (isMatchable(matcher)) {
+ insertMatcher(matcher);
+ }
+ if (mainNormalizedRecord.children) {
+ const children = mainNormalizedRecord.children;
+ for (let i = 0; i < children.length; i++) {
+ addRoute(children[i], matcher, originalRecord && originalRecord.children[i]);
+ }
+ }
+ originalRecord = originalRecord || matcher;
+ }
+ return originalMatcher ? () => {
+ removeRoute(originalMatcher);
+ } : noop$2;
+ }
+ function removeRoute(matcherRef) {
+ if (isRouteName(matcherRef)) {
+ const matcher = matcherMap.get(matcherRef);
+ if (matcher) {
+ matcherMap.delete(matcherRef);
+ matchers.splice(matchers.indexOf(matcher), 1);
+ matcher.children.forEach(removeRoute);
+ matcher.alias.forEach(removeRoute);
+ }
+ } else {
+ const index = matchers.indexOf(matcherRef);
+ if (index > -1) {
+ matchers.splice(index, 1);
+ if (matcherRef.record.name)
+ matcherMap.delete(matcherRef.record.name);
+ matcherRef.children.forEach(removeRoute);
+ matcherRef.alias.forEach(removeRoute);
+ }
+ }
+ }
+ function getRoutes() {
+ return matchers;
+ }
+ function insertMatcher(matcher) {
+ const index = findInsertionIndex(matcher, matchers);
+ matchers.splice(index, 0, matcher);
+ if (matcher.record.name && !isAliasRecord(matcher))
+ matcherMap.set(matcher.record.name, matcher);
+ }
+ function resolve2(location2, currentLocation) {
+ let matcher;
+ let params = {};
+ let path;
+ let name2;
+ if ("name" in location2 && location2.name) {
+ matcher = matcherMap.get(location2.name);
+ if (!matcher)
+ throw createRouterError(1, {
+ location: location2
+ });
+ name2 = matcher.record.name;
+ params = assign(
+ // paramsFromLocation is a new object
+ paramsFromLocation(
+ currentLocation.params,
+ // only keep params that exist in the resolved location
+ // only keep optional params coming from a parent record
+ matcher.keys.filter((k) => !k.optional).concat(matcher.parent ? matcher.parent.keys.filter((k) => k.optional) : []).map((k) => k.name)
+ ),
+ // discard any existing params in the current location that do not exist here
+ // #1497 this ensures better active/exact matching
+ location2.params && paramsFromLocation(location2.params, matcher.keys.map((k) => k.name))
+ );
+ path = matcher.stringify(params);
+ } else if (location2.path != null) {
+ path = location2.path;
+ matcher = matchers.find((m) => m.re.test(path));
+ if (matcher) {
+ params = matcher.parse(path);
+ name2 = matcher.record.name;
+ }
+ } else {
+ matcher = currentLocation.name ? matcherMap.get(currentLocation.name) : matchers.find((m) => m.re.test(currentLocation.path));
+ if (!matcher)
+ throw createRouterError(1, {
+ location: location2,
+ currentLocation
+ });
+ name2 = matcher.record.name;
+ params = assign({}, currentLocation.params, location2.params);
+ path = matcher.stringify(params);
+ }
+ const matched = [];
+ let parentMatcher = matcher;
+ while (parentMatcher) {
+ matched.unshift(parentMatcher.record);
+ parentMatcher = parentMatcher.parent;
+ }
+ return {
+ name: name2,
+ path,
+ params,
+ matched,
+ meta: mergeMetaFields(matched)
+ };
+ }
+ routes2.forEach((route) => addRoute(route));
+ function clearRoutes() {
+ matchers.length = 0;
+ matcherMap.clear();
+ }
+ return {
+ addRoute,
+ resolve: resolve2,
+ removeRoute,
+ clearRoutes,
+ getRoutes,
+ getRecordMatcher
+ };
+}
+function paramsFromLocation(params, keys) {
+ const newParams = {};
+ for (const key of keys) {
+ if (key in params)
+ newParams[key] = params[key];
+ }
+ return newParams;
+}
+function normalizeRouteRecord(record) {
+ const normalized = {
+ path: record.path,
+ redirect: record.redirect,
+ name: record.name,
+ meta: record.meta || {},
+ aliasOf: record.aliasOf,
+ beforeEnter: record.beforeEnter,
+ props: normalizeRecordProps(record),
+ children: record.children || [],
+ instances: {},
+ leaveGuards: /* @__PURE__ */ new Set(),
+ updateGuards: /* @__PURE__ */ new Set(),
+ enterCallbacks: {},
+ // must be declared afterwards
+ // mods: {},
+ components: "components" in record ? record.components || null : record.component && { default: record.component }
+ };
+ Object.defineProperty(normalized, "mods", {
+ value: {}
+ });
+ return normalized;
+}
+function normalizeRecordProps(record) {
+ const propsObject = {};
+ const props = record.props || false;
+ if ("component" in record) {
+ propsObject.default = props;
+ } else {
+ for (const name2 in record.components)
+ propsObject[name2] = typeof props === "object" ? props[name2] : props;
+ }
+ return propsObject;
+}
+function isAliasRecord(record) {
+ while (record) {
+ if (record.record.aliasOf)
+ return true;
+ record = record.parent;
+ }
+ return false;
+}
+function mergeMetaFields(matched) {
+ return matched.reduce((meta, record) => assign(meta, record.meta), {});
+}
+function mergeOptions(defaults2, partialOptions) {
+ const options = {};
+ for (const key in defaults2) {
+ options[key] = key in partialOptions ? partialOptions[key] : defaults2[key];
+ }
+ return options;
+}
+function findInsertionIndex(matcher, matchers) {
+ let lower = 0;
+ let upper = matchers.length;
+ while (lower !== upper) {
+ const mid = lower + upper >> 1;
+ const sortOrder = comparePathParserScore(matcher, matchers[mid]);
+ if (sortOrder < 0) {
+ upper = mid;
+ } else {
+ lower = mid + 1;
+ }
+ }
+ const insertionAncestor = getInsertionAncestor(matcher);
+ if (insertionAncestor) {
+ upper = matchers.lastIndexOf(insertionAncestor, upper - 1);
+ }
+ return upper;
+}
+function getInsertionAncestor(matcher) {
+ let ancestor = matcher;
+ while (ancestor = ancestor.parent) {
+ if (isMatchable(ancestor) && comparePathParserScore(matcher, ancestor) === 0) {
+ return ancestor;
+ }
+ }
+ return;
+}
+function isMatchable({ record }) {
+ return !!(record.name || record.components && Object.keys(record.components).length || record.redirect);
+}
+function parseQuery(search) {
+ const query = {};
+ if (search === "" || search === "?")
+ return query;
+ const hasLeadingIM = search[0] === "?";
+ const searchParams = (hasLeadingIM ? search.slice(1) : search).split("&");
+ for (let i = 0; i < searchParams.length; ++i) {
+ const searchParam = searchParams[i].replace(PLUS_RE, " ");
+ const eqPos = searchParam.indexOf("=");
+ const key = decode(eqPos < 0 ? searchParam : searchParam.slice(0, eqPos));
+ const value = eqPos < 0 ? null : decode(searchParam.slice(eqPos + 1));
+ if (key in query) {
+ let currentValue = query[key];
+ if (!isArray$2(currentValue)) {
+ currentValue = query[key] = [currentValue];
+ }
+ currentValue.push(value);
+ } else {
+ query[key] = value;
+ }
+ }
+ return query;
+}
+function stringifyQuery(query) {
+ let search = "";
+ for (let key in query) {
+ const value = query[key];
+ key = encodeQueryKey(key);
+ if (value == null) {
+ if (value !== void 0) {
+ search += (search.length ? "&" : "") + key;
+ }
+ continue;
+ }
+ const values = isArray$2(value) ? value.map((v) => v && encodeQueryValue(v)) : [value && encodeQueryValue(value)];
+ values.forEach((value2) => {
+ if (value2 !== void 0) {
+ search += (search.length ? "&" : "") + key;
+ if (value2 != null)
+ search += "=" + value2;
+ }
+ });
+ }
+ return search;
+}
+function normalizeQuery(query) {
+ const normalizedQuery = {};
+ for (const key in query) {
+ const value = query[key];
+ if (value !== void 0) {
+ normalizedQuery[key] = isArray$2(value) ? value.map((v) => v == null ? null : "" + v) : value == null ? value : "" + value;
+ }
+ }
+ return normalizedQuery;
+}
+const matchedRouteKey = Symbol("");
+const viewDepthKey = Symbol("");
+const routerKey = Symbol("");
+const routeLocationKey = Symbol("");
+const routerViewLocationKey = Symbol("");
+function useCallbacks() {
+ let handlers2 = [];
+ function add(handler) {
+ handlers2.push(handler);
+ return () => {
+ const i = handlers2.indexOf(handler);
+ if (i > -1)
+ handlers2.splice(i, 1);
+ };
+ }
+ function reset() {
+ handlers2 = [];
+ }
+ return {
+ add,
+ list: () => handlers2.slice(),
+ reset
+ };
+}
+function guardToPromiseFn(guard, to, from, record, name2, runWithContext = (fn) => fn()) {
+ const enterCallbackArray = record && // name is defined if record is because of the function overload
+ (record.enterCallbacks[name2] = record.enterCallbacks[name2] || []);
+ return () => new Promise((resolve2, reject) => {
+ const next = (valid) => {
+ if (valid === false) {
+ reject(createRouterError(4, {
+ from,
+ to
+ }));
+ } else if (valid instanceof Error) {
+ reject(valid);
+ } else if (isRouteLocation(valid)) {
+ reject(createRouterError(2, {
+ from: to,
+ to: valid
+ }));
+ } else {
+ if (enterCallbackArray && // since enterCallbackArray is truthy, both record and name also are
+ record.enterCallbacks[name2] === enterCallbackArray && typeof valid === "function") {
+ enterCallbackArray.push(valid);
+ }
+ resolve2();
+ }
+ };
+ const guardReturn = runWithContext(() => guard.call(record && record.instances[name2], to, from, next));
+ let guardCall = Promise.resolve(guardReturn);
+ if (guard.length < 3)
+ guardCall = guardCall.then(next);
+ guardCall.catch((err) => reject(err));
+ });
+}
+function extractComponentsGuards(matched, guardType, to, from, runWithContext = (fn) => fn()) {
+ const guards = [];
+ for (const record of matched) {
+ for (const name2 in record.components) {
+ let rawComponent = record.components[name2];
+ if (guardType !== "beforeRouteEnter" && !record.instances[name2])
+ continue;
+ if (isRouteComponent(rawComponent)) {
+ const options = rawComponent.__vccOpts || rawComponent;
+ const guard = options[guardType];
+ guard && guards.push(guardToPromiseFn(guard, to, from, record, name2, runWithContext));
+ } else {
+ let componentPromise = rawComponent();
+ guards.push(() => componentPromise.then((resolved) => {
+ if (!resolved)
+ throw new Error(`Couldn't resolve component "${name2}" at "${record.path}"`);
+ const resolvedComponent = isESModule(resolved) ? resolved.default : resolved;
+ record.mods[name2] = resolved;
+ record.components[name2] = resolvedComponent;
+ const options = resolvedComponent.__vccOpts || resolvedComponent;
+ const guard = options[guardType];
+ return guard && guardToPromiseFn(guard, to, from, record, name2, runWithContext)();
+ }));
+ }
+ }
+ }
+ return guards;
+}
+function useLink(props) {
+ const router2 = inject(routerKey);
+ const currentRoute = inject(routeLocationKey);
+ const route = computed(() => {
+ const to = unref(props.to);
+ return router2.resolve(to);
+ });
+ const activeRecordIndex = computed(() => {
+ const { matched } = route.value;
+ const { length } = matched;
+ const routeMatched = matched[length - 1];
+ const currentMatched = currentRoute.matched;
+ if (!routeMatched || !currentMatched.length)
+ return -1;
+ const index = currentMatched.findIndex(isSameRouteRecord.bind(null, routeMatched));
+ if (index > -1)
+ return index;
+ const parentRecordPath = getOriginalPath(matched[length - 2]);
+ return (
+ // we are dealing with nested routes
+ length > 1 && // if the parent and matched route have the same path, this link is
+ // referring to the empty child. Or we currently are on a different
+ // child of the same parent
+ getOriginalPath(routeMatched) === parentRecordPath && // avoid comparing the child with its parent
+ currentMatched[currentMatched.length - 1].path !== parentRecordPath ? currentMatched.findIndex(isSameRouteRecord.bind(null, matched[length - 2])) : index
+ );
+ });
+ const isActive = computed(() => activeRecordIndex.value > -1 && includesParams(currentRoute.params, route.value.params));
+ const isExactActive = computed(() => activeRecordIndex.value > -1 && activeRecordIndex.value === currentRoute.matched.length - 1 && isSameRouteLocationParams(currentRoute.params, route.value.params));
+ function navigate(e = {}) {
+ if (guardEvent(e)) {
+ const p2 = router2[unref(props.replace) ? "replace" : "push"](
+ unref(props.to)
+ // avoid uncaught errors are they are logged anyway
+ ).catch(noop$2);
+ if (props.viewTransition && typeof document !== "undefined" && "startViewTransition" in document) {
+ document.startViewTransition(() => p2);
+ }
+ return p2;
+ }
+ return Promise.resolve();
+ }
+ return {
+ route,
+ href: computed(() => route.value.href),
+ isActive,
+ isExactActive,
+ navigate
+ };
+}
+function preferSingleVNode(vnodes) {
+ return vnodes.length === 1 ? vnodes[0] : vnodes;
+}
+const RouterLinkImpl = /* @__PURE__ */ defineComponent({
+ name: "RouterLink",
+ compatConfig: { MODE: 3 },
+ props: {
+ to: {
+ type: [String, Object],
+ required: true
+ },
+ replace: Boolean,
+ activeClass: String,
+ // inactiveClass: String,
+ exactActiveClass: String,
+ custom: Boolean,
+ ariaCurrentValue: {
+ type: String,
+ default: "page"
+ }
+ },
+ useLink,
+ setup(props, { slots }) {
+ const link2 = reactive(useLink(props));
+ const { options } = inject(routerKey);
+ const elClass = computed(() => ({
+ [getLinkClass(props.activeClass, options.linkActiveClass, "router-link-active")]: link2.isActive,
+ // [getLinkClass(
+ // props.inactiveClass,
+ // options.linkInactiveClass,
+ // 'router-link-inactive'
+ // )]: !link.isExactActive,
+ [getLinkClass(props.exactActiveClass, options.linkExactActiveClass, "router-link-exact-active")]: link2.isExactActive
+ }));
+ return () => {
+ const children = slots.default && preferSingleVNode(slots.default(link2));
+ return props.custom ? children : h("a", {
+ "aria-current": link2.isExactActive ? props.ariaCurrentValue : null,
+ href: link2.href,
+ // this would override user added attrs but Vue will still add
+ // the listener, so we end up triggering both
+ onClick: link2.navigate,
+ class: elClass.value
+ }, children);
+ };
+ }
+});
+const RouterLink = RouterLinkImpl;
+function guardEvent(e) {
+ if (e.metaKey || e.altKey || e.ctrlKey || e.shiftKey)
+ return;
+ if (e.defaultPrevented)
+ return;
+ if (e.button !== void 0 && e.button !== 0)
+ return;
+ if (e.currentTarget && e.currentTarget.getAttribute) {
+ const target = e.currentTarget.getAttribute("target");
+ if (/\b_blank\b/i.test(target))
+ return;
+ }
+ if (e.preventDefault)
+ e.preventDefault();
+ return true;
+}
+function includesParams(outer, inner) {
+ for (const key in inner) {
+ const innerValue = inner[key];
+ const outerValue = outer[key];
+ if (typeof innerValue === "string") {
+ if (innerValue !== outerValue)
+ return false;
+ } else {
+ if (!isArray$2(outerValue) || outerValue.length !== innerValue.length || innerValue.some((value, i) => value !== outerValue[i]))
+ return false;
+ }
+ }
+ return true;
+}
+function getOriginalPath(record) {
+ return record ? record.aliasOf ? record.aliasOf.path : record.path : "";
+}
+const getLinkClass = (propClass, globalClass, defaultClass) => propClass != null ? propClass : globalClass != null ? globalClass : defaultClass;
+const RouterViewImpl = /* @__PURE__ */ defineComponent({
+ name: "RouterView",
+ // #674 we manually inherit them
+ inheritAttrs: false,
+ props: {
+ name: {
+ type: String,
+ default: "default"
+ },
+ route: Object
+ },
+ // Better compat for @vue/compat users
+ // https://github.com/vuejs/router/issues/1315
+ compatConfig: { MODE: 3 },
+ setup(props, { attrs, slots }) {
+ const injectedRoute = inject(routerViewLocationKey);
+ const routeToDisplay = computed(() => props.route || injectedRoute.value);
+ const injectedDepth = inject(viewDepthKey, 0);
+ const depth = computed(() => {
+ let initialDepth = unref(injectedDepth);
+ const { matched } = routeToDisplay.value;
+ let matchedRoute;
+ while ((matchedRoute = matched[initialDepth]) && !matchedRoute.components) {
+ initialDepth++;
+ }
+ return initialDepth;
+ });
+ const matchedRouteRef = computed(() => routeToDisplay.value.matched[depth.value]);
+ provide(viewDepthKey, computed(() => depth.value + 1));
+ provide(matchedRouteKey, matchedRouteRef);
+ provide(routerViewLocationKey, routeToDisplay);
+ const viewRef = ref();
+ watch(() => [viewRef.value, matchedRouteRef.value, props.name], ([instance, to, name2], [oldInstance, from, oldName]) => {
+ if (to) {
+ to.instances[name2] = instance;
+ if (from && from !== to && instance && instance === oldInstance) {
+ if (!to.leaveGuards.size) {
+ to.leaveGuards = from.leaveGuards;
+ }
+ if (!to.updateGuards.size) {
+ to.updateGuards = from.updateGuards;
+ }
+ }
+ }
+ if (instance && to && // if there is no instance but to and from are the same this might be
+ // the first visit
+ (!from || !isSameRouteRecord(to, from) || !oldInstance)) {
+ (to.enterCallbacks[name2] || []).forEach((callback) => callback(instance));
+ }
+ }, { flush: "post" });
+ return () => {
+ const route = routeToDisplay.value;
+ const currentName = props.name;
+ const matchedRoute = matchedRouteRef.value;
+ const ViewComponent = matchedRoute && matchedRoute.components[currentName];
+ if (!ViewComponent) {
+ return normalizeSlot(slots.default, { Component: ViewComponent, route });
+ }
+ const routePropsOption = matchedRoute.props[currentName];
+ const routeProps = routePropsOption ? routePropsOption === true ? route.params : typeof routePropsOption === "function" ? routePropsOption(route) : routePropsOption : null;
+ const onVnodeUnmounted = (vnode2) => {
+ if (vnode2.component.isUnmounted) {
+ matchedRoute.instances[currentName] = null;
+ }
+ };
+ const component = h(ViewComponent, assign({}, routeProps, attrs, {
+ onVnodeUnmounted,
+ ref: viewRef
+ }));
+ return (
+ // pass the vnode to the slot as a prop.
+ // h and both accept vnodes
+ normalizeSlot(slots.default, { Component: component, route }) || component
+ );
+ };
+ }
+});
+function normalizeSlot(slot, data) {
+ if (!slot)
+ return null;
+ const slotContent = slot(data);
+ return slotContent.length === 1 ? slotContent[0] : slotContent;
+}
+const RouterView = RouterViewImpl;
+function createRouter(options) {
+ const matcher = createRouterMatcher(options.routes, options);
+ const parseQuery$1 = options.parseQuery || parseQuery;
+ const stringifyQuery$1 = options.stringifyQuery || stringifyQuery;
+ const routerHistory = options.history;
+ const beforeGuards = useCallbacks();
+ const beforeResolveGuards = useCallbacks();
+ const afterGuards = useCallbacks();
+ const currentRoute = shallowRef(START_LOCATION_NORMALIZED);
+ let pendingLocation = START_LOCATION_NORMALIZED;
+ if (isBrowser$3 && options.scrollBehavior && "scrollRestoration" in history) {
+ history.scrollRestoration = "manual";
+ }
+ const normalizeParams = applyToParams.bind(null, (paramValue) => "" + paramValue);
+ const encodeParams = applyToParams.bind(null, encodeParam);
+ const decodeParams = (
+ // @ts-expect-error: intentionally avoid the type check
+ applyToParams.bind(null, decode)
+ );
+ function addRoute(parentOrRoute, route) {
+ let parent;
+ let record;
+ if (isRouteName(parentOrRoute)) {
+ parent = matcher.getRecordMatcher(parentOrRoute);
+ record = route;
+ } else {
+ record = parentOrRoute;
+ }
+ return matcher.addRoute(record, parent);
+ }
+ function removeRoute(name2) {
+ const recordMatcher = matcher.getRecordMatcher(name2);
+ if (recordMatcher) {
+ matcher.removeRoute(recordMatcher);
+ }
+ }
+ function getRoutes() {
+ return matcher.getRoutes().map((routeMatcher) => routeMatcher.record);
+ }
+ function hasRoute(name2) {
+ return !!matcher.getRecordMatcher(name2);
+ }
+ function resolve2(rawLocation, currentLocation) {
+ currentLocation = assign({}, currentLocation || currentRoute.value);
+ if (typeof rawLocation === "string") {
+ const locationNormalized = parseURL(parseQuery$1, rawLocation, currentLocation.path);
+ const matchedRoute2 = matcher.resolve({ path: locationNormalized.path }, currentLocation);
+ const href2 = routerHistory.createHref(locationNormalized.fullPath);
+ return assign(locationNormalized, matchedRoute2, {
+ params: decodeParams(matchedRoute2.params),
+ hash: decode(locationNormalized.hash),
+ redirectedFrom: void 0,
+ href: href2
+ });
+ }
+ let matcherLocation;
+ if (rawLocation.path != null) {
+ matcherLocation = assign({}, rawLocation, {
+ path: parseURL(parseQuery$1, rawLocation.path, currentLocation.path).path
+ });
+ } else {
+ const targetParams = assign({}, rawLocation.params);
+ for (const key in targetParams) {
+ if (targetParams[key] == null) {
+ delete targetParams[key];
+ }
+ }
+ matcherLocation = assign({}, rawLocation, {
+ params: encodeParams(targetParams)
+ });
+ currentLocation.params = encodeParams(currentLocation.params);
+ }
+ const matchedRoute = matcher.resolve(matcherLocation, currentLocation);
+ const hash = rawLocation.hash || "";
+ matchedRoute.params = normalizeParams(decodeParams(matchedRoute.params));
+ const fullPath = stringifyURL(stringifyQuery$1, assign({}, rawLocation, {
+ hash: encodeHash(hash),
+ path: matchedRoute.path
+ }));
+ const href = routerHistory.createHref(fullPath);
+ return assign({
+ fullPath,
+ // keep the hash encoded so fullPath is effectively path + encodedQuery +
+ // hash
+ hash,
+ query: (
+ // if the user is using a custom query lib like qs, we might have
+ // nested objects, so we keep the query as is, meaning it can contain
+ // numbers at `$route.query`, but at the point, the user will have to
+ // use their own type anyway.
+ // https://github.com/vuejs/router/issues/328#issuecomment-649481567
+ stringifyQuery$1 === stringifyQuery ? normalizeQuery(rawLocation.query) : rawLocation.query || {}
+ )
+ }, matchedRoute, {
+ redirectedFrom: void 0,
+ href
+ });
+ }
+ function locationAsObject(to) {
+ return typeof to === "string" ? parseURL(parseQuery$1, to, currentRoute.value.path) : assign({}, to);
+ }
+ function checkCanceledNavigation(to, from) {
+ if (pendingLocation !== to) {
+ return createRouterError(8, {
+ from,
+ to
+ });
+ }
+ }
+ function push(to) {
+ return pushWithRedirect(to);
+ }
+ function replace(to) {
+ return push(assign(locationAsObject(to), { replace: true }));
+ }
+ function handleRedirectRecord(to) {
+ const lastMatched = to.matched[to.matched.length - 1];
+ if (lastMatched && lastMatched.redirect) {
+ const { redirect } = lastMatched;
+ let newTargetLocation = typeof redirect === "function" ? redirect(to) : redirect;
+ if (typeof newTargetLocation === "string") {
+ newTargetLocation = newTargetLocation.includes("?") || newTargetLocation.includes("#") ? newTargetLocation = locationAsObject(newTargetLocation) : (
+ // force empty params
+ { path: newTargetLocation }
+ );
+ newTargetLocation.params = {};
+ }
+ return assign({
+ query: to.query,
+ hash: to.hash,
+ // avoid transferring params if the redirect has a path
+ params: newTargetLocation.path != null ? {} : to.params
+ }, newTargetLocation);
+ }
+ }
+ function pushWithRedirect(to, redirectedFrom) {
+ const targetLocation = pendingLocation = resolve2(to);
+ const from = currentRoute.value;
+ const data = to.state;
+ const force = to.force;
+ const replace2 = to.replace === true;
+ const shouldRedirect = handleRedirectRecord(targetLocation);
+ if (shouldRedirect)
+ return pushWithRedirect(
+ assign(locationAsObject(shouldRedirect), {
+ state: typeof shouldRedirect === "object" ? assign({}, data, shouldRedirect.state) : data,
+ force,
+ replace: replace2
+ }),
+ // keep original redirectedFrom if it exists
+ redirectedFrom || targetLocation
+ );
+ const toLocation = targetLocation;
+ toLocation.redirectedFrom = redirectedFrom;
+ let failure;
+ if (!force && isSameRouteLocation(stringifyQuery$1, from, targetLocation)) {
+ failure = createRouterError(16, { to: toLocation, from });
+ handleScroll(
+ from,
+ from,
+ // this is a push, the only way for it to be triggered from a
+ // history.listen is with a redirect, which makes it become a push
+ true,
+ // This cannot be the first navigation because the initial location
+ // cannot be manually navigated to
+ false
+ );
+ }
+ return (failure ? Promise.resolve(failure) : navigate(toLocation, from)).catch((error) => isNavigationFailure(error) ? (
+ // navigation redirects still mark the router as ready
+ isNavigationFailure(
+ error,
+ 2
+ /* ErrorTypes.NAVIGATION_GUARD_REDIRECT */
+ ) ? error : markAsReady(error)
+ ) : (
+ // reject any unknown error
+ triggerError(error, toLocation, from)
+ )).then((failure2) => {
+ if (failure2) {
+ if (isNavigationFailure(
+ failure2,
+ 2
+ /* ErrorTypes.NAVIGATION_GUARD_REDIRECT */
+ )) {
+ return pushWithRedirect(
+ // keep options
+ assign({
+ // preserve an existing replacement but allow the redirect to override it
+ replace: replace2
+ }, locationAsObject(failure2.to), {
+ state: typeof failure2.to === "object" ? assign({}, data, failure2.to.state) : data,
+ force
+ }),
+ // preserve the original redirectedFrom if any
+ redirectedFrom || toLocation
+ );
+ }
+ } else {
+ failure2 = finalizeNavigation(toLocation, from, true, replace2, data);
+ }
+ triggerAfterEach(toLocation, from, failure2);
+ return failure2;
+ });
+ }
+ function checkCanceledNavigationAndReject(to, from) {
+ const error = checkCanceledNavigation(to, from);
+ return error ? Promise.reject(error) : Promise.resolve();
+ }
+ function runWithContext(fn) {
+ const app2 = installedApps.values().next().value;
+ return app2 && typeof app2.runWithContext === "function" ? app2.runWithContext(fn) : fn();
+ }
+ function navigate(to, from) {
+ let guards;
+ const [leavingRecords, updatingRecords, enteringRecords] = extractChangingRecords(to, from);
+ guards = extractComponentsGuards(leavingRecords.reverse(), "beforeRouteLeave", to, from);
+ for (const record of leavingRecords) {
+ record.leaveGuards.forEach((guard) => {
+ guards.push(guardToPromiseFn(guard, to, from));
+ });
+ }
+ const canceledNavigationCheck = checkCanceledNavigationAndReject.bind(null, to, from);
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards).then(() => {
+ guards = [];
+ for (const guard of beforeGuards.list()) {
+ guards.push(guardToPromiseFn(guard, to, from));
+ }
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards);
+ }).then(() => {
+ guards = extractComponentsGuards(updatingRecords, "beforeRouteUpdate", to, from);
+ for (const record of updatingRecords) {
+ record.updateGuards.forEach((guard) => {
+ guards.push(guardToPromiseFn(guard, to, from));
+ });
+ }
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards);
+ }).then(() => {
+ guards = [];
+ for (const record of enteringRecords) {
+ if (record.beforeEnter) {
+ if (isArray$2(record.beforeEnter)) {
+ for (const beforeEnter of record.beforeEnter)
+ guards.push(guardToPromiseFn(beforeEnter, to, from));
+ } else {
+ guards.push(guardToPromiseFn(record.beforeEnter, to, from));
+ }
+ }
+ }
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards);
+ }).then(() => {
+ to.matched.forEach((record) => record.enterCallbacks = {});
+ guards = extractComponentsGuards(enteringRecords, "beforeRouteEnter", to, from, runWithContext);
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards);
+ }).then(() => {
+ guards = [];
+ for (const guard of beforeResolveGuards.list()) {
+ guards.push(guardToPromiseFn(guard, to, from));
+ }
+ guards.push(canceledNavigationCheck);
+ return runGuardQueue(guards);
+ }).catch((err) => isNavigationFailure(
+ err,
+ 8
+ /* ErrorTypes.NAVIGATION_CANCELLED */
+ ) ? err : Promise.reject(err));
+ }
+ function triggerAfterEach(to, from, failure) {
+ afterGuards.list().forEach((guard) => runWithContext(() => guard(to, from, failure)));
+ }
+ function finalizeNavigation(toLocation, from, isPush, replace2, data) {
+ const error = checkCanceledNavigation(toLocation, from);
+ if (error)
+ return error;
+ const isFirstNavigation = from === START_LOCATION_NORMALIZED;
+ const state2 = !isBrowser$3 ? {} : history.state;
+ if (isPush) {
+ if (replace2 || isFirstNavigation)
+ routerHistory.replace(toLocation.fullPath, assign({
+ scroll: isFirstNavigation && state2 && state2.scroll
+ }, data));
+ else
+ routerHistory.push(toLocation.fullPath, data);
+ }
+ currentRoute.value = toLocation;
+ handleScroll(toLocation, from, isPush, isFirstNavigation);
+ markAsReady();
+ }
+ let removeHistoryListener;
+ function setupListeners() {
+ if (removeHistoryListener)
+ return;
+ removeHistoryListener = routerHistory.listen((to, _from, info) => {
+ if (!router2.listening)
+ return;
+ const toLocation = resolve2(to);
+ const shouldRedirect = handleRedirectRecord(toLocation);
+ if (shouldRedirect) {
+ pushWithRedirect(assign(shouldRedirect, { replace: true, force: true }), toLocation).catch(noop$2);
+ return;
+ }
+ pendingLocation = toLocation;
+ const from = currentRoute.value;
+ if (isBrowser$3) {
+ saveScrollPosition(getScrollKey(from.fullPath, info.delta), computeScrollPosition());
+ }
+ navigate(toLocation, from).catch((error) => {
+ if (isNavigationFailure(
+ error,
+ 4 | 8
+ /* ErrorTypes.NAVIGATION_CANCELLED */
+ )) {
+ return error;
+ }
+ if (isNavigationFailure(
+ error,
+ 2
+ /* ErrorTypes.NAVIGATION_GUARD_REDIRECT */
+ )) {
+ pushWithRedirect(
+ assign(locationAsObject(error.to), {
+ force: true
+ }),
+ toLocation
+ // avoid an uncaught rejection, let push call triggerError
+ ).then((failure) => {
+ if (isNavigationFailure(
+ failure,
+ 4 | 16
+ /* ErrorTypes.NAVIGATION_DUPLICATED */
+ ) && !info.delta && info.type === NavigationType.pop) {
+ routerHistory.go(-1, false);
+ }
+ }).catch(noop$2);
+ return Promise.reject();
+ }
+ if (info.delta) {
+ routerHistory.go(-info.delta, false);
+ }
+ return triggerError(error, toLocation, from);
+ }).then((failure) => {
+ failure = failure || finalizeNavigation(
+ // after navigation, all matched components are resolved
+ toLocation,
+ from,
+ false
+ );
+ if (failure) {
+ if (info.delta && // a new navigation has been triggered, so we do not want to revert, that will change the current history
+ // entry while a different route is displayed
+ !isNavigationFailure(
+ failure,
+ 8
+ /* ErrorTypes.NAVIGATION_CANCELLED */
+ )) {
+ routerHistory.go(-info.delta, false);
+ } else if (info.type === NavigationType.pop && isNavigationFailure(
+ failure,
+ 4 | 16
+ /* ErrorTypes.NAVIGATION_DUPLICATED */
+ )) {
+ routerHistory.go(-1, false);
+ }
+ }
+ triggerAfterEach(toLocation, from, failure);
+ }).catch(noop$2);
+ });
+ }
+ let readyHandlers = useCallbacks();
+ let errorListeners = useCallbacks();
+ let ready;
+ function triggerError(error, to, from) {
+ markAsReady(error);
+ const list2 = errorListeners.list();
+ if (list2.length) {
+ list2.forEach((handler) => handler(error, to, from));
+ } else {
+ console.error(error);
+ }
+ return Promise.reject(error);
+ }
+ function isReady() {
+ if (ready && currentRoute.value !== START_LOCATION_NORMALIZED)
+ return Promise.resolve();
+ return new Promise((resolve22, reject) => {
+ readyHandlers.add([resolve22, reject]);
+ });
+ }
+ function markAsReady(err) {
+ if (!ready) {
+ ready = !err;
+ setupListeners();
+ readyHandlers.list().forEach(([resolve22, reject]) => err ? reject(err) : resolve22());
+ readyHandlers.reset();
+ }
+ return err;
+ }
+ function handleScroll(to, from, isPush, isFirstNavigation) {
+ const { scrollBehavior } = options;
+ if (!isBrowser$3 || !scrollBehavior)
+ return Promise.resolve();
+ const scrollPosition = !isPush && getSavedScrollPosition(getScrollKey(to.fullPath, 0)) || (isFirstNavigation || !isPush) && history.state && history.state.scroll || null;
+ return nextTick().then(() => scrollBehavior(to, from, scrollPosition)).then((position) => position && scrollToPosition(position)).catch((err) => triggerError(err, to, from));
+ }
+ const go = (delta) => routerHistory.go(delta);
+ let started;
+ const installedApps = /* @__PURE__ */ new Set();
+ const router2 = {
+ currentRoute,
+ listening: true,
+ addRoute,
+ removeRoute,
+ clearRoutes: matcher.clearRoutes,
+ hasRoute,
+ getRoutes,
+ resolve: resolve2,
+ options,
+ push,
+ replace,
+ go,
+ back: () => go(-1),
+ forward: () => go(1),
+ beforeEach: beforeGuards.add,
+ beforeResolve: beforeResolveGuards.add,
+ afterEach: afterGuards.add,
+ onError: errorListeners.add,
+ isReady,
+ install(app2) {
+ const router22 = this;
+ app2.component("RouterLink", RouterLink);
+ app2.component("RouterView", RouterView);
+ app2.config.globalProperties.$router = router22;
+ Object.defineProperty(app2.config.globalProperties, "$route", {
+ enumerable: true,
+ get: () => unref(currentRoute)
+ });
+ if (isBrowser$3 && // used for the initial navigation client side to avoid pushing
+ // multiple times when the router is used in multiple apps
+ !started && currentRoute.value === START_LOCATION_NORMALIZED) {
+ started = true;
+ push(routerHistory.location).catch((err) => {
+ });
+ }
+ const reactiveRoute = {};
+ for (const key in START_LOCATION_NORMALIZED) {
+ Object.defineProperty(reactiveRoute, key, {
+ get: () => currentRoute.value[key],
+ enumerable: true
+ });
+ }
+ app2.provide(routerKey, router22);
+ app2.provide(routeLocationKey, shallowReactive(reactiveRoute));
+ app2.provide(routerViewLocationKey, currentRoute);
+ const unmountApp = app2.unmount;
+ installedApps.add(app2);
+ app2.unmount = function() {
+ installedApps.delete(app2);
+ if (installedApps.size < 1) {
+ pendingLocation = START_LOCATION_NORMALIZED;
+ removeHistoryListener && removeHistoryListener();
+ removeHistoryListener = null;
+ currentRoute.value = START_LOCATION_NORMALIZED;
+ started = false;
+ ready = false;
+ }
+ unmountApp();
+ };
+ }
+ };
+ function runGuardQueue(guards) {
+ return guards.reduce((promise, guard) => promise.then(() => runWithContext(guard)), Promise.resolve());
+ }
+ return router2;
+}
+function extractChangingRecords(to, from) {
+ const leavingRecords = [];
+ const updatingRecords = [];
+ const enteringRecords = [];
+ const len = Math.max(from.matched.length, to.matched.length);
+ for (let i = 0; i < len; i++) {
+ const recordFrom = from.matched[i];
+ if (recordFrom) {
+ if (to.matched.find((record) => isSameRouteRecord(record, recordFrom)))
+ updatingRecords.push(recordFrom);
+ else
+ leavingRecords.push(recordFrom);
+ }
+ const recordTo = to.matched[i];
+ if (recordTo) {
+ if (!from.matched.find((record) => isSameRouteRecord(record, recordTo))) {
+ enteringRecords.push(recordTo);
+ }
+ }
+ }
+ return [leavingRecords, updatingRecords, enteringRecords];
+}
+function useRouter() {
+ return inject(routerKey);
+}
+function useRoute(_name) {
+ return inject(routeLocationKey);
+}
+/*!
+ * vuex v4.1.0
+ * (c) 2022 Evan You
+ * @license MIT
+ */
+var storeKey = "store";
+function useStore(key) {
+ if (key === void 0) key = null;
+ return inject(key !== null ? key : storeKey);
+}
+function forEachValue(obj, fn) {
+ Object.keys(obj).forEach(function(key) {
+ return fn(obj[key], key);
+ });
+}
+function isObject$3(obj) {
+ return obj !== null && typeof obj === "object";
+}
+function isPromise(val) {
+ return val && typeof val.then === "function";
+}
+function partial(fn, arg) {
+ return function() {
+ return fn(arg);
+ };
+}
+function genericSubscribe(fn, subs, options) {
+ if (subs.indexOf(fn) < 0) {
+ options && options.prepend ? subs.unshift(fn) : subs.push(fn);
+ }
+ return function() {
+ var i = subs.indexOf(fn);
+ if (i > -1) {
+ subs.splice(i, 1);
+ }
+ };
+}
+function resetStore(store2, hot) {
+ store2._actions = /* @__PURE__ */ Object.create(null);
+ store2._mutations = /* @__PURE__ */ Object.create(null);
+ store2._wrappedGetters = /* @__PURE__ */ Object.create(null);
+ store2._modulesNamespaceMap = /* @__PURE__ */ Object.create(null);
+ var state2 = store2.state;
+ installModule(store2, state2, [], store2._modules.root, true);
+ resetStoreState(store2, state2, hot);
+}
+function resetStoreState(store2, state2, hot) {
+ var oldState = store2._state;
+ var oldScope = store2._scope;
+ store2.getters = {};
+ store2._makeLocalGettersCache = /* @__PURE__ */ Object.create(null);
+ var wrappedGetters = store2._wrappedGetters;
+ var computedObj = {};
+ var computedCache = {};
+ var scope = effectScope(true);
+ scope.run(function() {
+ forEachValue(wrappedGetters, function(fn, key) {
+ computedObj[key] = partial(fn, store2);
+ computedCache[key] = computed(function() {
+ return computedObj[key]();
+ });
+ Object.defineProperty(store2.getters, key, {
+ get: function() {
+ return computedCache[key].value;
+ },
+ enumerable: true
+ // for local getters
+ });
+ });
+ });
+ store2._state = reactive({
+ data: state2
+ });
+ store2._scope = scope;
+ if (store2.strict) {
+ enableStrictMode(store2);
+ }
+ if (oldState) {
+ if (hot) {
+ store2._withCommit(function() {
+ oldState.data = null;
+ });
+ }
+ }
+ if (oldScope) {
+ oldScope.stop();
+ }
+}
+function installModule(store2, rootState, path, module2, hot) {
+ var isRoot = !path.length;
+ var namespace2 = store2._modules.getNamespace(path);
+ if (module2.namespaced) {
+ if (store2._modulesNamespaceMap[namespace2] && false) ;
+ store2._modulesNamespaceMap[namespace2] = module2;
+ }
+ if (!isRoot && !hot) {
+ var parentState = getNestedState(rootState, path.slice(0, -1));
+ var moduleName = path[path.length - 1];
+ store2._withCommit(function() {
+ parentState[moduleName] = module2.state;
+ });
+ }
+ var local = module2.context = makeLocalContext(store2, namespace2, path);
+ module2.forEachMutation(function(mutation, key) {
+ var namespacedType = namespace2 + key;
+ registerMutation(store2, namespacedType, mutation, local);
+ });
+ module2.forEachAction(function(action, key) {
+ var type = action.root ? key : namespace2 + key;
+ var handler = action.handler || action;
+ registerAction(store2, type, handler, local);
+ });
+ module2.forEachGetter(function(getter, key) {
+ var namespacedType = namespace2 + key;
+ registerGetter(store2, namespacedType, getter, local);
+ });
+ module2.forEachChild(function(child, key) {
+ installModule(store2, rootState, path.concat(key), child, hot);
+ });
+}
+function makeLocalContext(store2, namespace2, path) {
+ var noNamespace = namespace2 === "";
+ var local = {
+ dispatch: noNamespace ? store2.dispatch : function(_type, _payload, _options) {
+ var args = unifyObjectStyle(_type, _payload, _options);
+ var payload = args.payload;
+ var options = args.options;
+ var type = args.type;
+ if (!options || !options.root) {
+ type = namespace2 + type;
+ }
+ return store2.dispatch(type, payload);
+ },
+ commit: noNamespace ? store2.commit : function(_type, _payload, _options) {
+ var args = unifyObjectStyle(_type, _payload, _options);
+ var payload = args.payload;
+ var options = args.options;
+ var type = args.type;
+ if (!options || !options.root) {
+ type = namespace2 + type;
+ }
+ store2.commit(type, payload, options);
+ }
+ };
+ Object.defineProperties(local, {
+ getters: {
+ get: noNamespace ? function() {
+ return store2.getters;
+ } : function() {
+ return makeLocalGetters(store2, namespace2);
+ }
+ },
+ state: {
+ get: function() {
+ return getNestedState(store2.state, path);
+ }
+ }
+ });
+ return local;
+}
+function makeLocalGetters(store2, namespace2) {
+ if (!store2._makeLocalGettersCache[namespace2]) {
+ var gettersProxy = {};
+ var splitPos = namespace2.length;
+ Object.keys(store2.getters).forEach(function(type) {
+ if (type.slice(0, splitPos) !== namespace2) {
+ return;
+ }
+ var localType = type.slice(splitPos);
+ Object.defineProperty(gettersProxy, localType, {
+ get: function() {
+ return store2.getters[type];
+ },
+ enumerable: true
+ });
+ });
+ store2._makeLocalGettersCache[namespace2] = gettersProxy;
+ }
+ return store2._makeLocalGettersCache[namespace2];
+}
+function registerMutation(store2, type, handler, local) {
+ var entry = store2._mutations[type] || (store2._mutations[type] = []);
+ entry.push(function wrappedMutationHandler(payload) {
+ handler.call(store2, local.state, payload);
+ });
+}
+function registerAction(store2, type, handler, local) {
+ var entry = store2._actions[type] || (store2._actions[type] = []);
+ entry.push(function wrappedActionHandler(payload) {
+ var res = handler.call(store2, {
+ dispatch: local.dispatch,
+ commit: local.commit,
+ getters: local.getters,
+ state: local.state,
+ rootGetters: store2.getters,
+ rootState: store2.state
+ }, payload);
+ if (!isPromise(res)) {
+ res = Promise.resolve(res);
+ }
+ if (store2._devtoolHook) {
+ return res.catch(function(err) {
+ store2._devtoolHook.emit("vuex:error", err);
+ throw err;
+ });
+ } else {
+ return res;
+ }
+ });
+}
+function registerGetter(store2, type, rawGetter, local) {
+ if (store2._wrappedGetters[type]) {
+ return;
+ }
+ store2._wrappedGetters[type] = function wrappedGetter(store22) {
+ return rawGetter(
+ local.state,
+ // local state
+ local.getters,
+ // local getters
+ store22.state,
+ // root state
+ store22.getters
+ // root getters
+ );
+ };
+}
+function enableStrictMode(store2) {
+ watch(function() {
+ return store2._state.data;
+ }, function() {
+ }, { deep: true, flush: "sync" });
+}
+function getNestedState(state2, path) {
+ return path.reduce(function(state22, key) {
+ return state22[key];
+ }, state2);
+}
+function unifyObjectStyle(type, payload, options) {
+ if (isObject$3(type) && type.type) {
+ options = payload;
+ payload = type;
+ type = type.type;
+ }
+ return { type, payload, options };
+}
+var LABEL_VUEX_BINDINGS = "vuex bindings";
+var MUTATIONS_LAYER_ID = "vuex:mutations";
+var ACTIONS_LAYER_ID = "vuex:actions";
+var INSPECTOR_ID = "vuex";
+var actionId = 0;
+function addDevtools(app2, store2) {
+ setupDevtoolsPlugin(
+ {
+ id: "org.vuejs.vuex",
+ app: app2,
+ label: "Vuex",
+ homepage: "https://next.vuex.vuejs.org/",
+ logo: "https://vuejs.org/images/icons/favicon-96x96.png",
+ packageName: "vuex",
+ componentStateTypes: [LABEL_VUEX_BINDINGS]
+ },
+ function(api) {
+ api.addTimelineLayer({
+ id: MUTATIONS_LAYER_ID,
+ label: "Vuex Mutations",
+ color: COLOR_LIME_500
+ });
+ api.addTimelineLayer({
+ id: ACTIONS_LAYER_ID,
+ label: "Vuex Actions",
+ color: COLOR_LIME_500
+ });
+ api.addInspector({
+ id: INSPECTOR_ID,
+ label: "Vuex",
+ icon: "storage",
+ treeFilterPlaceholder: "Filter stores..."
+ });
+ api.on.getInspectorTree(function(payload) {
+ if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) {
+ if (payload.filter) {
+ var nodes = [];
+ flattenStoreForInspectorTree(nodes, store2._modules.root, payload.filter, "");
+ payload.rootNodes = nodes;
+ } else {
+ payload.rootNodes = [
+ formatStoreForInspectorTree(store2._modules.root, "")
+ ];
+ }
+ }
+ });
+ api.on.getInspectorState(function(payload) {
+ if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) {
+ var modulePath = payload.nodeId;
+ makeLocalGetters(store2, modulePath);
+ payload.state = formatStoreForInspectorState(
+ getStoreModule(store2._modules, modulePath),
+ modulePath === "root" ? store2.getters : store2._makeLocalGettersCache,
+ modulePath
+ );
+ }
+ });
+ api.on.editInspectorState(function(payload) {
+ if (payload.app === app2 && payload.inspectorId === INSPECTOR_ID) {
+ var modulePath = payload.nodeId;
+ var path = payload.path;
+ if (modulePath !== "root") {
+ path = modulePath.split("/").filter(Boolean).concat(path);
+ }
+ store2._withCommit(function() {
+ payload.set(store2._state.data, path, payload.state.value);
+ });
+ }
+ });
+ store2.subscribe(function(mutation, state2) {
+ var data = {};
+ if (mutation.payload) {
+ data.payload = mutation.payload;
+ }
+ data.state = state2;
+ api.notifyComponentUpdate();
+ api.sendInspectorTree(INSPECTOR_ID);
+ api.sendInspectorState(INSPECTOR_ID);
+ api.addTimelineEvent({
+ layerId: MUTATIONS_LAYER_ID,
+ event: {
+ time: Date.now(),
+ title: mutation.type,
+ data
+ }
+ });
+ });
+ store2.subscribeAction({
+ before: function(action, state2) {
+ var data = {};
+ if (action.payload) {
+ data.payload = action.payload;
+ }
+ action._id = actionId++;
+ action._time = Date.now();
+ data.state = state2;
+ api.addTimelineEvent({
+ layerId: ACTIONS_LAYER_ID,
+ event: {
+ time: action._time,
+ title: action.type,
+ groupId: action._id,
+ subtitle: "start",
+ data
+ }
+ });
+ },
+ after: function(action, state2) {
+ var data = {};
+ var duration2 = Date.now() - action._time;
+ data.duration = {
+ _custom: {
+ type: "duration",
+ display: duration2 + "ms",
+ tooltip: "Action duration",
+ value: duration2
+ }
+ };
+ if (action.payload) {
+ data.payload = action.payload;
+ }
+ data.state = state2;
+ api.addTimelineEvent({
+ layerId: ACTIONS_LAYER_ID,
+ event: {
+ time: Date.now(),
+ title: action.type,
+ groupId: action._id,
+ subtitle: "end",
+ data
+ }
+ });
+ }
+ });
+ }
+ );
+}
+var COLOR_LIME_500 = 8702998;
+var COLOR_DARK = 6710886;
+var COLOR_WHITE = 16777215;
+var TAG_NAMESPACED = {
+ label: "namespaced",
+ textColor: COLOR_WHITE,
+ backgroundColor: COLOR_DARK
+};
+function extractNameFromPath(path) {
+ return path && path !== "root" ? path.split("/").slice(-2, -1)[0] : "Root";
+}
+function formatStoreForInspectorTree(module2, path) {
+ return {
+ id: path || "root",
+ // all modules end with a `/`, we want the last segment only
+ // cart/ -> cart
+ // nested/cart/ -> cart
+ label: extractNameFromPath(path),
+ tags: module2.namespaced ? [TAG_NAMESPACED] : [],
+ children: Object.keys(module2._children).map(
+ function(moduleName) {
+ return formatStoreForInspectorTree(
+ module2._children[moduleName],
+ path + moduleName + "/"
+ );
+ }
+ )
+ };
+}
+function flattenStoreForInspectorTree(result, module2, filter2, path) {
+ if (path.includes(filter2)) {
+ result.push({
+ id: path || "root",
+ label: path.endsWith("/") ? path.slice(0, path.length - 1) : path || "Root",
+ tags: module2.namespaced ? [TAG_NAMESPACED] : []
+ });
+ }
+ Object.keys(module2._children).forEach(function(moduleName) {
+ flattenStoreForInspectorTree(result, module2._children[moduleName], filter2, path + moduleName + "/");
+ });
+}
+function formatStoreForInspectorState(module2, getters, path) {
+ getters = path === "root" ? getters : getters[path];
+ var gettersKeys = Object.keys(getters);
+ var storeState = {
+ state: Object.keys(module2.state).map(function(key) {
+ return {
+ key,
+ editable: true,
+ value: module2.state[key]
+ };
+ })
+ };
+ if (gettersKeys.length) {
+ var tree = transformPathsToObjectTree(getters);
+ storeState.getters = Object.keys(tree).map(function(key) {
+ return {
+ key: key.endsWith("/") ? extractNameFromPath(key) : key,
+ editable: false,
+ value: canThrow(function() {
+ return tree[key];
+ })
+ };
+ });
+ }
+ return storeState;
+}
+function transformPathsToObjectTree(getters) {
+ var result = {};
+ Object.keys(getters).forEach(function(key) {
+ var path = key.split("/");
+ if (path.length > 1) {
+ var target = result;
+ var leafKey = path.pop();
+ path.forEach(function(p2) {
+ if (!target[p2]) {
+ target[p2] = {
+ _custom: {
+ value: {},
+ display: p2,
+ tooltip: "Module",
+ abstract: true
+ }
+ };
+ }
+ target = target[p2]._custom.value;
+ });
+ target[leafKey] = canThrow(function() {
+ return getters[key];
+ });
+ } else {
+ result[key] = canThrow(function() {
+ return getters[key];
+ });
+ }
+ });
+ return result;
+}
+function getStoreModule(moduleMap, path) {
+ var names = path.split("/").filter(function(n) {
+ return n;
+ });
+ return names.reduce(
+ function(module2, moduleName, i) {
+ var child = module2[moduleName];
+ if (!child) {
+ throw new Error('Missing module "' + moduleName + '" for path "' + path + '".');
+ }
+ return i === names.length - 1 ? child : child._children;
+ },
+ path === "root" ? moduleMap : moduleMap.root._children
+ );
+}
+function canThrow(cb) {
+ try {
+ return cb();
+ } catch (e) {
+ return e;
+ }
+}
+var Module = function Module2(rawModule, runtime) {
+ this.runtime = runtime;
+ this._children = /* @__PURE__ */ Object.create(null);
+ this._rawModule = rawModule;
+ var rawState = rawModule.state;
+ this.state = (typeof rawState === "function" ? rawState() : rawState) || {};
+};
+var prototypeAccessors$1 = { namespaced: { configurable: true } };
+prototypeAccessors$1.namespaced.get = function() {
+ return !!this._rawModule.namespaced;
+};
+Module.prototype.addChild = function addChild(key, module2) {
+ this._children[key] = module2;
+};
+Module.prototype.removeChild = function removeChild(key) {
+ delete this._children[key];
+};
+Module.prototype.getChild = function getChild(key) {
+ return this._children[key];
+};
+Module.prototype.hasChild = function hasChild(key) {
+ return key in this._children;
+};
+Module.prototype.update = function update(rawModule) {
+ this._rawModule.namespaced = rawModule.namespaced;
+ if (rawModule.actions) {
+ this._rawModule.actions = rawModule.actions;
+ }
+ if (rawModule.mutations) {
+ this._rawModule.mutations = rawModule.mutations;
+ }
+ if (rawModule.getters) {
+ this._rawModule.getters = rawModule.getters;
+ }
+};
+Module.prototype.forEachChild = function forEachChild(fn) {
+ forEachValue(this._children, fn);
+};
+Module.prototype.forEachGetter = function forEachGetter(fn) {
+ if (this._rawModule.getters) {
+ forEachValue(this._rawModule.getters, fn);
+ }
+};
+Module.prototype.forEachAction = function forEachAction(fn) {
+ if (this._rawModule.actions) {
+ forEachValue(this._rawModule.actions, fn);
+ }
+};
+Module.prototype.forEachMutation = function forEachMutation(fn) {
+ if (this._rawModule.mutations) {
+ forEachValue(this._rawModule.mutations, fn);
+ }
+};
+Object.defineProperties(Module.prototype, prototypeAccessors$1);
+var ModuleCollection = function ModuleCollection2(rawRootModule) {
+ this.register([], rawRootModule, false);
+};
+ModuleCollection.prototype.get = function get(path) {
+ return path.reduce(function(module2, key) {
+ return module2.getChild(key);
+ }, this.root);
+};
+ModuleCollection.prototype.getNamespace = function getNamespace(path) {
+ var module2 = this.root;
+ return path.reduce(function(namespace2, key) {
+ module2 = module2.getChild(key);
+ return namespace2 + (module2.namespaced ? key + "/" : "");
+ }, "");
+};
+ModuleCollection.prototype.update = function update$1(rawRootModule) {
+ update2([], this.root, rawRootModule);
+};
+ModuleCollection.prototype.register = function register(path, rawModule, runtime) {
+ var this$1$1 = this;
+ if (runtime === void 0) runtime = true;
+ var newModule = new Module(rawModule, runtime);
+ if (path.length === 0) {
+ this.root = newModule;
+ } else {
+ var parent = this.get(path.slice(0, -1));
+ parent.addChild(path[path.length - 1], newModule);
+ }
+ if (rawModule.modules) {
+ forEachValue(rawModule.modules, function(rawChildModule, key) {
+ this$1$1.register(path.concat(key), rawChildModule, runtime);
+ });
+ }
+};
+ModuleCollection.prototype.unregister = function unregister(path) {
+ var parent = this.get(path.slice(0, -1));
+ var key = path[path.length - 1];
+ var child = parent.getChild(key);
+ if (!child) {
+ return;
+ }
+ if (!child.runtime) {
+ return;
+ }
+ parent.removeChild(key);
+};
+ModuleCollection.prototype.isRegistered = function isRegistered(path) {
+ var parent = this.get(path.slice(0, -1));
+ var key = path[path.length - 1];
+ if (parent) {
+ return parent.hasChild(key);
+ }
+ return false;
+};
+function update2(path, targetModule, newModule) {
+ targetModule.update(newModule);
+ if (newModule.modules) {
+ for (var key in newModule.modules) {
+ if (!targetModule.getChild(key)) {
+ return;
+ }
+ update2(
+ path.concat(key),
+ targetModule.getChild(key),
+ newModule.modules[key]
+ );
+ }
+ }
+}
+function createStore(options) {
+ return new Store(options);
+}
+var Store = function Store2(options) {
+ var this$1$1 = this;
+ if (options === void 0) options = {};
+ var plugins = options.plugins;
+ if (plugins === void 0) plugins = [];
+ var strict = options.strict;
+ if (strict === void 0) strict = false;
+ var devtools = options.devtools;
+ this._committing = false;
+ this._actions = /* @__PURE__ */ Object.create(null);
+ this._actionSubscribers = [];
+ this._mutations = /* @__PURE__ */ Object.create(null);
+ this._wrappedGetters = /* @__PURE__ */ Object.create(null);
+ this._modules = new ModuleCollection(options);
+ this._modulesNamespaceMap = /* @__PURE__ */ Object.create(null);
+ this._subscribers = [];
+ this._makeLocalGettersCache = /* @__PURE__ */ Object.create(null);
+ this._scope = null;
+ this._devtools = devtools;
+ var store2 = this;
+ var ref2 = this;
+ var dispatch2 = ref2.dispatch;
+ var commit2 = ref2.commit;
+ this.dispatch = function boundDispatch(type, payload) {
+ return dispatch2.call(store2, type, payload);
+ };
+ this.commit = function boundCommit(type, payload, options2) {
+ return commit2.call(store2, type, payload, options2);
+ };
+ this.strict = strict;
+ var state2 = this._modules.root.state;
+ installModule(this, state2, [], this._modules.root);
+ resetStoreState(this, state2);
+ plugins.forEach(function(plugin2) {
+ return plugin2(this$1$1);
+ });
+};
+var prototypeAccessors = { state: { configurable: true } };
+Store.prototype.install = function install(app2, injectKey) {
+ app2.provide(injectKey || storeKey, this);
+ app2.config.globalProperties.$store = this;
+ var useDevtools = this._devtools !== void 0 ? this._devtools : false;
+ if (useDevtools) {
+ addDevtools(app2, this);
+ }
+};
+prototypeAccessors.state.get = function() {
+ return this._state.data;
+};
+prototypeAccessors.state.set = function(v) {
+};
+Store.prototype.commit = function commit(_type, _payload, _options) {
+ var this$1$1 = this;
+ var ref2 = unifyObjectStyle(_type, _payload, _options);
+ var type = ref2.type;
+ var payload = ref2.payload;
+ var mutation = { type, payload };
+ var entry = this._mutations[type];
+ if (!entry) {
+ return;
+ }
+ this._withCommit(function() {
+ entry.forEach(function commitIterator(handler) {
+ handler(payload);
+ });
+ });
+ this._subscribers.slice().forEach(function(sub) {
+ return sub(mutation, this$1$1.state);
+ });
+};
+Store.prototype.dispatch = function dispatch(_type, _payload) {
+ var this$1$1 = this;
+ var ref2 = unifyObjectStyle(_type, _payload);
+ var type = ref2.type;
+ var payload = ref2.payload;
+ var action = { type, payload };
+ var entry = this._actions[type];
+ if (!entry) {
+ return;
+ }
+ try {
+ this._actionSubscribers.slice().filter(function(sub) {
+ return sub.before;
+ }).forEach(function(sub) {
+ return sub.before(action, this$1$1.state);
+ });
+ } catch (e) {
+ }
+ var result = entry.length > 1 ? Promise.all(entry.map(function(handler) {
+ return handler(payload);
+ })) : entry[0](payload);
+ return new Promise(function(resolve2, reject) {
+ result.then(function(res) {
+ try {
+ this$1$1._actionSubscribers.filter(function(sub) {
+ return sub.after;
+ }).forEach(function(sub) {
+ return sub.after(action, this$1$1.state);
+ });
+ } catch (e) {
+ }
+ resolve2(res);
+ }, function(error) {
+ try {
+ this$1$1._actionSubscribers.filter(function(sub) {
+ return sub.error;
+ }).forEach(function(sub) {
+ return sub.error(action, this$1$1.state, error);
+ });
+ } catch (e) {
+ }
+ reject(error);
+ });
+ });
+};
+Store.prototype.subscribe = function subscribe(fn, options) {
+ return genericSubscribe(fn, this._subscribers, options);
+};
+Store.prototype.subscribeAction = function subscribeAction(fn, options) {
+ var subs = typeof fn === "function" ? { before: fn } : fn;
+ return genericSubscribe(subs, this._actionSubscribers, options);
+};
+Store.prototype.watch = function watch$12(getter, cb, options) {
+ var this$1$1 = this;
+ return watch(function() {
+ return getter(this$1$1.state, this$1$1.getters);
+ }, cb, Object.assign({}, options));
+};
+Store.prototype.replaceState = function replaceState(state2) {
+ var this$1$1 = this;
+ this._withCommit(function() {
+ this$1$1._state.data = state2;
+ });
+};
+Store.prototype.registerModule = function registerModule(path, rawModule, options) {
+ if (options === void 0) options = {};
+ if (typeof path === "string") {
+ path = [path];
+ }
+ this._modules.register(path, rawModule);
+ installModule(this, this.state, path, this._modules.get(path), options.preserveState);
+ resetStoreState(this, this.state);
+};
+Store.prototype.unregisterModule = function unregisterModule(path) {
+ var this$1$1 = this;
+ if (typeof path === "string") {
+ path = [path];
+ }
+ this._modules.unregister(path);
+ this._withCommit(function() {
+ var parentState = getNestedState(this$1$1.state, path.slice(0, -1));
+ delete parentState[path[path.length - 1]];
+ });
+ resetStore(this);
+};
+Store.prototype.hasModule = function hasModule(path) {
+ if (typeof path === "string") {
+ path = [path];
+ }
+ return this._modules.isRegistered(path);
+};
+Store.prototype.hotUpdate = function hotUpdate(newOptions) {
+ this._modules.update(newOptions);
+ resetStore(this, true);
+};
+Store.prototype._withCommit = function _withCommit(fn) {
+ var committing = this._committing;
+ this._committing = true;
+ fn();
+ this._committing = committing;
+};
+Object.defineProperties(Store.prototype, prototypeAccessors);
+function plugin$1(options) {
+ let _bPrefix = ".";
+ let _ePrefix = "__";
+ let _mPrefix = "--";
+ let c2;
+ {
+ let t = options.blockPrefix;
+ if (t) {
+ _bPrefix = t;
+ }
+ t = options.elementPrefix;
+ if (t) {
+ _ePrefix = t;
+ }
+ t = options.modifierPrefix;
+ if (t) {
+ _mPrefix = t;
+ }
+ }
+ const _plugin = {
+ install(instance) {
+ c2 = instance.c;
+ const ctx2 = instance.context;
+ ctx2.bem = {};
+ ctx2.bem.b = null;
+ ctx2.bem.els = null;
+ }
+ };
+ function b(arg) {
+ let memorizedB;
+ let memorizedE;
+ return {
+ before(ctx2) {
+ memorizedB = ctx2.bem.b;
+ memorizedE = ctx2.bem.els;
+ ctx2.bem.els = null;
+ },
+ after(ctx2) {
+ ctx2.bem.b = memorizedB;
+ ctx2.bem.els = memorizedE;
+ },
+ $({ context, props }) {
+ arg = typeof arg === "string" ? arg : arg({ context, props });
+ context.bem.b = arg;
+ return `${(props === null || props === void 0 ? void 0 : props.bPrefix) || _bPrefix}${context.bem.b}`;
+ }
+ };
+ }
+ function e(arg) {
+ let memorizedE;
+ return {
+ before(ctx2) {
+ memorizedE = ctx2.bem.els;
+ },
+ after(ctx2) {
+ ctx2.bem.els = memorizedE;
+ },
+ $({ context, props }) {
+ arg = typeof arg === "string" ? arg : arg({ context, props });
+ context.bem.els = arg.split(",").map((v) => v.trim());
+ return context.bem.els.map((el) => `${(props === null || props === void 0 ? void 0 : props.bPrefix) || _bPrefix}${context.bem.b}${_ePrefix}${el}`).join(", ");
+ }
+ };
+ }
+ function m(arg) {
+ return {
+ $({ context, props }) {
+ arg = typeof arg === "string" ? arg : arg({ context, props });
+ const modifiers = arg.split(",").map((v) => v.trim());
+ function elementToSelector(el) {
+ return modifiers.map((modifier) => `&${(props === null || props === void 0 ? void 0 : props.bPrefix) || _bPrefix}${context.bem.b}${el !== void 0 ? `${_ePrefix}${el}` : ""}${_mPrefix}${modifier}`).join(", ");
+ }
+ const els = context.bem.els;
+ if (els !== null) {
+ return elementToSelector(els[0]);
+ } else {
+ return elementToSelector();
+ }
+ }
+ };
+ }
+ function notM(arg) {
+ return {
+ $({ context, props }) {
+ arg = typeof arg === "string" ? arg : arg({ context, props });
+ const els = context.bem.els;
+ return `&:not(${(props === null || props === void 0 ? void 0 : props.bPrefix) || _bPrefix}${context.bem.b}${els !== null && els.length > 0 ? `${_ePrefix}${els[0]}` : ""}${_mPrefix}${arg})`;
+ }
+ };
+ }
+ const cB2 = (...args) => c2(b(args[0]), args[1], args[2]);
+ const cE2 = (...args) => c2(e(args[0]), args[1], args[2]);
+ const cM2 = (...args) => c2(m(args[0]), args[1], args[2]);
+ const cNotM2 = (...args) => c2(notM(args[0]), args[1], args[2]);
+ Object.assign(_plugin, {
+ cB: cB2,
+ cE: cE2,
+ cM: cM2,
+ cNotM: cNotM2
+ });
+ return _plugin;
+}
+function ampCount(selector) {
+ let cnt = 0;
+ for (let i = 0; i < selector.length; ++i) {
+ if (selector[i] === "&")
+ ++cnt;
+ }
+ return cnt;
+}
+const separatorRegex = /\s*,(?![^(]*\))\s*/g;
+const extraSpaceRegex = /\s+/g;
+function resolveSelectorWithAmp(amp, selector) {
+ const nextAmp = [];
+ selector.split(separatorRegex).forEach((partialSelector) => {
+ let round = ampCount(partialSelector);
+ if (!round) {
+ amp.forEach((partialAmp) => {
+ nextAmp.push(
+ // eslint-disable-next-line @typescript-eslint/strict-boolean-expressions
+ (partialAmp && partialAmp + " ") + partialSelector
+ );
+ });
+ return;
+ } else if (round === 1) {
+ amp.forEach((partialAmp) => {
+ nextAmp.push(partialSelector.replace("&", partialAmp));
+ });
+ return;
+ }
+ let partialNextAmp = [
+ partialSelector
+ ];
+ while (round--) {
+ const nextPartialNextAmp = [];
+ partialNextAmp.forEach((selectorItr) => {
+ amp.forEach((partialAmp) => {
+ nextPartialNextAmp.push(selectorItr.replace("&", partialAmp));
+ });
+ });
+ partialNextAmp = nextPartialNextAmp;
+ }
+ partialNextAmp.forEach((part) => nextAmp.push(part));
+ });
+ return nextAmp;
+}
+function resolveSelector(amp, selector) {
+ const nextAmp = [];
+ selector.split(separatorRegex).forEach((partialSelector) => {
+ amp.forEach((partialAmp) => {
+ nextAmp.push((partialAmp && partialAmp + " ") + partialSelector);
+ });
+ });
+ return nextAmp;
+}
+function parseSelectorPath(selectorPaths) {
+ let amp = [""];
+ selectorPaths.forEach((selector) => {
+ selector = selector && selector.trim();
+ if (
+ // eslint-disable-next-line @typescript-eslint/strict-boolean-expressions
+ !selector
+ ) {
+ return;
+ }
+ if (selector.includes("&")) {
+ amp = resolveSelectorWithAmp(amp, selector);
+ } else {
+ amp = resolveSelector(amp, selector);
+ }
+ });
+ return amp.join(", ").replace(extraSpaceRegex, " ");
+}
+function removeElement(el) {
+ if (!el)
+ return;
+ const parentElement = el.parentElement;
+ if (parentElement)
+ parentElement.removeChild(el);
+}
+function queryElement(id, parent) {
+ return (parent !== null && parent !== void 0 ? parent : document.head).querySelector(`style[cssr-id="${id}"]`);
+}
+function createElement(id) {
+ const el = document.createElement("style");
+ el.setAttribute("cssr-id", id);
+ return el;
+}
+function isMediaOrSupports(selector) {
+ if (!selector)
+ return false;
+ return /^\s*@(s|m)/.test(selector);
+}
+const kebabRegex = /[A-Z]/g;
+function kebabCase(pattern) {
+ return pattern.replace(kebabRegex, (match) => "-" + match.toLowerCase());
+}
+function unwrapProperty(prop, indent = " ") {
+ if (typeof prop === "object" && prop !== null) {
+ return " {\n" + Object.entries(prop).map((v) => {
+ return indent + ` ${kebabCase(v[0])}: ${v[1]};`;
+ }).join("\n") + "\n" + indent + "}";
+ }
+ return `: ${prop};`;
+}
+function unwrapProperties(props, instance, params) {
+ if (typeof props === "function") {
+ return props({
+ context: instance.context,
+ props: params
+ });
+ }
+ return props;
+}
+function createStyle(selector, props, instance, params) {
+ if (!props)
+ return "";
+ const unwrappedProps = unwrapProperties(props, instance, params);
+ if (!unwrappedProps)
+ return "";
+ if (typeof unwrappedProps === "string") {
+ return `${selector} {
+${unwrappedProps}
+}`;
+ }
+ const propertyNames = Object.keys(unwrappedProps);
+ if (propertyNames.length === 0) {
+ if (instance.config.keepEmptyBlock)
+ return selector + " {\n}";
+ return "";
+ }
+ const statements = selector ? [
+ selector + " {"
+ ] : [];
+ propertyNames.forEach((propertyName) => {
+ const property = unwrappedProps[propertyName];
+ if (propertyName === "raw") {
+ statements.push("\n" + property + "\n");
+ return;
+ }
+ propertyName = kebabCase(propertyName);
+ if (property !== null && property !== void 0) {
+ statements.push(` ${propertyName}${unwrapProperty(property)}`);
+ }
+ });
+ if (selector) {
+ statements.push("}");
+ }
+ return statements.join("\n");
+}
+function loopCNodeListWithCallback(children, options, callback) {
+ if (!children)
+ return;
+ children.forEach((child) => {
+ if (Array.isArray(child)) {
+ loopCNodeListWithCallback(child, options, callback);
+ } else if (typeof child === "function") {
+ const grandChildren = child(options);
+ if (Array.isArray(grandChildren)) {
+ loopCNodeListWithCallback(grandChildren, options, callback);
+ } else if (grandChildren) {
+ callback(grandChildren);
+ }
+ } else if (child) {
+ callback(child);
+ }
+ });
+}
+function traverseCNode(node, selectorPaths, styles, instance, params) {
+ const $ = node.$;
+ let blockSelector = "";
+ if (!$ || typeof $ === "string") {
+ if (isMediaOrSupports($)) {
+ blockSelector = $;
+ } else {
+ selectorPaths.push($);
+ }
+ } else if (typeof $ === "function") {
+ const selector2 = $({
+ context: instance.context,
+ props: params
+ });
+ if (isMediaOrSupports(selector2)) {
+ blockSelector = selector2;
+ } else {
+ selectorPaths.push(selector2);
+ }
+ } else {
+ if ($.before)
+ $.before(instance.context);
+ if (!$.$ || typeof $.$ === "string") {
+ if (isMediaOrSupports($.$)) {
+ blockSelector = $.$;
+ } else {
+ selectorPaths.push($.$);
+ }
+ } else if ($.$) {
+ const selector2 = $.$({
+ context: instance.context,
+ props: params
+ });
+ if (isMediaOrSupports(selector2)) {
+ blockSelector = selector2;
+ } else {
+ selectorPaths.push(selector2);
+ }
+ }
+ }
+ const selector = parseSelectorPath(selectorPaths);
+ const style2 = createStyle(selector, node.props, instance, params);
+ if (blockSelector) {
+ styles.push(`${blockSelector} {`);
+ } else if (style2.length) {
+ styles.push(style2);
+ }
+ if (node.children) {
+ loopCNodeListWithCallback(node.children, {
+ context: instance.context,
+ props: params
+ }, (childNode) => {
+ if (typeof childNode === "string") {
+ const style3 = createStyle(selector, { raw: childNode }, instance, params);
+ styles.push(style3);
+ } else {
+ traverseCNode(childNode, selectorPaths, styles, instance, params);
+ }
+ });
+ }
+ selectorPaths.pop();
+ if (blockSelector) {
+ styles.push("}");
+ }
+ if ($ && $.after)
+ $.after(instance.context);
+}
+function render$1(node, instance, props) {
+ const styles = [];
+ traverseCNode(node, [], styles, instance, props);
+ return styles.join("\n\n");
+}
+function murmur2(str) {
+ var h2 = 0;
+ var k, i = 0, len = str.length;
+ for (; len >= 4; ++i, len -= 4) {
+ k = str.charCodeAt(i) & 255 | (str.charCodeAt(++i) & 255) << 8 | (str.charCodeAt(++i) & 255) << 16 | (str.charCodeAt(++i) & 255) << 24;
+ k = /* Math.imul(k, m): */
+ (k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16);
+ k ^= /* k >>> r: */
+ k >>> 24;
+ h2 = /* Math.imul(k, m): */
+ (k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
+ (h2 & 65535) * 1540483477 + ((h2 >>> 16) * 59797 << 16);
+ }
+ switch (len) {
+ case 3:
+ h2 ^= (str.charCodeAt(i + 2) & 255) << 16;
+ case 2:
+ h2 ^= (str.charCodeAt(i + 1) & 255) << 8;
+ case 1:
+ h2 ^= str.charCodeAt(i) & 255;
+ h2 = /* Math.imul(h, m): */
+ (h2 & 65535) * 1540483477 + ((h2 >>> 16) * 59797 << 16);
+ }
+ h2 ^= h2 >>> 13;
+ h2 = /* Math.imul(h, m): */
+ (h2 & 65535) * 1540483477 + ((h2 >>> 16) * 59797 << 16);
+ return ((h2 ^ h2 >>> 15) >>> 0).toString(36);
+}
+if (typeof window !== "undefined") {
+ window.__cssrContext = {};
+}
+function unmount(instance, node, id, parent) {
+ const { els } = node;
+ if (id === void 0) {
+ els.forEach(removeElement);
+ node.els = [];
+ } else {
+ const target = queryElement(id, parent);
+ if (target && els.includes(target)) {
+ removeElement(target);
+ node.els = els.filter((el) => el !== target);
+ }
+ }
+}
+function addElementToList(els, target) {
+ els.push(target);
+}
+function mount(instance, node, id, props, head, force, anchorMetaName, parent, ssrAdapter2) {
+ let style2;
+ if (id === void 0) {
+ style2 = node.render(props);
+ id = murmur2(style2);
+ }
+ if (ssrAdapter2) {
+ ssrAdapter2.adapter(id, style2 !== null && style2 !== void 0 ? style2 : node.render(props));
+ return;
+ }
+ if (parent === void 0) {
+ parent = document.head;
+ }
+ const queriedTarget = queryElement(id, parent);
+ if (queriedTarget !== null && !force) {
+ return queriedTarget;
+ }
+ const target = queriedTarget !== null && queriedTarget !== void 0 ? queriedTarget : createElement(id);
+ if (style2 === void 0)
+ style2 = node.render(props);
+ target.textContent = style2;
+ if (queriedTarget !== null)
+ return queriedTarget;
+ if (anchorMetaName) {
+ const anchorMetaEl = parent.querySelector(`meta[name="${anchorMetaName}"]`);
+ if (anchorMetaEl) {
+ parent.insertBefore(target, anchorMetaEl);
+ addElementToList(node.els, target);
+ return target;
+ }
+ }
+ if (head) {
+ parent.insertBefore(target, parent.querySelector("style, link"));
+ } else {
+ parent.appendChild(target);
+ }
+ addElementToList(node.els, target);
+ return target;
+}
+function wrappedRender(props) {
+ return render$1(this, this.instance, props);
+}
+function wrappedMount(options = {}) {
+ const { id, ssr, props, head = false, force = false, anchorMetaName, parent } = options;
+ const targetElement = mount(this.instance, this, id, props, head, force, anchorMetaName, parent, ssr);
+ return targetElement;
+}
+function wrappedUnmount(options = {}) {
+ const { id, parent } = options;
+ unmount(this.instance, this, id, parent);
+}
+const createCNode = function(instance, $, props, children) {
+ return {
+ instance,
+ $,
+ props,
+ children,
+ els: [],
+ render: wrappedRender,
+ mount: wrappedMount,
+ unmount: wrappedUnmount
+ };
+};
+const c$1 = function(instance, $, props, children) {
+ if (Array.isArray($)) {
+ return createCNode(instance, { $: null }, null, $);
+ } else if (Array.isArray(props)) {
+ return createCNode(instance, $, null, props);
+ } else if (Array.isArray(children)) {
+ return createCNode(instance, $, props, children);
+ } else {
+ return createCNode(instance, $, props, null);
+ }
+};
+function CssRender(config2 = {}) {
+ const cssr2 = {
+ c: (...args) => c$1(cssr2, ...args),
+ use: (plugin2, ...args) => plugin2.install(cssr2, ...args),
+ find: queryElement,
+ context: {},
+ config: config2
+ };
+ return cssr2;
+}
+function exists(id, ssr) {
+ if (id === void 0)
+ return false;
+ if (ssr) {
+ const { context: { ids } } = ssr;
+ return ids.has(id);
+ }
+ return queryElement(id) !== null;
+}
+const namespace = "n";
+const prefix$1 = `.${namespace}-`;
+const elementPrefix = "__";
+const modifierPrefix = "--";
+const cssr = CssRender();
+const plugin = plugin$1({
+ blockPrefix: prefix$1,
+ elementPrefix,
+ modifierPrefix
+});
+cssr.use(plugin);
+const {
+ c,
+ find
+} = cssr;
+const {
+ cB,
+ cE,
+ cM,
+ cNotM
+} = plugin;
+function insideModal(style2) {
+ return c(({
+ props: {
+ bPrefix
+ }
+ }) => `${bPrefix || prefix$1}modal, ${bPrefix || prefix$1}drawer`, [style2]);
+}
+function insidePopover(style2) {
+ return c(({
+ props: {
+ bPrefix
+ }
+ }) => `${bPrefix || prefix$1}popover`, [style2]);
+}
+function asModal(style2) {
+ return c(({
+ props: {
+ bPrefix
+ }
+ }) => `&${bPrefix || prefix$1}modal`, style2);
+}
+const cCB = (...args) => {
+ return c(">", [cB(...args)]);
+};
+function createKey(prefix2, suffix2) {
+ return prefix2 + (suffix2 === "default" ? "" : suffix2.replace(/^[a-z]/, (startChar) => startChar.toUpperCase()));
+}
+function getPreciseEventTarget(event) {
+ return event.composedPath()[0] || null;
+}
+function depx(value) {
+ if (typeof value === "string") {
+ if (value.endsWith("px")) {
+ return Number(value.slice(0, value.length - 2));
+ }
+ return Number(value);
+ }
+ return value;
+}
+function pxfy(value) {
+ if (value === void 0 || value === null)
+ return void 0;
+ if (typeof value === "number")
+ return `${value}px`;
+ if (value.endsWith("px"))
+ return value;
+ return `${value}px`;
+}
+function getMargin(value, position) {
+ const parts = value.trim().split(/\s+/g);
+ const margin = {
+ top: parts[0]
+ };
+ switch (parts.length) {
+ case 1:
+ margin.right = parts[0];
+ margin.bottom = parts[0];
+ margin.left = parts[0];
+ break;
+ case 2:
+ margin.right = parts[1];
+ margin.left = parts[1];
+ margin.bottom = parts[0];
+ break;
+ case 3:
+ margin.right = parts[1];
+ margin.bottom = parts[2];
+ margin.left = parts[1];
+ break;
+ case 4:
+ margin.right = parts[1];
+ margin.bottom = parts[2];
+ margin.left = parts[3];
+ break;
+ default:
+ throw new Error("[seemly/getMargin]:" + value + " is not a valid value.");
+ }
+ return margin;
+}
+const colors = {
+ black: "#000",
+ silver: "#C0C0C0",
+ gray: "#808080",
+ white: "#FFF",
+ maroon: "#800000",
+ red: "#F00",
+ purple: "#800080",
+ fuchsia: "#F0F",
+ green: "#008000",
+ lime: "#0F0",
+ olive: "#808000",
+ yellow: "#FF0",
+ navy: "#000080",
+ blue: "#00F",
+ teal: "#008080",
+ aqua: "#0FF",
+ transparent: "#0000"
+};
+const prefix = "^\\s*";
+const suffix = "\\s*$";
+const float = "\\s*((\\.\\d+)|(\\d+(\\.\\d*)?))\\s*";
+const hex = "([0-9A-Fa-f])";
+const dhex = "([0-9A-Fa-f]{2})";
+const rgbRegex = new RegExp(`${prefix}rgb\\s*\\(${float},${float},${float}\\)${suffix}`);
+const rgbaRegex = new RegExp(`${prefix}rgba\\s*\\(${float},${float},${float},${float}\\)${suffix}`);
+const sHexRegex = new RegExp(`${prefix}#${hex}${hex}${hex}${suffix}`);
+const hexRegex = new RegExp(`${prefix}#${dhex}${dhex}${dhex}${suffix}`);
+const sHexaRegex = new RegExp(`${prefix}#${hex}${hex}${hex}${hex}${suffix}`);
+const hexaRegex = new RegExp(`${prefix}#${dhex}${dhex}${dhex}${dhex}${suffix}`);
+function parseHex(value) {
+ return parseInt(value, 16);
+}
+function rgba(color) {
+ try {
+ let i;
+ if (i = hexRegex.exec(color)) {
+ return [parseHex(i[1]), parseHex(i[2]), parseHex(i[3]), 1];
+ } else if (i = rgbRegex.exec(color)) {
+ return [roundChannel(i[1]), roundChannel(i[5]), roundChannel(i[9]), 1];
+ } else if (i = rgbaRegex.exec(color)) {
+ return [
+ roundChannel(i[1]),
+ roundChannel(i[5]),
+ roundChannel(i[9]),
+ roundAlpha(i[13])
+ ];
+ } else if (i = sHexRegex.exec(color)) {
+ return [
+ parseHex(i[1] + i[1]),
+ parseHex(i[2] + i[2]),
+ parseHex(i[3] + i[3]),
+ 1
+ ];
+ } else if (i = hexaRegex.exec(color)) {
+ return [
+ parseHex(i[1]),
+ parseHex(i[2]),
+ parseHex(i[3]),
+ roundAlpha(parseHex(i[4]) / 255)
+ ];
+ } else if (i = sHexaRegex.exec(color)) {
+ return [
+ parseHex(i[1] + i[1]),
+ parseHex(i[2] + i[2]),
+ parseHex(i[3] + i[3]),
+ roundAlpha(parseHex(i[4] + i[4]) / 255)
+ ];
+ } else if (color in colors) {
+ return rgba(colors[color]);
+ }
+ throw new Error(`[seemly/rgba]: Invalid color value ${color}.`);
+ } catch (e) {
+ throw e;
+ }
+}
+function normalizeAlpha(alphaValue) {
+ return alphaValue > 1 ? 1 : alphaValue < 0 ? 0 : alphaValue;
+}
+function stringifyRgba(r, g, b, a) {
+ return `rgba(${roundChannel(r)}, ${roundChannel(g)}, ${roundChannel(b)}, ${normalizeAlpha(a)})`;
+}
+function compositeChannel(v1, a1, v2, a2, a) {
+ return roundChannel((v1 * a1 * (1 - a2) + v2 * a2) / a);
+}
+function composite(background, overlay2) {
+ if (!Array.isArray(background))
+ background = rgba(background);
+ if (!Array.isArray(overlay2))
+ overlay2 = rgba(overlay2);
+ const a1 = background[3];
+ const a2 = overlay2[3];
+ const alpha = roundAlpha(a1 + a2 - a1 * a2);
+ return stringifyRgba(compositeChannel(background[0], a1, overlay2[0], a2, alpha), compositeChannel(background[1], a1, overlay2[1], a2, alpha), compositeChannel(background[2], a1, overlay2[2], a2, alpha), alpha);
+}
+function changeColor(base2, options) {
+ const [r, g, b, a = 1] = Array.isArray(base2) ? base2 : rgba(base2);
+ if (options.alpha) {
+ return stringifyRgba(r, g, b, options.alpha);
+ }
+ return stringifyRgba(r, g, b, a);
+}
+function scaleColor(base2, options) {
+ const [r, g, b, a = 1] = Array.isArray(base2) ? base2 : rgba(base2);
+ const { lightness = 1, alpha = 1 } = options;
+ return toRgbaString([r * lightness, g * lightness, b * lightness, a * alpha]);
+}
+function roundAlpha(value) {
+ const v = Math.round(Number(value) * 100) / 100;
+ if (v > 1)
+ return 1;
+ if (v < 0)
+ return 0;
+ return v;
+}
+function roundChannel(value) {
+ const v = Math.round(Number(value));
+ if (v > 255)
+ return 255;
+ if (v < 0)
+ return 0;
+ return v;
+}
+function toRgbaString(base2) {
+ const [r, g, b] = base2;
+ if (3 in base2) {
+ return `rgba(${roundChannel(r)}, ${roundChannel(g)}, ${roundChannel(b)}, ${roundAlpha(base2[3])})`;
+ }
+ return `rgba(${roundChannel(r)}, ${roundChannel(g)}, ${roundChannel(b)}, 1)`;
+}
+function createId(length = 8) {
+ return Math.random().toString(16).slice(2, 2 + length);
+}
+function getEventTarget(e) {
+ const path = e.composedPath();
+ return path[0];
+}
+const traps = {
+ mousemoveoutside: /* @__PURE__ */ new WeakMap(),
+ clickoutside: /* @__PURE__ */ new WeakMap()
+};
+function createTrapHandler(name2, el, originalHandler) {
+ if (name2 === "mousemoveoutside") {
+ const moveHandler = (e) => {
+ if (el.contains(getEventTarget(e)))
+ return;
+ originalHandler(e);
+ };
+ return {
+ mousemove: moveHandler,
+ touchstart: moveHandler
+ };
+ } else if (name2 === "clickoutside") {
+ let mouseDownOutside = false;
+ const downHandler = (e) => {
+ mouseDownOutside = !el.contains(getEventTarget(e));
+ };
+ const upHanlder = (e) => {
+ if (!mouseDownOutside)
+ return;
+ if (el.contains(getEventTarget(e)))
+ return;
+ originalHandler(e);
+ };
+ return {
+ mousedown: downHandler,
+ mouseup: upHanlder,
+ touchstart: downHandler,
+ touchend: upHanlder
+ };
+ }
+ console.error(
+ // eslint-disable-next-line @typescript-eslint/restrict-template-expressions
+ `[evtd/create-trap-handler]: name \`${name2}\` is invalid. This could be a bug of evtd.`
+ );
+ return {};
+}
+function ensureTrapHandlers(name2, el, handler) {
+ const handlers2 = traps[name2];
+ let elHandlers = handlers2.get(el);
+ if (elHandlers === void 0) {
+ handlers2.set(el, elHandlers = /* @__PURE__ */ new WeakMap());
+ }
+ let trapHandler = elHandlers.get(handler);
+ if (trapHandler === void 0) {
+ elHandlers.set(handler, trapHandler = createTrapHandler(name2, el, handler));
+ }
+ return trapHandler;
+}
+function trapOn(name2, el, handler, options) {
+ if (name2 === "mousemoveoutside" || name2 === "clickoutside") {
+ const trapHandlers = ensureTrapHandlers(name2, el, handler);
+ Object.keys(trapHandlers).forEach((key) => {
+ on(key, document, trapHandlers[key], options);
+ });
+ return true;
+ }
+ return false;
+}
+function trapOff(name2, el, handler, options) {
+ if (name2 === "mousemoveoutside" || name2 === "clickoutside") {
+ const trapHandlers = ensureTrapHandlers(name2, el, handler);
+ Object.keys(trapHandlers).forEach((key) => {
+ off(key, document, trapHandlers[key], options);
+ });
+ return true;
+ }
+ return false;
+}
+function createDelegate() {
+ if (typeof window === "undefined") {
+ return {
+ on: () => {
+ },
+ off: () => {
+ }
+ };
+ }
+ const propagationStopped = /* @__PURE__ */ new WeakMap();
+ const immediatePropagationStopped = /* @__PURE__ */ new WeakMap();
+ function trackPropagation() {
+ propagationStopped.set(this, true);
+ }
+ function trackImmediate() {
+ propagationStopped.set(this, true);
+ immediatePropagationStopped.set(this, true);
+ }
+ function spy(event, propName, fn) {
+ const source = event[propName];
+ event[propName] = function() {
+ fn.apply(event, arguments);
+ return source.apply(event, arguments);
+ };
+ return event;
+ }
+ function unspy(event, propName) {
+ event[propName] = Event.prototype[propName];
+ }
+ const currentTargets = /* @__PURE__ */ new WeakMap();
+ const currentTargetDescriptor = Object.getOwnPropertyDescriptor(Event.prototype, "currentTarget");
+ function getCurrentTarget() {
+ var _a;
+ return (_a = currentTargets.get(this)) !== null && _a !== void 0 ? _a : null;
+ }
+ function defineCurrentTarget(event, getter) {
+ if (currentTargetDescriptor === void 0)
+ return;
+ Object.defineProperty(event, "currentTarget", {
+ configurable: true,
+ enumerable: true,
+ get: getter !== null && getter !== void 0 ? getter : currentTargetDescriptor.get
+ });
+ }
+ const phaseToTypeToElToHandlers = {
+ bubble: {},
+ capture: {}
+ };
+ const typeToWindowEventHandlers = {};
+ function createUnifiedHandler() {
+ const delegeteHandler = function(e) {
+ const { type, eventPhase, bubbles } = e;
+ const target = getEventTarget(e);
+ if (eventPhase === 2)
+ return;
+ const phase = eventPhase === 1 ? "capture" : "bubble";
+ let cursor = target;
+ const path = [];
+ while (true) {
+ if (cursor === null)
+ cursor = window;
+ path.push(cursor);
+ if (cursor === window) {
+ break;
+ }
+ cursor = cursor.parentNode || null;
+ }
+ const captureElToHandlers = phaseToTypeToElToHandlers.capture[type];
+ const bubbleElToHandlers = phaseToTypeToElToHandlers.bubble[type];
+ spy(e, "stopPropagation", trackPropagation);
+ spy(e, "stopImmediatePropagation", trackImmediate);
+ defineCurrentTarget(e, getCurrentTarget);
+ if (phase === "capture") {
+ if (captureElToHandlers === void 0)
+ return;
+ for (let i = path.length - 1; i >= 0; --i) {
+ if (propagationStopped.has(e))
+ break;
+ const target2 = path[i];
+ const handlers2 = captureElToHandlers.get(target2);
+ if (handlers2 !== void 0) {
+ currentTargets.set(e, target2);
+ for (const handler of handlers2) {
+ if (immediatePropagationStopped.has(e))
+ break;
+ handler(e);
+ }
+ }
+ if (i === 0 && !bubbles && bubbleElToHandlers !== void 0) {
+ const bubbleHandlers = bubbleElToHandlers.get(target2);
+ if (bubbleHandlers !== void 0) {
+ for (const handler of bubbleHandlers) {
+ if (immediatePropagationStopped.has(e))
+ break;
+ handler(e);
+ }
+ }
+ }
+ }
+ } else if (phase === "bubble") {
+ if (bubbleElToHandlers === void 0)
+ return;
+ for (let i = 0; i < path.length; ++i) {
+ if (propagationStopped.has(e))
+ break;
+ const target2 = path[i];
+ const handlers2 = bubbleElToHandlers.get(target2);
+ if (handlers2 !== void 0) {
+ currentTargets.set(e, target2);
+ for (const handler of handlers2) {
+ if (immediatePropagationStopped.has(e))
+ break;
+ handler(e);
+ }
+ }
+ }
+ }
+ unspy(e, "stopPropagation");
+ unspy(e, "stopImmediatePropagation");
+ defineCurrentTarget(e);
+ };
+ delegeteHandler.displayName = "evtdUnifiedHandler";
+ return delegeteHandler;
+ }
+ function createUnifiedWindowEventHandler() {
+ const delegateHandler = function(e) {
+ const { type, eventPhase } = e;
+ if (eventPhase !== 2)
+ return;
+ const handlers2 = typeToWindowEventHandlers[type];
+ if (handlers2 === void 0)
+ return;
+ handlers2.forEach((handler) => handler(e));
+ };
+ delegateHandler.displayName = "evtdUnifiedWindowEventHandler";
+ return delegateHandler;
+ }
+ const unifiedHandler = createUnifiedHandler();
+ const unfiendWindowEventHandler = createUnifiedWindowEventHandler();
+ function ensureElToHandlers(phase, type) {
+ const phaseHandlers = phaseToTypeToElToHandlers[phase];
+ if (phaseHandlers[type] === void 0) {
+ phaseHandlers[type] = /* @__PURE__ */ new Map();
+ window.addEventListener(type, unifiedHandler, phase === "capture");
+ }
+ return phaseHandlers[type];
+ }
+ function ensureWindowEventHandlers(type) {
+ const windowEventHandlers = typeToWindowEventHandlers[type];
+ if (windowEventHandlers === void 0) {
+ typeToWindowEventHandlers[type] = /* @__PURE__ */ new Set();
+ window.addEventListener(type, unfiendWindowEventHandler);
+ }
+ return typeToWindowEventHandlers[type];
+ }
+ function ensureHandlers(elToHandlers, el) {
+ let elHandlers = elToHandlers.get(el);
+ if (elHandlers === void 0) {
+ elToHandlers.set(el, elHandlers = /* @__PURE__ */ new Set());
+ }
+ return elHandlers;
+ }
+ function handlerExist(el, phase, type, handler) {
+ const elToHandlers = phaseToTypeToElToHandlers[phase][type];
+ if (elToHandlers !== void 0) {
+ const handlers2 = elToHandlers.get(el);
+ if (handlers2 !== void 0) {
+ if (handlers2.has(handler))
+ return true;
+ }
+ }
+ return false;
+ }
+ function windowEventHandlerExist(type, handler) {
+ const handlers2 = typeToWindowEventHandlers[type];
+ if (handlers2 !== void 0) {
+ if (handlers2.has(handler)) {
+ return true;
+ }
+ }
+ return false;
+ }
+ function on2(type, el, handler, options) {
+ let mergedHandler;
+ if (typeof options === "object" && options.once === true) {
+ mergedHandler = (e) => {
+ off2(type, el, mergedHandler, options);
+ handler(e);
+ };
+ } else {
+ mergedHandler = handler;
+ }
+ const trapped = trapOn(type, el, mergedHandler, options);
+ if (trapped)
+ return;
+ const phase = options === true || typeof options === "object" && options.capture === true ? "capture" : "bubble";
+ const elToHandlers = ensureElToHandlers(phase, type);
+ const handlers2 = ensureHandlers(elToHandlers, el);
+ if (!handlers2.has(mergedHandler))
+ handlers2.add(mergedHandler);
+ if (el === window) {
+ const windowEventHandlers = ensureWindowEventHandlers(type);
+ if (!windowEventHandlers.has(mergedHandler)) {
+ windowEventHandlers.add(mergedHandler);
+ }
+ }
+ }
+ function off2(type, el, handler, options) {
+ const trapped = trapOff(type, el, handler, options);
+ if (trapped)
+ return;
+ const capture = options === true || typeof options === "object" && options.capture === true;
+ const phase = capture ? "capture" : "bubble";
+ const elToHandlers = ensureElToHandlers(phase, type);
+ const handlers2 = ensureHandlers(elToHandlers, el);
+ if (el === window) {
+ const mirrorPhase = capture ? "bubble" : "capture";
+ if (!handlerExist(el, mirrorPhase, type, handler) && windowEventHandlerExist(type, handler)) {
+ const windowEventHandlers = typeToWindowEventHandlers[type];
+ windowEventHandlers.delete(handler);
+ if (windowEventHandlers.size === 0) {
+ window.removeEventListener(type, unfiendWindowEventHandler);
+ typeToWindowEventHandlers[type] = void 0;
+ }
+ }
+ }
+ if (handlers2.has(handler))
+ handlers2.delete(handler);
+ if (handlers2.size === 0) {
+ elToHandlers.delete(el);
+ }
+ if (elToHandlers.size === 0) {
+ window.removeEventListener(type, unifiedHandler, phase === "capture");
+ phaseToTypeToElToHandlers[phase][type] = void 0;
+ }
+ }
+ return {
+ on: on2,
+ off: off2
+ };
+}
+const { on, off } = createDelegate();
+function useFalseUntilTruthy(originalRef) {
+ const currentRef = ref(!!originalRef.value);
+ if (currentRef.value)
+ return readonly(currentRef);
+ const stop = watch(originalRef, (value) => {
+ if (value) {
+ currentRef.value = true;
+ stop();
+ }
+ });
+ return readonly(currentRef);
+}
+function useMemo(getterOrOptions) {
+ const computedValueRef = computed(getterOrOptions);
+ const valueRef = ref(computedValueRef.value);
+ watch(computedValueRef, (value) => {
+ valueRef.value = value;
+ });
+ if (typeof getterOrOptions === "function") {
+ return valueRef;
+ } else {
+ return {
+ __v_isRef: true,
+ get value() {
+ return valueRef.value;
+ },
+ set value(v) {
+ getterOrOptions.set(v);
+ }
+ };
+ }
+}
+function hasInstance() {
+ return getCurrentInstance() !== null;
+}
+const isBrowser$2 = typeof window !== "undefined";
+const mousePositionRef = ref(null);
+function clickHandler(e) {
+ if (e.clientX > 0 || e.clientY > 0) {
+ mousePositionRef.value = {
+ x: e.clientX,
+ y: e.clientY
+ };
+ } else {
+ const { target } = e;
+ if (target instanceof Element) {
+ const { left, top, width, height } = target.getBoundingClientRect();
+ if (left > 0 || top > 0) {
+ mousePositionRef.value = {
+ x: left + width / 2,
+ y: top + height / 2
+ };
+ } else {
+ mousePositionRef.value = { x: 0, y: 0 };
+ }
+ } else {
+ mousePositionRef.value = null;
+ }
+ }
+}
+let usedCount$1 = 0;
+let managable$1 = true;
+function useClickPosition() {
+ if (!isBrowser$2)
+ return readonly(ref(null));
+ if (usedCount$1 === 0)
+ on("click", document, clickHandler, true);
+ const setup = () => {
+ usedCount$1 += 1;
+ };
+ if (managable$1 && (managable$1 = hasInstance())) {
+ onBeforeMount(setup);
+ onBeforeUnmount(() => {
+ usedCount$1 -= 1;
+ if (usedCount$1 === 0)
+ off("click", document, clickHandler, true);
+ });
+ } else {
+ setup();
+ }
+ return readonly(mousePositionRef);
+}
+const clickedTimeRef = ref(void 0);
+let usedCount = 0;
+function handleClick() {
+ clickedTimeRef.value = Date.now();
+}
+let managable = true;
+function useClicked(timeout) {
+ if (!isBrowser$2)
+ return readonly(ref(false));
+ const clickedRef = ref(false);
+ let timerId = null;
+ function clearTimer() {
+ if (timerId !== null)
+ window.clearTimeout(timerId);
+ }
+ function clickedHandler() {
+ clearTimer();
+ clickedRef.value = true;
+ timerId = window.setTimeout(() => {
+ clickedRef.value = false;
+ }, timeout);
+ }
+ if (usedCount === 0) {
+ on("click", window, handleClick, true);
+ }
+ const setup = () => {
+ usedCount += 1;
+ on("click", window, clickedHandler, true);
+ };
+ if (managable && (managable = hasInstance())) {
+ onBeforeMount(setup);
+ onBeforeUnmount(() => {
+ usedCount -= 1;
+ if (usedCount === 0) {
+ off("click", window, handleClick, true);
+ }
+ off("click", window, clickedHandler, true);
+ clearTimer();
+ });
+ } else {
+ setup();
+ }
+ return readonly(clickedRef);
+}
+function useMergedState(controlledStateRef, uncontrolledStateRef) {
+ watch(controlledStateRef, (value) => {
+ if (value !== void 0) {
+ uncontrolledStateRef.value = value;
+ }
+ });
+ return computed(() => {
+ if (controlledStateRef.value === void 0) {
+ return uncontrolledStateRef.value;
+ }
+ return controlledStateRef.value;
+ });
+}
+function isMounted() {
+ const isMounted2 = ref(false);
+ onMounted(() => {
+ isMounted2.value = true;
+ });
+ return readonly(isMounted2);
+}
+function useCompitable(reactive2, keys) {
+ return computed(() => {
+ for (const key of keys) {
+ if (reactive2[key] !== void 0)
+ return reactive2[key];
+ }
+ return reactive2[keys[keys.length - 1]];
+ });
+}
+const isIos = (typeof window === "undefined" ? false : /iPad|iPhone|iPod/.test(navigator.platform) || navigator.platform === "MacIntel" && navigator.maxTouchPoints > 1) && // eslint-disable-next-line @typescript-eslint/strict-boolean-expressions
+!window.MSStream;
+function useIsIos() {
+ return isIos;
+}
+function createInjectionKey(key) {
+ return key;
+}
+const drawerBodyInjectionKey = createInjectionKey("n-drawer-body");
+const drawerInjectionKey = createInjectionKey("n-drawer");
+const modalBodyInjectionKey = createInjectionKey("n-modal-body");
+const modalProviderInjectionKey = createInjectionKey("n-modal-provider");
+const modalInjectionKey = createInjectionKey("n-modal");
+const popoverBodyInjectionKey = createInjectionKey("n-popover-body");
+const isBrowser$1 = typeof document !== "undefined" && typeof window !== "undefined";
+const isComposingRef = ref(false);
+function compositionStartHandler() {
+ isComposingRef.value = true;
+}
+function compositionEndHandler() {
+ isComposingRef.value = false;
+}
+let mountedCount = 0;
+function useIsComposing() {
+ if (isBrowser$1) {
+ onBeforeMount(() => {
+ if (!mountedCount) {
+ window.addEventListener("compositionstart", compositionStartHandler);
+ window.addEventListener("compositionend", compositionEndHandler);
+ }
+ mountedCount++;
+ });
+ onBeforeUnmount(() => {
+ if (mountedCount <= 1) {
+ window.removeEventListener("compositionstart", compositionStartHandler);
+ window.removeEventListener("compositionend", compositionEndHandler);
+ mountedCount = 0;
+ } else {
+ mountedCount--;
+ }
+ });
+ }
+ return isComposingRef;
+}
+let lockCount = 0;
+let originalMarginRight = "";
+let originalOverflow = "";
+let originalOverflowX = "";
+let originalOverflowY = "";
+const lockHtmlScrollRightCompensationRef = ref("0px");
+function useLockHtmlScroll(lockRef) {
+ if (typeof document === "undefined") return;
+ const el = document.documentElement;
+ let watchStopHandle;
+ let activated = false;
+ const unlock = () => {
+ el.style.marginRight = originalMarginRight;
+ el.style.overflow = originalOverflow;
+ el.style.overflowX = originalOverflowX;
+ el.style.overflowY = originalOverflowY;
+ lockHtmlScrollRightCompensationRef.value = "0px";
+ };
+ onMounted(() => {
+ watchStopHandle = watch(lockRef, (value) => {
+ if (value) {
+ if (!lockCount) {
+ const scrollbarWidth = window.innerWidth - el.offsetWidth;
+ if (scrollbarWidth > 0) {
+ originalMarginRight = el.style.marginRight;
+ el.style.marginRight = `${scrollbarWidth}px`;
+ lockHtmlScrollRightCompensationRef.value = `${scrollbarWidth}px`;
+ }
+ originalOverflow = el.style.overflow;
+ originalOverflowX = el.style.overflowX;
+ originalOverflowY = el.style.overflowY;
+ el.style.overflow = "hidden";
+ el.style.overflowX = "hidden";
+ el.style.overflowY = "hidden";
+ }
+ activated = true;
+ lockCount++;
+ } else {
+ lockCount--;
+ if (!lockCount) {
+ unlock();
+ }
+ activated = false;
+ }
+ }, {
+ immediate: true
+ });
+ });
+ onBeforeUnmount(() => {
+ watchStopHandle === null || watchStopHandle === void 0 ? void 0 : watchStopHandle();
+ if (activated) {
+ lockCount--;
+ if (!lockCount) {
+ unlock();
+ }
+ activated = false;
+ }
+ });
+}
+function useReactivated(callback) {
+ const isDeactivatedRef = {
+ isDeactivated: false
+ };
+ let activateStateInitialized = false;
+ onActivated(() => {
+ isDeactivatedRef.isDeactivated = false;
+ if (!activateStateInitialized) {
+ activateStateInitialized = true;
+ return;
+ }
+ callback();
+ });
+ onDeactivated(() => {
+ isDeactivatedRef.isDeactivated = true;
+ if (!activateStateInitialized) {
+ activateStateInitialized = true;
+ }
+ });
+ return isDeactivatedRef;
+}
+function getSlot(scope, slots, slotName = "default") {
+ const slot = slots[slotName];
+ if (slot === void 0) {
+ throw new Error(`[vueuc/${scope}]: slot[${slotName}] is empty.`);
+ }
+ return slot();
+}
+function flatten$1(vNodes, filterCommentNode = true, result = []) {
+ vNodes.forEach((vNode) => {
+ if (vNode === null)
+ return;
+ if (typeof vNode !== "object") {
+ if (typeof vNode === "string" || typeof vNode === "number") {
+ result.push(createTextVNode(String(vNode)));
+ }
+ return;
+ }
+ if (Array.isArray(vNode)) {
+ flatten$1(vNode, filterCommentNode, result);
+ return;
+ }
+ if (vNode.type === Fragment) {
+ if (vNode.children === null)
+ return;
+ if (Array.isArray(vNode.children)) {
+ flatten$1(vNode.children, filterCommentNode, result);
+ }
+ } else if (vNode.type !== Comment) {
+ result.push(vNode);
+ }
+ });
+ return result;
+}
+function getFirstVNode(scope, slots, slotName = "default") {
+ const slot = slots[slotName];
+ if (slot === void 0) {
+ throw new Error(`[vueuc/${scope}]: slot[${slotName}] is empty.`);
+ }
+ const content = flatten$1(slot());
+ if (content.length === 1) {
+ return content[0];
+ } else {
+ throw new Error(`[vueuc/${scope}]: slot[${slotName}] should have exactly one child.`);
+ }
+}
+const ctxKey = "@@coContext";
+const clickoutside = {
+ mounted(el, { value, modifiers }) {
+ el[ctxKey] = {
+ handler: void 0
+ };
+ if (typeof value === "function") {
+ el[ctxKey].handler = value;
+ on("clickoutside", el, value, {
+ capture: modifiers.capture
+ });
+ }
+ },
+ updated(el, { value, modifiers }) {
+ const ctx2 = el[ctxKey];
+ if (typeof value === "function") {
+ if (ctx2.handler) {
+ if (ctx2.handler !== value) {
+ off("clickoutside", el, ctx2.handler, {
+ capture: modifiers.capture
+ });
+ ctx2.handler = value;
+ on("clickoutside", el, value, {
+ capture: modifiers.capture
+ });
+ }
+ } else {
+ el[ctxKey].handler = value;
+ on("clickoutside", el, value, {
+ capture: modifiers.capture
+ });
+ }
+ } else {
+ if (ctx2.handler) {
+ off("clickoutside", el, ctx2.handler, {
+ capture: modifiers.capture
+ });
+ ctx2.handler = void 0;
+ }
+ }
+ },
+ unmounted(el, { modifiers }) {
+ const { handler } = el[ctxKey];
+ if (handler) {
+ off("clickoutside", el, handler, {
+ capture: modifiers.capture
+ });
+ }
+ el[ctxKey].handler = void 0;
+ }
+};
+function warn$2(location2, message) {
+ console.error(`[vdirs/${location2}]: ${message}`);
+}
+class ZIndexManager {
+ constructor() {
+ this.elementZIndex = /* @__PURE__ */ new Map();
+ this.nextZIndex = 2e3;
+ }
+ get elementCount() {
+ return this.elementZIndex.size;
+ }
+ ensureZIndex(el, zIndex) {
+ const { elementZIndex } = this;
+ if (zIndex !== void 0) {
+ el.style.zIndex = `${zIndex}`;
+ elementZIndex.delete(el);
+ return;
+ }
+ const { nextZIndex } = this;
+ if (elementZIndex.has(el)) {
+ const currentZIndex = elementZIndex.get(el);
+ if (currentZIndex + 1 === this.nextZIndex)
+ return;
+ }
+ el.style.zIndex = `${nextZIndex}`;
+ elementZIndex.set(el, nextZIndex);
+ this.nextZIndex = nextZIndex + 1;
+ this.squashState();
+ }
+ unregister(el, zIndex) {
+ const { elementZIndex } = this;
+ if (elementZIndex.has(el)) {
+ elementZIndex.delete(el);
+ } else if (zIndex === void 0) {
+ warn$2("z-index-manager/unregister-element", "Element not found when unregistering.");
+ }
+ this.squashState();
+ }
+ squashState() {
+ const { elementCount } = this;
+ if (!elementCount) {
+ this.nextZIndex = 2e3;
+ }
+ if (this.nextZIndex - elementCount > 2500)
+ this.rearrange();
+ }
+ rearrange() {
+ const elementZIndexPair = Array.from(this.elementZIndex.entries());
+ elementZIndexPair.sort((pair1, pair2) => {
+ return pair1[1] - pair2[1];
+ });
+ this.nextZIndex = 2e3;
+ elementZIndexPair.forEach((pair) => {
+ const el = pair[0];
+ const zIndex = this.nextZIndex++;
+ if (`${zIndex}` !== el.style.zIndex)
+ el.style.zIndex = `${zIndex}`;
+ });
+ }
+}
+const zIndexManager = new ZIndexManager();
+const ctx = "@@ziContext";
+const zindexable = {
+ mounted(el, bindings) {
+ const { value = {} } = bindings;
+ const { zIndex, enabled } = value;
+ el[ctx] = {
+ enabled: !!enabled,
+ initialized: false
+ };
+ if (enabled) {
+ zIndexManager.ensureZIndex(el, zIndex);
+ el[ctx].initialized = true;
+ }
+ },
+ updated(el, bindings) {
+ const { value = {} } = bindings;
+ const { zIndex, enabled } = value;
+ const cachedEnabled = el[ctx].enabled;
+ if (enabled && !cachedEnabled) {
+ zIndexManager.ensureZIndex(el, zIndex);
+ el[ctx].initialized = true;
+ }
+ el[ctx].enabled = !!enabled;
+ },
+ unmounted(el, bindings) {
+ if (!el[ctx].initialized)
+ return;
+ const { value = {} } = bindings;
+ const { zIndex } = value;
+ zIndexManager.unregister(el, zIndex);
+ }
+};
+const ssrContextKey = "@css-render/vue3-ssr";
+function createStyleString(id, style2) {
+ return ``;
+}
+function ssrAdapter(id, style2, ssrContext) {
+ const { styles, ids } = ssrContext;
+ if (ids.has(id))
+ return;
+ if (styles !== null) {
+ ids.add(id);
+ styles.push(createStyleString(id, style2));
+ }
+}
+const isBrowser = typeof document !== "undefined";
+function useSsrAdapter() {
+ if (isBrowser)
+ return void 0;
+ const context = inject(ssrContextKey, null);
+ if (context === null)
+ return void 0;
+ return {
+ adapter: (id, style2) => ssrAdapter(id, style2, context),
+ context
+ };
+}
+function warn$1(location2, message) {
+ console.error(`[vueuc/${location2}]: ${message}`);
+}
+function resolveTo(selector) {
+ if (typeof selector === "string") {
+ return document.querySelector(selector);
+ }
+ return selector();
+}
+const LazyTeleport = /* @__PURE__ */ defineComponent({
+ name: "LazyTeleport",
+ props: {
+ to: {
+ type: [String, Object],
+ default: void 0
+ },
+ disabled: Boolean,
+ show: {
+ type: Boolean,
+ required: true
+ }
+ },
+ setup(props) {
+ return {
+ showTeleport: useFalseUntilTruthy(toRef(props, "show")),
+ mergedTo: computed(() => {
+ const { to } = props;
+ return to !== null && to !== void 0 ? to : "body";
+ })
+ };
+ },
+ render() {
+ return this.showTeleport ? this.disabled ? getSlot("lazy-teleport", this.$slots) : h(Teleport, {
+ disabled: this.disabled,
+ to: this.mergedTo
+ }, getSlot("lazy-teleport", this.$slots)) : null;
+ }
+});
+var resizeObservers = [];
+var hasActiveObservations = function() {
+ return resizeObservers.some(function(ro) {
+ return ro.activeTargets.length > 0;
+ });
+};
+var hasSkippedObservations = function() {
+ return resizeObservers.some(function(ro) {
+ return ro.skippedTargets.length > 0;
+ });
+};
+var msg = "ResizeObserver loop completed with undelivered notifications.";
+var deliverResizeLoopError = function() {
+ var event;
+ if (typeof ErrorEvent === "function") {
+ event = new ErrorEvent("error", {
+ message: msg
+ });
+ } else {
+ event = document.createEvent("Event");
+ event.initEvent("error", false, false);
+ event.message = msg;
+ }
+ window.dispatchEvent(event);
+};
+var ResizeObserverBoxOptions;
+(function(ResizeObserverBoxOptions2) {
+ ResizeObserverBoxOptions2["BORDER_BOX"] = "border-box";
+ ResizeObserverBoxOptions2["CONTENT_BOX"] = "content-box";
+ ResizeObserverBoxOptions2["DEVICE_PIXEL_CONTENT_BOX"] = "device-pixel-content-box";
+})(ResizeObserverBoxOptions || (ResizeObserverBoxOptions = {}));
+var freeze = function(obj) {
+ return Object.freeze(obj);
+};
+var ResizeObserverSize = /* @__PURE__ */ function() {
+ function ResizeObserverSize2(inlineSize, blockSize) {
+ this.inlineSize = inlineSize;
+ this.blockSize = blockSize;
+ freeze(this);
+ }
+ return ResizeObserverSize2;
+}();
+var DOMRectReadOnly = function() {
+ function DOMRectReadOnly2(x, y, width, height) {
+ this.x = x;
+ this.y = y;
+ this.width = width;
+ this.height = height;
+ this.top = this.y;
+ this.left = this.x;
+ this.bottom = this.top + this.height;
+ this.right = this.left + this.width;
+ return freeze(this);
+ }
+ DOMRectReadOnly2.prototype.toJSON = function() {
+ var _a = this, x = _a.x, y = _a.y, top = _a.top, right = _a.right, bottom = _a.bottom, left = _a.left, width = _a.width, height = _a.height;
+ return { x, y, top, right, bottom, left, width, height };
+ };
+ DOMRectReadOnly2.fromRect = function(rectangle) {
+ return new DOMRectReadOnly2(rectangle.x, rectangle.y, rectangle.width, rectangle.height);
+ };
+ return DOMRectReadOnly2;
+}();
+var isSVG = function(target) {
+ return target instanceof SVGElement && "getBBox" in target;
+};
+var isHidden = function(target) {
+ if (isSVG(target)) {
+ var _a = target.getBBox(), width = _a.width, height = _a.height;
+ return !width && !height;
+ }
+ var _b = target, offsetWidth = _b.offsetWidth, offsetHeight = _b.offsetHeight;
+ return !(offsetWidth || offsetHeight || target.getClientRects().length);
+};
+var isElement = function(obj) {
+ var _a;
+ if (obj instanceof Element) {
+ return true;
+ }
+ var scope = (_a = obj === null || obj === void 0 ? void 0 : obj.ownerDocument) === null || _a === void 0 ? void 0 : _a.defaultView;
+ return !!(scope && obj instanceof scope.Element);
+};
+var isReplacedElement = function(target) {
+ switch (target.tagName) {
+ case "INPUT":
+ if (target.type !== "image") {
+ break;
+ }
+ case "VIDEO":
+ case "AUDIO":
+ case "EMBED":
+ case "OBJECT":
+ case "CANVAS":
+ case "IFRAME":
+ case "IMG":
+ return true;
+ }
+ return false;
+};
+var global$1 = typeof window !== "undefined" ? window : {};
+var cache = /* @__PURE__ */ new WeakMap();
+var scrollRegexp = /auto|scroll/;
+var verticalRegexp = /^tb|vertical/;
+var IE = /msie|trident/i.test(global$1.navigator && global$1.navigator.userAgent);
+var parseDimension = function(pixel) {
+ return parseFloat(pixel || "0");
+};
+var size = function(inlineSize, blockSize, switchSizes) {
+ if (inlineSize === void 0) {
+ inlineSize = 0;
+ }
+ if (blockSize === void 0) {
+ blockSize = 0;
+ }
+ if (switchSizes === void 0) {
+ switchSizes = false;
+ }
+ return new ResizeObserverSize((switchSizes ? blockSize : inlineSize) || 0, (switchSizes ? inlineSize : blockSize) || 0);
+};
+var zeroBoxes = freeze({
+ devicePixelContentBoxSize: size(),
+ borderBoxSize: size(),
+ contentBoxSize: size(),
+ contentRect: new DOMRectReadOnly(0, 0, 0, 0)
+});
+var calculateBoxSizes = function(target, forceRecalculation) {
+ if (forceRecalculation === void 0) {
+ forceRecalculation = false;
+ }
+ if (cache.has(target) && !forceRecalculation) {
+ return cache.get(target);
+ }
+ if (isHidden(target)) {
+ cache.set(target, zeroBoxes);
+ return zeroBoxes;
+ }
+ var cs = getComputedStyle(target);
+ var svg = isSVG(target) && target.ownerSVGElement && target.getBBox();
+ var removePadding = !IE && cs.boxSizing === "border-box";
+ var switchSizes = verticalRegexp.test(cs.writingMode || "");
+ var canScrollVertically = !svg && scrollRegexp.test(cs.overflowY || "");
+ var canScrollHorizontally = !svg && scrollRegexp.test(cs.overflowX || "");
+ var paddingTop = svg ? 0 : parseDimension(cs.paddingTop);
+ var paddingRight = svg ? 0 : parseDimension(cs.paddingRight);
+ var paddingBottom = svg ? 0 : parseDimension(cs.paddingBottom);
+ var paddingLeft = svg ? 0 : parseDimension(cs.paddingLeft);
+ var borderTop = svg ? 0 : parseDimension(cs.borderTopWidth);
+ var borderRight = svg ? 0 : parseDimension(cs.borderRightWidth);
+ var borderBottom = svg ? 0 : parseDimension(cs.borderBottomWidth);
+ var borderLeft = svg ? 0 : parseDimension(cs.borderLeftWidth);
+ var horizontalPadding = paddingLeft + paddingRight;
+ var verticalPadding = paddingTop + paddingBottom;
+ var horizontalBorderArea = borderLeft + borderRight;
+ var verticalBorderArea = borderTop + borderBottom;
+ var horizontalScrollbarThickness = !canScrollHorizontally ? 0 : target.offsetHeight - verticalBorderArea - target.clientHeight;
+ var verticalScrollbarThickness = !canScrollVertically ? 0 : target.offsetWidth - horizontalBorderArea - target.clientWidth;
+ var widthReduction = removePadding ? horizontalPadding + horizontalBorderArea : 0;
+ var heightReduction = removePadding ? verticalPadding + verticalBorderArea : 0;
+ var contentWidth = svg ? svg.width : parseDimension(cs.width) - widthReduction - verticalScrollbarThickness;
+ var contentHeight = svg ? svg.height : parseDimension(cs.height) - heightReduction - horizontalScrollbarThickness;
+ var borderBoxWidth = contentWidth + horizontalPadding + verticalScrollbarThickness + horizontalBorderArea;
+ var borderBoxHeight = contentHeight + verticalPadding + horizontalScrollbarThickness + verticalBorderArea;
+ var boxes = freeze({
+ devicePixelContentBoxSize: size(Math.round(contentWidth * devicePixelRatio), Math.round(contentHeight * devicePixelRatio), switchSizes),
+ borderBoxSize: size(borderBoxWidth, borderBoxHeight, switchSizes),
+ contentBoxSize: size(contentWidth, contentHeight, switchSizes),
+ contentRect: new DOMRectReadOnly(paddingLeft, paddingTop, contentWidth, contentHeight)
+ });
+ cache.set(target, boxes);
+ return boxes;
+};
+var calculateBoxSize = function(target, observedBox, forceRecalculation) {
+ var _a = calculateBoxSizes(target, forceRecalculation), borderBoxSize = _a.borderBoxSize, contentBoxSize = _a.contentBoxSize, devicePixelContentBoxSize = _a.devicePixelContentBoxSize;
+ switch (observedBox) {
+ case ResizeObserverBoxOptions.DEVICE_PIXEL_CONTENT_BOX:
+ return devicePixelContentBoxSize;
+ case ResizeObserverBoxOptions.BORDER_BOX:
+ return borderBoxSize;
+ default:
+ return contentBoxSize;
+ }
+};
+var ResizeObserverEntry = /* @__PURE__ */ function() {
+ function ResizeObserverEntry2(target) {
+ var boxes = calculateBoxSizes(target);
+ this.target = target;
+ this.contentRect = boxes.contentRect;
+ this.borderBoxSize = freeze([boxes.borderBoxSize]);
+ this.contentBoxSize = freeze([boxes.contentBoxSize]);
+ this.devicePixelContentBoxSize = freeze([boxes.devicePixelContentBoxSize]);
+ }
+ return ResizeObserverEntry2;
+}();
+var calculateDepthForNode = function(node) {
+ if (isHidden(node)) {
+ return Infinity;
+ }
+ var depth = 0;
+ var parent = node.parentNode;
+ while (parent) {
+ depth += 1;
+ parent = parent.parentNode;
+ }
+ return depth;
+};
+var broadcastActiveObservations = function() {
+ var shallowestDepth = Infinity;
+ var callbacks2 = [];
+ resizeObservers.forEach(function processObserver(ro) {
+ if (ro.activeTargets.length === 0) {
+ return;
+ }
+ var entries = [];
+ ro.activeTargets.forEach(function processTarget(ot) {
+ var entry = new ResizeObserverEntry(ot.target);
+ var targetDepth = calculateDepthForNode(ot.target);
+ entries.push(entry);
+ ot.lastReportedSize = calculateBoxSize(ot.target, ot.observedBox);
+ if (targetDepth < shallowestDepth) {
+ shallowestDepth = targetDepth;
+ }
+ });
+ callbacks2.push(function resizeObserverCallback() {
+ ro.callback.call(ro.observer, entries, ro.observer);
+ });
+ ro.activeTargets.splice(0, ro.activeTargets.length);
+ });
+ for (var _i = 0, callbacks_1 = callbacks2; _i < callbacks_1.length; _i++) {
+ var callback = callbacks_1[_i];
+ callback();
+ }
+ return shallowestDepth;
+};
+var gatherActiveObservationsAtDepth = function(depth) {
+ resizeObservers.forEach(function processObserver(ro) {
+ ro.activeTargets.splice(0, ro.activeTargets.length);
+ ro.skippedTargets.splice(0, ro.skippedTargets.length);
+ ro.observationTargets.forEach(function processTarget(ot) {
+ if (ot.isActive()) {
+ if (calculateDepthForNode(ot.target) > depth) {
+ ro.activeTargets.push(ot);
+ } else {
+ ro.skippedTargets.push(ot);
+ }
+ }
+ });
+ });
+};
+var process$1 = function() {
+ var depth = 0;
+ gatherActiveObservationsAtDepth(depth);
+ while (hasActiveObservations()) {
+ depth = broadcastActiveObservations();
+ gatherActiveObservationsAtDepth(depth);
+ }
+ if (hasSkippedObservations()) {
+ deliverResizeLoopError();
+ }
+ return depth > 0;
+};
+var trigger;
+var callbacks = [];
+var notify = function() {
+ return callbacks.splice(0).forEach(function(cb) {
+ return cb();
+ });
+};
+var queueMicroTask = function(callback) {
+ if (!trigger) {
+ var toggle_1 = 0;
+ var el_1 = document.createTextNode("");
+ var config2 = { characterData: true };
+ new MutationObserver(function() {
+ return notify();
+ }).observe(el_1, config2);
+ trigger = function() {
+ el_1.textContent = "".concat(toggle_1 ? toggle_1-- : toggle_1++);
+ };
+ }
+ callbacks.push(callback);
+ trigger();
+};
+var queueResizeObserver = function(cb) {
+ queueMicroTask(function ResizeObserver() {
+ requestAnimationFrame(cb);
+ });
+};
+var watching = 0;
+var isWatching = function() {
+ return !!watching;
+};
+var CATCH_PERIOD = 250;
+var observerConfig = { attributes: true, characterData: true, childList: true, subtree: true };
+var events = [
+ "resize",
+ "load",
+ "transitionend",
+ "animationend",
+ "animationstart",
+ "animationiteration",
+ "keyup",
+ "keydown",
+ "mouseup",
+ "mousedown",
+ "mouseover",
+ "mouseout",
+ "blur",
+ "focus"
+];
+var time = function(timeout) {
+ if (timeout === void 0) {
+ timeout = 0;
+ }
+ return Date.now() + timeout;
+};
+var scheduled = false;
+var Scheduler = function() {
+ function Scheduler2() {
+ var _this = this;
+ this.stopped = true;
+ this.listener = function() {
+ return _this.schedule();
+ };
+ }
+ Scheduler2.prototype.run = function(timeout) {
+ var _this = this;
+ if (timeout === void 0) {
+ timeout = CATCH_PERIOD;
+ }
+ if (scheduled) {
+ return;
+ }
+ scheduled = true;
+ var until = time(timeout);
+ queueResizeObserver(function() {
+ var elementsHaveResized = false;
+ try {
+ elementsHaveResized = process$1();
+ } finally {
+ scheduled = false;
+ timeout = until - time();
+ if (!isWatching()) {
+ return;
+ }
+ if (elementsHaveResized) {
+ _this.run(1e3);
+ } else if (timeout > 0) {
+ _this.run(timeout);
+ } else {
+ _this.start();
+ }
+ }
+ });
+ };
+ Scheduler2.prototype.schedule = function() {
+ this.stop();
+ this.run();
+ };
+ Scheduler2.prototype.observe = function() {
+ var _this = this;
+ var cb = function() {
+ return _this.observer && _this.observer.observe(document.body, observerConfig);
+ };
+ document.body ? cb() : global$1.addEventListener("DOMContentLoaded", cb);
+ };
+ Scheduler2.prototype.start = function() {
+ var _this = this;
+ if (this.stopped) {
+ this.stopped = false;
+ this.observer = new MutationObserver(this.listener);
+ this.observe();
+ events.forEach(function(name2) {
+ return global$1.addEventListener(name2, _this.listener, true);
+ });
+ }
+ };
+ Scheduler2.prototype.stop = function() {
+ var _this = this;
+ if (!this.stopped) {
+ this.observer && this.observer.disconnect();
+ events.forEach(function(name2) {
+ return global$1.removeEventListener(name2, _this.listener, true);
+ });
+ this.stopped = true;
+ }
+ };
+ return Scheduler2;
+}();
+var scheduler = new Scheduler();
+var updateCount = function(n) {
+ !watching && n > 0 && scheduler.start();
+ watching += n;
+ !watching && scheduler.stop();
+};
+var skipNotifyOnElement = function(target) {
+ return !isSVG(target) && !isReplacedElement(target) && getComputedStyle(target).display === "inline";
+};
+var ResizeObservation = function() {
+ function ResizeObservation2(target, observedBox) {
+ this.target = target;
+ this.observedBox = observedBox || ResizeObserverBoxOptions.CONTENT_BOX;
+ this.lastReportedSize = {
+ inlineSize: 0,
+ blockSize: 0
+ };
+ }
+ ResizeObservation2.prototype.isActive = function() {
+ var size2 = calculateBoxSize(this.target, this.observedBox, true);
+ if (skipNotifyOnElement(this.target)) {
+ this.lastReportedSize = size2;
+ }
+ if (this.lastReportedSize.inlineSize !== size2.inlineSize || this.lastReportedSize.blockSize !== size2.blockSize) {
+ return true;
+ }
+ return false;
+ };
+ return ResizeObservation2;
+}();
+var ResizeObserverDetail = /* @__PURE__ */ function() {
+ function ResizeObserverDetail2(resizeObserver, callback) {
+ this.activeTargets = [];
+ this.skippedTargets = [];
+ this.observationTargets = [];
+ this.observer = resizeObserver;
+ this.callback = callback;
+ }
+ return ResizeObserverDetail2;
+}();
+var observerMap = /* @__PURE__ */ new WeakMap();
+var getObservationIndex = function(observationTargets, target) {
+ for (var i = 0; i < observationTargets.length; i += 1) {
+ if (observationTargets[i].target === target) {
+ return i;
+ }
+ }
+ return -1;
+};
+var ResizeObserverController = function() {
+ function ResizeObserverController2() {
+ }
+ ResizeObserverController2.connect = function(resizeObserver, callback) {
+ var detail = new ResizeObserverDetail(resizeObserver, callback);
+ observerMap.set(resizeObserver, detail);
+ };
+ ResizeObserverController2.observe = function(resizeObserver, target, options) {
+ var detail = observerMap.get(resizeObserver);
+ var firstObservation = detail.observationTargets.length === 0;
+ if (getObservationIndex(detail.observationTargets, target) < 0) {
+ firstObservation && resizeObservers.push(detail);
+ detail.observationTargets.push(new ResizeObservation(target, options && options.box));
+ updateCount(1);
+ scheduler.schedule();
+ }
+ };
+ ResizeObserverController2.unobserve = function(resizeObserver, target) {
+ var detail = observerMap.get(resizeObserver);
+ var index = getObservationIndex(detail.observationTargets, target);
+ var lastObservation = detail.observationTargets.length === 1;
+ if (index >= 0) {
+ lastObservation && resizeObservers.splice(resizeObservers.indexOf(detail), 1);
+ detail.observationTargets.splice(index, 1);
+ updateCount(-1);
+ }
+ };
+ ResizeObserverController2.disconnect = function(resizeObserver) {
+ var _this = this;
+ var detail = observerMap.get(resizeObserver);
+ detail.observationTargets.slice().forEach(function(ot) {
+ return _this.unobserve(resizeObserver, ot.target);
+ });
+ detail.activeTargets.splice(0, detail.activeTargets.length);
+ };
+ return ResizeObserverController2;
+}();
+var ResizeObserver$1 = function() {
+ function ResizeObserver(callback) {
+ if (arguments.length === 0) {
+ throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");
+ }
+ if (typeof callback !== "function") {
+ throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");
+ }
+ ResizeObserverController.connect(this, callback);
+ }
+ ResizeObserver.prototype.observe = function(target, options) {
+ if (arguments.length === 0) {
+ throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");
+ }
+ if (!isElement(target)) {
+ throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");
+ }
+ ResizeObserverController.observe(this, target, options);
+ };
+ ResizeObserver.prototype.unobserve = function(target) {
+ if (arguments.length === 0) {
+ throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");
+ }
+ if (!isElement(target)) {
+ throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");
+ }
+ ResizeObserverController.unobserve(this, target);
+ };
+ ResizeObserver.prototype.disconnect = function() {
+ ResizeObserverController.disconnect(this);
+ };
+ ResizeObserver.toString = function() {
+ return "function ResizeObserver () { [polyfill code] }";
+ };
+ return ResizeObserver;
+}();
+class ResizeObserverDelegate {
+ constructor() {
+ this.handleResize = this.handleResize.bind(this);
+ this.observer = new (typeof window !== "undefined" && window.ResizeObserver || ResizeObserver$1)(this.handleResize);
+ this.elHandlersMap = /* @__PURE__ */ new Map();
+ }
+ handleResize(entries) {
+ for (const entry of entries) {
+ const handler = this.elHandlersMap.get(entry.target);
+ if (handler !== void 0) {
+ handler(entry);
+ }
+ }
+ }
+ registerHandler(el, handler) {
+ this.elHandlersMap.set(el, handler);
+ this.observer.observe(el);
+ }
+ unregisterHandler(el) {
+ if (!this.elHandlersMap.has(el)) {
+ return;
+ }
+ this.elHandlersMap.delete(el);
+ this.observer.unobserve(el);
+ }
+}
+const resizeObserverManager = new ResizeObserverDelegate();
+const VResizeObserver = /* @__PURE__ */ defineComponent({
+ name: "ResizeObserver",
+ props: {
+ onResize: Function
+ },
+ setup(props) {
+ let registered = false;
+ const proxy = getCurrentInstance().proxy;
+ function handleResize(entry) {
+ const { onResize } = props;
+ if (onResize !== void 0)
+ onResize(entry);
+ }
+ onMounted(() => {
+ const el = proxy.$el;
+ if (el === void 0) {
+ warn$1("resize-observer", "$el does not exist.");
+ return;
+ }
+ if (el.nextElementSibling !== el.nextSibling) {
+ if (el.nodeType === 3 && el.nodeValue !== "") {
+ warn$1("resize-observer", "$el can not be observed (it may be a text node).");
+ return;
+ }
+ }
+ if (el.nextElementSibling !== null) {
+ resizeObserverManager.registerHandler(el.nextElementSibling, handleResize);
+ registered = true;
+ }
+ });
+ onBeforeUnmount(() => {
+ if (registered) {
+ resizeObserverManager.unregisterHandler(proxy.$el.nextElementSibling);
+ }
+ });
+ },
+ render() {
+ return renderSlot(this.$slots, "default");
+ }
+});
+function isHTMLElement(node) {
+ return node instanceof HTMLElement;
+}
+function focusFirstDescendant(node) {
+ for (let i = 0; i < node.childNodes.length; i++) {
+ const child = node.childNodes[i];
+ if (isHTMLElement(child)) {
+ if (attemptFocus(child) || focusFirstDescendant(child)) {
+ return true;
+ }
+ }
+ }
+ return false;
+}
+function focusLastDescendant(element) {
+ for (let i = element.childNodes.length - 1; i >= 0; i--) {
+ const child = element.childNodes[i];
+ if (isHTMLElement(child)) {
+ if (attemptFocus(child) || focusLastDescendant(child)) {
+ return true;
+ }
+ }
+ }
+ return false;
+}
+function attemptFocus(element) {
+ if (!isFocusable(element)) {
+ return false;
+ }
+ try {
+ element.focus({ preventScroll: true });
+ } catch (e) {
+ }
+ return document.activeElement === element;
+}
+function isFocusable(element) {
+ if (element.tabIndex > 0 || element.tabIndex === 0 && element.getAttribute("tabIndex") !== null) {
+ return true;
+ }
+ if (element.getAttribute("disabled")) {
+ return false;
+ }
+ switch (element.nodeName) {
+ case "A":
+ return !!element.href && element.rel !== "ignore";
+ case "INPUT":
+ return element.type !== "hidden" && element.type !== "file";
+ case "BUTTON":
+ case "SELECT":
+ case "TEXTAREA":
+ return true;
+ default:
+ return false;
+ }
+}
+let stack = [];
+const FocusTrap = /* @__PURE__ */ defineComponent({
+ name: "FocusTrap",
+ props: {
+ disabled: Boolean,
+ active: Boolean,
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ onEsc: Function,
+ initialFocusTo: String,
+ finalFocusTo: String,
+ returnFocusOnDeactivated: {
+ type: Boolean,
+ default: true
+ }
+ },
+ setup(props) {
+ const id = createId();
+ const focusableStartRef = ref(null);
+ const focusableEndRef = ref(null);
+ let activated = false;
+ let ignoreInternalFocusChange = false;
+ const lastFocusedElement = typeof document === "undefined" ? null : document.activeElement;
+ function isCurrentActive() {
+ const currentActiveId = stack[stack.length - 1];
+ return currentActiveId === id;
+ }
+ function handleDocumentKeydown(e) {
+ var _a;
+ if (e.code === "Escape") {
+ if (isCurrentActive()) {
+ (_a = props.onEsc) === null || _a === void 0 ? void 0 : _a.call(props, e);
+ }
+ }
+ }
+ onMounted(() => {
+ watch(() => props.active, (value) => {
+ if (value) {
+ activate();
+ on("keydown", document, handleDocumentKeydown);
+ } else {
+ off("keydown", document, handleDocumentKeydown);
+ if (activated) {
+ deactivate();
+ }
+ }
+ }, {
+ immediate: true
+ });
+ });
+ onBeforeUnmount(() => {
+ off("keydown", document, handleDocumentKeydown);
+ if (activated)
+ deactivate();
+ });
+ function handleDocumentFocus(e) {
+ if (ignoreInternalFocusChange)
+ return;
+ if (isCurrentActive()) {
+ const mainEl = getMainEl();
+ if (mainEl === null)
+ return;
+ if (mainEl.contains(getPreciseEventTarget(e)))
+ return;
+ resetFocusTo("first");
+ }
+ }
+ function getMainEl() {
+ const focusableStartEl = focusableStartRef.value;
+ if (focusableStartEl === null)
+ return null;
+ let mainEl = focusableStartEl;
+ while (true) {
+ mainEl = mainEl.nextSibling;
+ if (mainEl === null)
+ break;
+ if (mainEl instanceof Element && mainEl.tagName === "DIV") {
+ break;
+ }
+ }
+ return mainEl;
+ }
+ function activate() {
+ var _a;
+ if (props.disabled)
+ return;
+ stack.push(id);
+ if (props.autoFocus) {
+ const { initialFocusTo } = props;
+ if (initialFocusTo === void 0) {
+ resetFocusTo("first");
+ } else {
+ (_a = resolveTo(initialFocusTo)) === null || _a === void 0 ? void 0 : _a.focus({ preventScroll: true });
+ }
+ }
+ activated = true;
+ document.addEventListener("focus", handleDocumentFocus, true);
+ }
+ function deactivate() {
+ var _a;
+ if (props.disabled)
+ return;
+ document.removeEventListener("focus", handleDocumentFocus, true);
+ stack = stack.filter((idInStack) => idInStack !== id);
+ if (isCurrentActive())
+ return;
+ const { finalFocusTo } = props;
+ if (finalFocusTo !== void 0) {
+ (_a = resolveTo(finalFocusTo)) === null || _a === void 0 ? void 0 : _a.focus({ preventScroll: true });
+ } else if (props.returnFocusOnDeactivated) {
+ if (lastFocusedElement instanceof HTMLElement) {
+ ignoreInternalFocusChange = true;
+ lastFocusedElement.focus({ preventScroll: true });
+ ignoreInternalFocusChange = false;
+ }
+ }
+ }
+ function resetFocusTo(target) {
+ if (!isCurrentActive())
+ return;
+ if (props.active) {
+ const focusableStartEl = focusableStartRef.value;
+ const focusableEndEl = focusableEndRef.value;
+ if (focusableStartEl !== null && focusableEndEl !== null) {
+ const mainEl = getMainEl();
+ if (mainEl == null || mainEl === focusableEndEl) {
+ ignoreInternalFocusChange = true;
+ focusableStartEl.focus({ preventScroll: true });
+ ignoreInternalFocusChange = false;
+ return;
+ }
+ ignoreInternalFocusChange = true;
+ const focused = target === "first" ? focusFirstDescendant(mainEl) : focusLastDescendant(mainEl);
+ ignoreInternalFocusChange = false;
+ if (!focused) {
+ ignoreInternalFocusChange = true;
+ focusableStartEl.focus({ preventScroll: true });
+ ignoreInternalFocusChange = false;
+ }
+ }
+ }
+ }
+ function handleStartFocus(e) {
+ if (ignoreInternalFocusChange)
+ return;
+ const mainEl = getMainEl();
+ if (mainEl === null)
+ return;
+ if (e.relatedTarget !== null && mainEl.contains(e.relatedTarget)) {
+ resetFocusTo("last");
+ } else {
+ resetFocusTo("first");
+ }
+ }
+ function handleEndFocus(e) {
+ if (ignoreInternalFocusChange)
+ return;
+ if (e.relatedTarget !== null && e.relatedTarget === focusableStartRef.value) {
+ resetFocusTo("last");
+ } else {
+ resetFocusTo("first");
+ }
+ }
+ return {
+ focusableStartRef,
+ focusableEndRef,
+ focusableStyle: "position: absolute; height: 0; width: 0;",
+ handleStartFocus,
+ handleEndFocus
+ };
+ },
+ render() {
+ const { default: defaultSlot } = this.$slots;
+ if (defaultSlot === void 0)
+ return null;
+ if (this.disabled)
+ return defaultSlot();
+ const { active, focusableStyle } = this;
+ return h(Fragment, null, [
+ h("div", {
+ "aria-hidden": "true",
+ tabindex: active ? "0" : "-1",
+ ref: "focusableStartRef",
+ style: focusableStyle,
+ onFocus: this.handleStartFocus
+ }),
+ defaultSlot(),
+ h("div", {
+ "aria-hidden": "true",
+ style: focusableStyle,
+ ref: "focusableEndRef",
+ tabindex: active ? "0" : "-1",
+ onFocus: this.handleEndFocus
+ })
+ ]);
+ }
+});
+function color2Class(color) {
+ return color.replace(/#|\(|\)|,|\s|\./g, "_");
+}
+function rtlInset(inset) {
+ const {
+ left,
+ right,
+ top,
+ bottom
+ } = getMargin(inset);
+ return `${top} ${left} ${bottom} ${right}`;
+}
+const eventSet = /* @__PURE__ */ new WeakSet();
+function eventEffectNotPerformed(event) {
+ return !eventSet.has(event);
+}
+function warn(location2, message) {
+ console.error(`[naive/${location2}]: ${message}`);
+}
+function throwError(location2, message) {
+ throw new Error(`[naive/${location2}]: ${message}`);
+}
+function call(funcs, ...args) {
+ if (Array.isArray(funcs)) {
+ funcs.forEach((func) => call(func, ...args));
+ } else {
+ return funcs(...args);
+ }
+}
+function flatten(vNodes, filterCommentNode = true, result = []) {
+ vNodes.forEach((vNode) => {
+ if (vNode === null) return;
+ if (typeof vNode !== "object") {
+ if (typeof vNode === "string" || typeof vNode === "number") {
+ result.push(createTextVNode(String(vNode)));
+ }
+ return;
+ }
+ if (Array.isArray(vNode)) {
+ flatten(vNode, filterCommentNode, result);
+ return;
+ }
+ if (vNode.type === Fragment) {
+ if (vNode.children === null) return;
+ if (Array.isArray(vNode.children)) {
+ flatten(vNode.children, filterCommentNode, result);
+ }
+ } else {
+ if (vNode.type === Comment && filterCommentNode) return;
+ result.push(vNode);
+ }
+ });
+ return result;
+}
+function getFirstSlotVNode(slots, slotName = "default", props = void 0) {
+ const slot = slots[slotName];
+ if (!slot) {
+ warn("getFirstSlotVNode", `slot[${slotName}] is empty`);
+ return null;
+ }
+ const slotContent = flatten(slot(props));
+ if (slotContent.length === 1) {
+ return slotContent[0];
+ } else {
+ warn("getFirstSlotVNode", `slot[${slotName}] should have exactly one child`);
+ return null;
+ }
+}
+function keep(object, keys = [], rest) {
+ const keepedObject = {};
+ keys.forEach((key) => {
+ keepedObject[key] = object[key];
+ });
+ return Object.assign(keepedObject, rest);
+}
+function keysOf(obj) {
+ return Object.keys(obj);
+}
+function omit(object, keys = [], rest) {
+ const omitedObject = {};
+ const originalKeys = Object.getOwnPropertyNames(object);
+ originalKeys.forEach((originalKey) => {
+ if (!keys.includes(originalKey)) {
+ omitedObject[originalKey] = object[originalKey];
+ }
+ });
+ return Object.assign(omitedObject, rest);
+}
+function render(r, ...args) {
+ if (typeof r === "function") {
+ return r(...args);
+ } else if (typeof r === "string") {
+ return createTextVNode(r);
+ } else if (typeof r === "number") {
+ return createTextVNode(String(r));
+ } else {
+ return null;
+ }
+}
+function ensureValidVNode(vnodes) {
+ return vnodes.some((child) => {
+ if (!isVNode(child)) {
+ return true;
+ }
+ if (child.type === Comment) {
+ return false;
+ }
+ if (child.type === Fragment && !ensureValidVNode(child.children)) {
+ return false;
+ }
+ return true;
+ }) ? vnodes : null;
+}
+function resolveSlot(slot, fallback) {
+ return slot && ensureValidVNode(slot()) || fallback();
+}
+function resolveSlotWithProps(slot, props, fallback) {
+ return slot && ensureValidVNode(slot(props)) || fallback(props);
+}
+function resolveWrappedSlot(slot, wrapper) {
+ const children = slot && ensureValidVNode(slot());
+ return wrapper(children || null);
+}
+function isSlotEmpty(slot) {
+ return !(slot && ensureValidVNode(slot()));
+}
+const Wrapper = /* @__PURE__ */ defineComponent({
+ render() {
+ var _a, _b;
+ return (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a);
+ }
+});
+const configProviderInjectionKey = createInjectionKey("n-config-provider");
+const defaultClsPrefix = "n";
+function useConfig(props = {}, options = {
+ defaultBordered: true
+}) {
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ return {
+ // NConfigProvider,
+ inlineThemeDisabled: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.inlineThemeDisabled,
+ mergedRtlRef: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedRtlRef,
+ mergedComponentPropsRef: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedComponentPropsRef,
+ mergedBreakpointsRef: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedBreakpointsRef,
+ mergedBorderedRef: computed(() => {
+ var _a, _b;
+ const {
+ bordered
+ } = props;
+ if (bordered !== void 0) return bordered;
+ return (_b = (_a = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedBorderedRef.value) !== null && _a !== void 0 ? _a : options.defaultBordered) !== null && _b !== void 0 ? _b : true;
+ }),
+ mergedClsPrefixRef: NConfigProvider ? NConfigProvider.mergedClsPrefixRef : shallowRef(defaultClsPrefix),
+ namespaceRef: computed(() => NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedNamespaceRef.value)
+ };
+}
+function useMergedClsPrefix() {
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ return NConfigProvider ? NConfigProvider.mergedClsPrefixRef : shallowRef(defaultClsPrefix);
+}
+function useThemeClass(componentName, hashRef, cssVarsRef, props) {
+ if (!cssVarsRef) throwError("useThemeClass", "cssVarsRef is not passed");
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ const mergedThemeHashRef = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeHashRef;
+ const styleMountTarget = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget;
+ const themeClassRef = ref("");
+ const ssrAdapter2 = useSsrAdapter();
+ let renderCallback;
+ const hashClassPrefix = `__${componentName}`;
+ const mountStyle = () => {
+ let finalThemeHash = hashClassPrefix;
+ const hashValue = hashRef ? hashRef.value : void 0;
+ const themeHash = mergedThemeHashRef === null || mergedThemeHashRef === void 0 ? void 0 : mergedThemeHashRef.value;
+ if (themeHash) finalThemeHash += `-${themeHash}`;
+ if (hashValue) finalThemeHash += `-${hashValue}`;
+ const {
+ themeOverrides,
+ builtinThemeOverrides
+ } = props;
+ if (themeOverrides) {
+ finalThemeHash += `-${murmur2(JSON.stringify(themeOverrides))}`;
+ }
+ if (builtinThemeOverrides) {
+ finalThemeHash += `-${murmur2(JSON.stringify(builtinThemeOverrides))}`;
+ }
+ themeClassRef.value = finalThemeHash;
+ renderCallback = () => {
+ const cssVars = cssVarsRef.value;
+ let style2 = "";
+ for (const key in cssVars) {
+ style2 += `${key}: ${cssVars[key]};`;
+ }
+ c(`.${finalThemeHash}`, style2).mount({
+ id: finalThemeHash,
+ ssr: ssrAdapter2,
+ parent: styleMountTarget
+ });
+ renderCallback = void 0;
+ };
+ };
+ watchEffect(() => {
+ mountStyle();
+ });
+ return {
+ themeClass: themeClassRef,
+ onRender: () => {
+ renderCallback === null || renderCallback === void 0 ? void 0 : renderCallback();
+ }
+ };
+}
+const formItemInjectionKey = createInjectionKey("n-form-item");
+function useFormItem(props, {
+ defaultSize = "medium",
+ mergedSize,
+ mergedDisabled
+} = {}) {
+ const NFormItem = inject(formItemInjectionKey, null);
+ provide(formItemInjectionKey, null);
+ const mergedSizeRef = computed(mergedSize ? () => mergedSize(NFormItem) : () => {
+ const {
+ size: size2
+ } = props;
+ if (size2) return size2;
+ if (NFormItem) {
+ const {
+ mergedSize: mergedSize2
+ } = NFormItem;
+ if (mergedSize2.value !== void 0) {
+ return mergedSize2.value;
+ }
+ }
+ return defaultSize;
+ });
+ const mergedDisabledRef = computed(mergedDisabled ? () => mergedDisabled(NFormItem) : () => {
+ const {
+ disabled
+ } = props;
+ if (disabled !== void 0) {
+ return disabled;
+ }
+ if (NFormItem) {
+ return NFormItem.disabled.value;
+ }
+ return false;
+ });
+ const mergedStatusRef = computed(() => {
+ const {
+ status
+ } = props;
+ if (status) return status;
+ return NFormItem === null || NFormItem === void 0 ? void 0 : NFormItem.mergedValidationStatus.value;
+ });
+ onBeforeUnmount(() => {
+ if (NFormItem) {
+ NFormItem.restoreValidation();
+ }
+ });
+ return {
+ mergedSizeRef,
+ mergedDisabledRef,
+ mergedStatusRef,
+ nTriggerFormBlur() {
+ if (NFormItem) {
+ NFormItem.handleContentBlur();
+ }
+ },
+ nTriggerFormChange() {
+ if (NFormItem) {
+ NFormItem.handleContentChange();
+ }
+ },
+ nTriggerFormFocus() {
+ if (NFormItem) {
+ NFormItem.handleContentFocus();
+ }
+ },
+ nTriggerFormInput() {
+ if (NFormItem) {
+ NFormItem.handleContentInput();
+ }
+ }
+ };
+}
+var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
+var freeSelf = typeof self == "object" && self && self.Object === Object && self;
+var root = freeGlobal || freeSelf || Function("return this")();
+var Symbol$1 = root.Symbol;
+var objectProto$a = Object.prototype;
+var hasOwnProperty$9 = objectProto$a.hasOwnProperty;
+var nativeObjectToString$1 = objectProto$a.toString;
+var symToStringTag$1 = Symbol$1 ? Symbol$1.toStringTag : void 0;
+function getRawTag(value) {
+ var isOwn = hasOwnProperty$9.call(value, symToStringTag$1), tag2 = value[symToStringTag$1];
+ try {
+ value[symToStringTag$1] = void 0;
+ var unmasked = true;
+ } catch (e) {
+ }
+ var result = nativeObjectToString$1.call(value);
+ if (unmasked) {
+ if (isOwn) {
+ value[symToStringTag$1] = tag2;
+ } else {
+ delete value[symToStringTag$1];
+ }
+ }
+ return result;
+}
+var objectProto$9 = Object.prototype;
+var nativeObjectToString = objectProto$9.toString;
+function objectToString(value) {
+ return nativeObjectToString.call(value);
+}
+var nullTag = "[object Null]", undefinedTag = "[object Undefined]";
+var symToStringTag = Symbol$1 ? Symbol$1.toStringTag : void 0;
+function baseGetTag(value) {
+ if (value == null) {
+ return value === void 0 ? undefinedTag : nullTag;
+ }
+ return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
+}
+function isObjectLike(value) {
+ return value != null && typeof value == "object";
+}
+var symbolTag = "[object Symbol]";
+function isSymbol(value) {
+ return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
+}
+function arrayMap(array, iteratee) {
+ var index = -1, length = array == null ? 0 : array.length, result = Array(length);
+ while (++index < length) {
+ result[index] = iteratee(array[index], index, array);
+ }
+ return result;
+}
+var isArray$1 = Array.isArray;
+var INFINITY = 1 / 0;
+var symbolProto = Symbol$1 ? Symbol$1.prototype : void 0, symbolToString = symbolProto ? symbolProto.toString : void 0;
+function baseToString(value) {
+ if (typeof value == "string") {
+ return value;
+ }
+ if (isArray$1(value)) {
+ return arrayMap(value, baseToString) + "";
+ }
+ if (isSymbol(value)) {
+ return symbolToString ? symbolToString.call(value) : "";
+ }
+ var result = value + "";
+ return result == "0" && 1 / value == -INFINITY ? "-0" : result;
+}
+function isObject$2(value) {
+ var type = typeof value;
+ return value != null && (type == "object" || type == "function");
+}
+function identity(value) {
+ return value;
+}
+var asyncTag = "[object AsyncFunction]", funcTag$1 = "[object Function]", genTag = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
+function isFunction$1(value) {
+ if (!isObject$2(value)) {
+ return false;
+ }
+ var tag2 = baseGetTag(value);
+ return tag2 == funcTag$1 || tag2 == genTag || tag2 == asyncTag || tag2 == proxyTag;
+}
+var coreJsData = root["__core-js_shared__"];
+var maskSrcKey = function() {
+ var uid2 = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
+ return uid2 ? "Symbol(src)_1." + uid2 : "";
+}();
+function isMasked(func) {
+ return !!maskSrcKey && maskSrcKey in func;
+}
+var funcProto$2 = Function.prototype;
+var funcToString$2 = funcProto$2.toString;
+function toSource(func) {
+ if (func != null) {
+ try {
+ return funcToString$2.call(func);
+ } catch (e) {
+ }
+ try {
+ return func + "";
+ } catch (e) {
+ }
+ }
+ return "";
+}
+var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
+var reIsHostCtor = /^\[object .+?Constructor\]$/;
+var funcProto$1 = Function.prototype, objectProto$8 = Object.prototype;
+var funcToString$1 = funcProto$1.toString;
+var hasOwnProperty$8 = objectProto$8.hasOwnProperty;
+var reIsNative = RegExp(
+ "^" + funcToString$1.call(hasOwnProperty$8).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
+);
+function baseIsNative(value) {
+ if (!isObject$2(value) || isMasked(value)) {
+ return false;
+ }
+ var pattern = isFunction$1(value) ? reIsNative : reIsHostCtor;
+ return pattern.test(toSource(value));
+}
+function getValue(object, key) {
+ return object == null ? void 0 : object[key];
+}
+function getNative(object, key) {
+ var value = getValue(object, key);
+ return baseIsNative(value) ? value : void 0;
+}
+var objectCreate = Object.create;
+var baseCreate = /* @__PURE__ */ function() {
+ function object() {
+ }
+ return function(proto) {
+ if (!isObject$2(proto)) {
+ return {};
+ }
+ if (objectCreate) {
+ return objectCreate(proto);
+ }
+ object.prototype = proto;
+ var result = new object();
+ object.prototype = void 0;
+ return result;
+ };
+}();
+function apply(func, thisArg, args) {
+ switch (args.length) {
+ case 0:
+ return func.call(thisArg);
+ case 1:
+ return func.call(thisArg, args[0]);
+ case 2:
+ return func.call(thisArg, args[0], args[1]);
+ case 3:
+ return func.call(thisArg, args[0], args[1], args[2]);
+ }
+ return func.apply(thisArg, args);
+}
+function copyArray(source, array) {
+ var index = -1, length = source.length;
+ array || (array = Array(length));
+ while (++index < length) {
+ array[index] = source[index];
+ }
+ return array;
+}
+var HOT_COUNT = 800, HOT_SPAN = 16;
+var nativeNow = Date.now;
+function shortOut(func) {
+ var count = 0, lastCalled = 0;
+ return function() {
+ var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled);
+ lastCalled = stamp;
+ if (remaining > 0) {
+ if (++count >= HOT_COUNT) {
+ return arguments[0];
+ }
+ } else {
+ count = 0;
+ }
+ return func.apply(void 0, arguments);
+ };
+}
+function constant(value) {
+ return function() {
+ return value;
+ };
+}
+var defineProperty = function() {
+ try {
+ var func = getNative(Object, "defineProperty");
+ func({}, "", {});
+ return func;
+ } catch (e) {
+ }
+}();
+var baseSetToString = !defineProperty ? identity : function(func, string) {
+ return defineProperty(func, "toString", {
+ "configurable": true,
+ "enumerable": false,
+ "value": constant(string),
+ "writable": true
+ });
+};
+var setToString = shortOut(baseSetToString);
+var MAX_SAFE_INTEGER$1 = 9007199254740991;
+var reIsUint = /^(?:0|[1-9]\d*)$/;
+function isIndex(value, length) {
+ var type = typeof value;
+ length = length == null ? MAX_SAFE_INTEGER$1 : length;
+ return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
+}
+function baseAssignValue(object, key, value) {
+ if (key == "__proto__" && defineProperty) {
+ defineProperty(object, key, {
+ "configurable": true,
+ "enumerable": true,
+ "value": value,
+ "writable": true
+ });
+ } else {
+ object[key] = value;
+ }
+}
+function eq(value, other2) {
+ return value === other2 || value !== value && other2 !== other2;
+}
+var objectProto$7 = Object.prototype;
+var hasOwnProperty$7 = objectProto$7.hasOwnProperty;
+function assignValue(object, key, value) {
+ var objValue = object[key];
+ if (!(hasOwnProperty$7.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) {
+ baseAssignValue(object, key, value);
+ }
+}
+function copyObject(source, props, object, customizer) {
+ var isNew = !object;
+ object || (object = {});
+ var index = -1, length = props.length;
+ while (++index < length) {
+ var key = props[index];
+ var newValue = void 0;
+ if (newValue === void 0) {
+ newValue = source[key];
+ }
+ if (isNew) {
+ baseAssignValue(object, key, newValue);
+ } else {
+ assignValue(object, key, newValue);
+ }
+ }
+ return object;
+}
+var nativeMax = Math.max;
+function overRest(func, start, transform) {
+ start = nativeMax(start === void 0 ? func.length - 1 : start, 0);
+ return function() {
+ var args = arguments, index = -1, length = nativeMax(args.length - start, 0), array = Array(length);
+ while (++index < length) {
+ array[index] = args[start + index];
+ }
+ index = -1;
+ var otherArgs = Array(start + 1);
+ while (++index < start) {
+ otherArgs[index] = args[index];
+ }
+ otherArgs[start] = transform(array);
+ return apply(func, this, otherArgs);
+ };
+}
+function baseRest(func, start) {
+ return setToString(overRest(func, start, identity), func + "");
+}
+var MAX_SAFE_INTEGER = 9007199254740991;
+function isLength(value) {
+ return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
+}
+function isArrayLike(value) {
+ return value != null && isLength(value.length) && !isFunction$1(value);
+}
+function isIterateeCall(value, index, object) {
+ if (!isObject$2(object)) {
+ return false;
+ }
+ var type = typeof index;
+ if (type == "number" ? isArrayLike(object) && isIndex(index, object.length) : type == "string" && index in object) {
+ return eq(object[index], value);
+ }
+ return false;
+}
+function createAssigner(assigner) {
+ return baseRest(function(object, sources) {
+ var index = -1, length = sources.length, customizer = length > 1 ? sources[length - 1] : void 0, guard = length > 2 ? sources[2] : void 0;
+ customizer = assigner.length > 3 && typeof customizer == "function" ? (length--, customizer) : void 0;
+ if (guard && isIterateeCall(sources[0], sources[1], guard)) {
+ customizer = length < 3 ? void 0 : customizer;
+ length = 1;
+ }
+ object = Object(object);
+ while (++index < length) {
+ var source = sources[index];
+ if (source) {
+ assigner(object, source, index, customizer);
+ }
+ }
+ return object;
+ });
+}
+var objectProto$6 = Object.prototype;
+function isPrototype(value) {
+ var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$6;
+ return value === proto;
+}
+function baseTimes(n, iteratee) {
+ var index = -1, result = Array(n);
+ while (++index < n) {
+ result[index] = iteratee(index);
+ }
+ return result;
+}
+var argsTag$1 = "[object Arguments]";
+function baseIsArguments(value) {
+ return isObjectLike(value) && baseGetTag(value) == argsTag$1;
+}
+var objectProto$5 = Object.prototype;
+var hasOwnProperty$6 = objectProto$5.hasOwnProperty;
+var propertyIsEnumerable = objectProto$5.propertyIsEnumerable;
+var isArguments = baseIsArguments(/* @__PURE__ */ function() {
+ return arguments;
+}()) ? baseIsArguments : function(value) {
+ return isObjectLike(value) && hasOwnProperty$6.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
+};
+function stubFalse() {
+ return false;
+}
+var freeExports$2 = typeof exports == "object" && exports && !exports.nodeType && exports;
+var freeModule$2 = freeExports$2 && typeof module == "object" && module && !module.nodeType && module;
+var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2;
+var Buffer$2 = moduleExports$2 ? root.Buffer : void 0;
+var nativeIsBuffer = Buffer$2 ? Buffer$2.isBuffer : void 0;
+var isBuffer$1 = nativeIsBuffer || stubFalse;
+var argsTag = "[object Arguments]", arrayTag = "[object Array]", boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", funcTag = "[object Function]", mapTag = "[object Map]", numberTag = "[object Number]", objectTag$1 = "[object Object]", regexpTag = "[object RegExp]", setTag = "[object Set]", stringTag = "[object String]", weakMapTag = "[object WeakMap]";
+var arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
+var typedArrayTags = {};
+typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true;
+typedArrayTags[argsTag] = typedArrayTags[arrayTag] = typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = typedArrayTags[errorTag] = typedArrayTags[funcTag] = typedArrayTags[mapTag] = typedArrayTags[numberTag] = typedArrayTags[objectTag$1] = typedArrayTags[regexpTag] = typedArrayTags[setTag] = typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false;
+function baseIsTypedArray(value) {
+ return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
+}
+function baseUnary(func) {
+ return function(value) {
+ return func(value);
+ };
+}
+var freeExports$1 = typeof exports == "object" && exports && !exports.nodeType && exports;
+var freeModule$1 = freeExports$1 && typeof module == "object" && module && !module.nodeType && module;
+var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
+var freeProcess = moduleExports$1 && freeGlobal.process;
+var nodeUtil = function() {
+ try {
+ var types = freeModule$1 && freeModule$1.require && freeModule$1.require("util").types;
+ if (types) {
+ return types;
+ }
+ return freeProcess && freeProcess.binding && freeProcess.binding("util");
+ } catch (e) {
+ }
+}();
+var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
+var isTypedArray$1 = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
+var objectProto$4 = Object.prototype;
+var hasOwnProperty$5 = objectProto$4.hasOwnProperty;
+function arrayLikeKeys(value, inherited) {
+ var isArr = isArray$1(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer$1(value), isType = !isArr && !isArg && !isBuff && isTypedArray$1(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
+ for (var key in value) {
+ if ((inherited || hasOwnProperty$5.call(value, key)) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
+ (key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
+ isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
+ isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
+ isIndex(key, length)))) {
+ result.push(key);
+ }
+ }
+ return result;
+}
+function overArg(func, transform) {
+ return function(arg) {
+ return func(transform(arg));
+ };
+}
+function nativeKeysIn(object) {
+ var result = [];
+ if (object != null) {
+ for (var key in Object(object)) {
+ result.push(key);
+ }
+ }
+ return result;
+}
+var objectProto$3 = Object.prototype;
+var hasOwnProperty$4 = objectProto$3.hasOwnProperty;
+function baseKeysIn(object) {
+ if (!isObject$2(object)) {
+ return nativeKeysIn(object);
+ }
+ var isProto = isPrototype(object), result = [];
+ for (var key in object) {
+ if (!(key == "constructor" && (isProto || !hasOwnProperty$4.call(object, key)))) {
+ result.push(key);
+ }
+ }
+ return result;
+}
+function keysIn(object) {
+ return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
+}
+var nativeCreate = getNative(Object, "create");
+function hashClear() {
+ this.__data__ = nativeCreate ? nativeCreate(null) : {};
+ this.size = 0;
+}
+function hashDelete(key) {
+ var result = this.has(key) && delete this.__data__[key];
+ this.size -= result ? 1 : 0;
+ return result;
+}
+var HASH_UNDEFINED$1 = "__lodash_hash_undefined__";
+var objectProto$2 = Object.prototype;
+var hasOwnProperty$3 = objectProto$2.hasOwnProperty;
+function hashGet(key) {
+ var data = this.__data__;
+ if (nativeCreate) {
+ var result = data[key];
+ return result === HASH_UNDEFINED$1 ? void 0 : result;
+ }
+ return hasOwnProperty$3.call(data, key) ? data[key] : void 0;
+}
+var objectProto$1 = Object.prototype;
+var hasOwnProperty$2 = objectProto$1.hasOwnProperty;
+function hashHas(key) {
+ var data = this.__data__;
+ return nativeCreate ? data[key] !== void 0 : hasOwnProperty$2.call(data, key);
+}
+var HASH_UNDEFINED = "__lodash_hash_undefined__";
+function hashSet(key, value) {
+ var data = this.__data__;
+ this.size += this.has(key) ? 0 : 1;
+ data[key] = nativeCreate && value === void 0 ? HASH_UNDEFINED : value;
+ return this;
+}
+function Hash(entries) {
+ var index = -1, length = entries == null ? 0 : entries.length;
+ this.clear();
+ while (++index < length) {
+ var entry = entries[index];
+ this.set(entry[0], entry[1]);
+ }
+}
+Hash.prototype.clear = hashClear;
+Hash.prototype["delete"] = hashDelete;
+Hash.prototype.get = hashGet;
+Hash.prototype.has = hashHas;
+Hash.prototype.set = hashSet;
+function listCacheClear() {
+ this.__data__ = [];
+ this.size = 0;
+}
+function assocIndexOf(array, key) {
+ var length = array.length;
+ while (length--) {
+ if (eq(array[length][0], key)) {
+ return length;
+ }
+ }
+ return -1;
+}
+var arrayProto = Array.prototype;
+var splice = arrayProto.splice;
+function listCacheDelete(key) {
+ var data = this.__data__, index = assocIndexOf(data, key);
+ if (index < 0) {
+ return false;
+ }
+ var lastIndex = data.length - 1;
+ if (index == lastIndex) {
+ data.pop();
+ } else {
+ splice.call(data, index, 1);
+ }
+ --this.size;
+ return true;
+}
+function listCacheGet(key) {
+ var data = this.__data__, index = assocIndexOf(data, key);
+ return index < 0 ? void 0 : data[index][1];
+}
+function listCacheHas(key) {
+ return assocIndexOf(this.__data__, key) > -1;
+}
+function listCacheSet(key, value) {
+ var data = this.__data__, index = assocIndexOf(data, key);
+ if (index < 0) {
+ ++this.size;
+ data.push([key, value]);
+ } else {
+ data[index][1] = value;
+ }
+ return this;
+}
+function ListCache(entries) {
+ var index = -1, length = entries == null ? 0 : entries.length;
+ this.clear();
+ while (++index < length) {
+ var entry = entries[index];
+ this.set(entry[0], entry[1]);
+ }
+}
+ListCache.prototype.clear = listCacheClear;
+ListCache.prototype["delete"] = listCacheDelete;
+ListCache.prototype.get = listCacheGet;
+ListCache.prototype.has = listCacheHas;
+ListCache.prototype.set = listCacheSet;
+var Map$1 = getNative(root, "Map");
+function mapCacheClear() {
+ this.size = 0;
+ this.__data__ = {
+ "hash": new Hash(),
+ "map": new (Map$1 || ListCache)(),
+ "string": new Hash()
+ };
+}
+function isKeyable(value) {
+ var type = typeof value;
+ return type == "string" || type == "number" || type == "symbol" || type == "boolean" ? value !== "__proto__" : value === null;
+}
+function getMapData(map, key) {
+ var data = map.__data__;
+ return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
+}
+function mapCacheDelete(key) {
+ var result = getMapData(this, key)["delete"](key);
+ this.size -= result ? 1 : 0;
+ return result;
+}
+function mapCacheGet(key) {
+ return getMapData(this, key).get(key);
+}
+function mapCacheHas(key) {
+ return getMapData(this, key).has(key);
+}
+function mapCacheSet(key, value) {
+ var data = getMapData(this, key), size2 = data.size;
+ data.set(key, value);
+ this.size += data.size == size2 ? 0 : 1;
+ return this;
+}
+function MapCache(entries) {
+ var index = -1, length = entries == null ? 0 : entries.length;
+ this.clear();
+ while (++index < length) {
+ var entry = entries[index];
+ this.set(entry[0], entry[1]);
+ }
+}
+MapCache.prototype.clear = mapCacheClear;
+MapCache.prototype["delete"] = mapCacheDelete;
+MapCache.prototype.get = mapCacheGet;
+MapCache.prototype.has = mapCacheHas;
+MapCache.prototype.set = mapCacheSet;
+function toString$2(value) {
+ return value == null ? "" : baseToString(value);
+}
+var getPrototype = overArg(Object.getPrototypeOf, Object);
+var objectTag = "[object Object]";
+var funcProto = Function.prototype, objectProto = Object.prototype;
+var funcToString = funcProto.toString;
+var hasOwnProperty$1 = objectProto.hasOwnProperty;
+var objectCtorString = funcToString.call(Object);
+function isPlainObject$1(value) {
+ if (!isObjectLike(value) || baseGetTag(value) != objectTag) {
+ return false;
+ }
+ var proto = getPrototype(value);
+ if (proto === null) {
+ return true;
+ }
+ var Ctor = hasOwnProperty$1.call(proto, "constructor") && proto.constructor;
+ return typeof Ctor == "function" && Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString;
+}
+function baseSlice(array, start, end) {
+ var index = -1, length = array.length;
+ if (start < 0) {
+ start = -start > length ? 0 : length + start;
+ }
+ end = end > length ? length : end;
+ if (end < 0) {
+ end += length;
+ }
+ length = start > end ? 0 : end - start >>> 0;
+ start >>>= 0;
+ var result = Array(length);
+ while (++index < length) {
+ result[index] = array[index + start];
+ }
+ return result;
+}
+function castSlice(array, start, end) {
+ var length = array.length;
+ end = end === void 0 ? length : end;
+ return !start && end >= length ? array : baseSlice(array, start, end);
+}
+var rsAstralRange$1 = "\\ud800-\\udfff", rsComboMarksRange$1 = "\\u0300-\\u036f", reComboHalfMarksRange$1 = "\\ufe20-\\ufe2f", rsComboSymbolsRange$1 = "\\u20d0-\\u20ff", rsComboRange$1 = rsComboMarksRange$1 + reComboHalfMarksRange$1 + rsComboSymbolsRange$1, rsVarRange$1 = "\\ufe0e\\ufe0f";
+var rsZWJ$1 = "\\u200d";
+var reHasUnicode = RegExp("[" + rsZWJ$1 + rsAstralRange$1 + rsComboRange$1 + rsVarRange$1 + "]");
+function hasUnicode(string) {
+ return reHasUnicode.test(string);
+}
+function asciiToArray(string) {
+ return string.split("");
+}
+var rsAstralRange = "\\ud800-\\udfff", rsComboMarksRange = "\\u0300-\\u036f", reComboHalfMarksRange = "\\ufe20-\\ufe2f", rsComboSymbolsRange = "\\u20d0-\\u20ff", rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange, rsVarRange = "\\ufe0e\\ufe0f";
+var rsAstral = "[" + rsAstralRange + "]", rsCombo = "[" + rsComboRange + "]", rsFitz = "\\ud83c[\\udffb-\\udfff]", rsModifier = "(?:" + rsCombo + "|" + rsFitz + ")", rsNonAstral = "[^" + rsAstralRange + "]", rsRegional = "(?:\\ud83c[\\udde6-\\uddff]){2}", rsSurrPair = "[\\ud800-\\udbff][\\udc00-\\udfff]", rsZWJ = "\\u200d";
+var reOptMod = rsModifier + "?", rsOptVar = "[" + rsVarRange + "]?", rsOptJoin = "(?:" + rsZWJ + "(?:" + [rsNonAstral, rsRegional, rsSurrPair].join("|") + ")" + rsOptVar + reOptMod + ")*", rsSeq = rsOptVar + reOptMod + rsOptJoin, rsSymbol = "(?:" + [rsNonAstral + rsCombo + "?", rsCombo, rsRegional, rsSurrPair, rsAstral].join("|") + ")";
+var reUnicode = RegExp(rsFitz + "(?=" + rsFitz + ")|" + rsSymbol + rsSeq, "g");
+function unicodeToArray(string) {
+ return string.match(reUnicode) || [];
+}
+function stringToArray(string) {
+ return hasUnicode(string) ? unicodeToArray(string) : asciiToArray(string);
+}
+function createCaseFirst(methodName) {
+ return function(string) {
+ string = toString$2(string);
+ var strSymbols = hasUnicode(string) ? stringToArray(string) : void 0;
+ var chr = strSymbols ? strSymbols[0] : string.charAt(0);
+ var trailing = strSymbols ? castSlice(strSymbols, 1).join("") : string.slice(1);
+ return chr[methodName]() + trailing;
+ };
+}
+var upperFirst = createCaseFirst("toUpperCase");
+function stackClear() {
+ this.__data__ = new ListCache();
+ this.size = 0;
+}
+function stackDelete(key) {
+ var data = this.__data__, result = data["delete"](key);
+ this.size = data.size;
+ return result;
+}
+function stackGet(key) {
+ return this.__data__.get(key);
+}
+function stackHas(key) {
+ return this.__data__.has(key);
+}
+var LARGE_ARRAY_SIZE = 200;
+function stackSet(key, value) {
+ var data = this.__data__;
+ if (data instanceof ListCache) {
+ var pairs = data.__data__;
+ if (!Map$1 || pairs.length < LARGE_ARRAY_SIZE - 1) {
+ pairs.push([key, value]);
+ this.size = ++data.size;
+ return this;
+ }
+ data = this.__data__ = new MapCache(pairs);
+ }
+ data.set(key, value);
+ this.size = data.size;
+ return this;
+}
+function Stack(entries) {
+ var data = this.__data__ = new ListCache(entries);
+ this.size = data.size;
+}
+Stack.prototype.clear = stackClear;
+Stack.prototype["delete"] = stackDelete;
+Stack.prototype.get = stackGet;
+Stack.prototype.has = stackHas;
+Stack.prototype.set = stackSet;
+var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
+var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
+var moduleExports = freeModule && freeModule.exports === freeExports;
+var Buffer$1 = moduleExports ? root.Buffer : void 0;
+Buffer$1 ? Buffer$1.allocUnsafe : void 0;
+function cloneBuffer(buffer, isDeep) {
+ {
+ return buffer.slice();
+ }
+}
+var Uint8Array$1 = root.Uint8Array;
+function cloneArrayBuffer(arrayBuffer) {
+ var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
+ new Uint8Array$1(result).set(new Uint8Array$1(arrayBuffer));
+ return result;
+}
+function cloneTypedArray(typedArray, isDeep) {
+ var buffer = cloneArrayBuffer(typedArray.buffer);
+ return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
+}
+function initCloneObject(object) {
+ return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate(getPrototype(object)) : {};
+}
+function createBaseFor(fromRight) {
+ return function(object, iteratee, keysFunc) {
+ var index = -1, iterable = Object(object), props = keysFunc(object), length = props.length;
+ while (length--) {
+ var key = props[++index];
+ if (iteratee(iterable[key], key, iterable) === false) {
+ break;
+ }
+ }
+ return object;
+ };
+}
+var baseFor = createBaseFor();
+function assignMergeValue(object, key, value) {
+ if (value !== void 0 && !eq(object[key], value) || value === void 0 && !(key in object)) {
+ baseAssignValue(object, key, value);
+ }
+}
+function isArrayLikeObject(value) {
+ return isObjectLike(value) && isArrayLike(value);
+}
+function safeGet(object, key) {
+ if (key === "constructor" && typeof object[key] === "function") {
+ return;
+ }
+ if (key == "__proto__") {
+ return;
+ }
+ return object[key];
+}
+function toPlainObject(value) {
+ return copyObject(value, keysIn(value));
+}
+function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack2) {
+ var objValue = safeGet(object, key), srcValue = safeGet(source, key), stacked = stack2.get(srcValue);
+ if (stacked) {
+ assignMergeValue(object, key, stacked);
+ return;
+ }
+ var newValue = customizer ? customizer(objValue, srcValue, key + "", object, source, stack2) : void 0;
+ var isCommon = newValue === void 0;
+ if (isCommon) {
+ var isArr = isArray$1(srcValue), isBuff = !isArr && isBuffer$1(srcValue), isTyped = !isArr && !isBuff && isTypedArray$1(srcValue);
+ newValue = srcValue;
+ if (isArr || isBuff || isTyped) {
+ if (isArray$1(objValue)) {
+ newValue = objValue;
+ } else if (isArrayLikeObject(objValue)) {
+ newValue = copyArray(objValue);
+ } else if (isBuff) {
+ isCommon = false;
+ newValue = cloneBuffer(srcValue);
+ } else if (isTyped) {
+ isCommon = false;
+ newValue = cloneTypedArray(srcValue);
+ } else {
+ newValue = [];
+ }
+ } else if (isPlainObject$1(srcValue) || isArguments(srcValue)) {
+ newValue = objValue;
+ if (isArguments(objValue)) {
+ newValue = toPlainObject(objValue);
+ } else if (!isObject$2(objValue) || isFunction$1(objValue)) {
+ newValue = initCloneObject(srcValue);
+ }
+ } else {
+ isCommon = false;
+ }
+ }
+ if (isCommon) {
+ stack2.set(srcValue, newValue);
+ mergeFunc(newValue, srcValue, srcIndex, customizer, stack2);
+ stack2["delete"](srcValue);
+ }
+ assignMergeValue(object, key, newValue);
+}
+function baseMerge(object, source, srcIndex, customizer, stack2) {
+ if (object === source) {
+ return;
+ }
+ baseFor(source, function(srcValue, key) {
+ stack2 || (stack2 = new Stack());
+ if (isObject$2(srcValue)) {
+ baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack2);
+ } else {
+ var newValue = customizer ? customizer(safeGet(object, key), srcValue, key + "", object, source, stack2) : void 0;
+ if (newValue === void 0) {
+ newValue = srcValue;
+ }
+ assignMergeValue(object, key, newValue);
+ }
+ }, keysIn);
+}
+var merge$1 = createAssigner(function(object, source, srcIndex) {
+ baseMerge(object, source, srcIndex);
+});
+const cssrAnchorMetaName = "naive-ui-style";
+function useRtl(mountId, rtlStateRef, clsPrefixRef) {
+ if (!rtlStateRef) return void 0;
+ const ssrAdapter2 = useSsrAdapter();
+ const componentRtlStateRef = computed(() => {
+ const {
+ value: rtlState
+ } = rtlStateRef;
+ if (!rtlState) {
+ return void 0;
+ }
+ const componentRtlState = rtlState[mountId];
+ if (!componentRtlState) {
+ return void 0;
+ }
+ return componentRtlState;
+ });
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ const mountStyle = () => {
+ watchEffect(() => {
+ const {
+ value: clsPrefix
+ } = clsPrefixRef;
+ const id = `${clsPrefix}${mountId}Rtl`;
+ if (exists(id, ssrAdapter2)) return;
+ const {
+ value: componentRtlState
+ } = componentRtlStateRef;
+ if (!componentRtlState) return;
+ componentRtlState.style.mount({
+ id,
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ props: {
+ bPrefix: clsPrefix ? `.${clsPrefix}-` : void 0
+ },
+ ssr: ssrAdapter2,
+ parent: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget
+ });
+ });
+ };
+ if (ssrAdapter2) {
+ mountStyle();
+ } else {
+ onBeforeMount(mountStyle);
+ }
+ return componentRtlStateRef;
+}
+const commonVariables$n = {
+ fontFamily: 'v-sans, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',
+ fontFamilyMono: "v-mono, SFMono-Regular, Menlo, Consolas, Courier, monospace",
+ fontWeight: "400",
+ fontWeightStrong: "500",
+ cubicBezierEaseInOut: "cubic-bezier(.4, 0, .2, 1)",
+ cubicBezierEaseOut: "cubic-bezier(0, 0, .2, 1)",
+ cubicBezierEaseIn: "cubic-bezier(.4, 0, 1, 1)",
+ borderRadius: "3px",
+ borderRadiusSmall: "2px",
+ fontSize: "14px",
+ fontSizeMini: "12px",
+ fontSizeTiny: "12px",
+ fontSizeSmall: "14px",
+ fontSizeMedium: "14px",
+ fontSizeLarge: "15px",
+ fontSizeHuge: "16px",
+ lineHeight: "1.6",
+ heightMini: "16px",
+ // private now, it's too small
+ heightTiny: "22px",
+ heightSmall: "28px",
+ heightMedium: "34px",
+ heightLarge: "40px",
+ heightHuge: "46px"
+};
+const {
+ fontSize,
+ fontFamily,
+ lineHeight
+} = commonVariables$n;
+const globalStyle = c("body", `
+ margin: 0;
+ font-size: ${fontSize};
+ font-family: ${fontFamily};
+ line-height: ${lineHeight};
+ -webkit-text-size-adjust: 100%;
+ -webkit-tap-highlight-color: transparent;
+`, [c("input", `
+ font-family: inherit;
+ font-size: inherit;
+ `)]);
+function useStyle(mountId, style2, clsPrefixRef) {
+ if (!style2) {
+ return;
+ }
+ const ssrAdapter2 = useSsrAdapter();
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ const mountStyle = () => {
+ const clsPrefix = clsPrefixRef.value;
+ style2.mount({
+ id: clsPrefix === void 0 ? mountId : clsPrefix + mountId,
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ props: {
+ bPrefix: clsPrefix ? `.${clsPrefix}-` : void 0
+ },
+ ssr: ssrAdapter2,
+ parent: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget
+ });
+ if (!(NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.preflightStyleDisabled)) {
+ globalStyle.mount({
+ id: "n-global",
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ ssr: ssrAdapter2,
+ parent: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget
+ });
+ }
+ };
+ if (ssrAdapter2) {
+ mountStyle();
+ } else {
+ onBeforeMount(mountStyle);
+ }
+}
+function createTheme(theme) {
+ return theme;
+}
+function useTheme(resolveId, mountId, style2, defaultTheme, props, clsPrefixRef) {
+ const ssrAdapter2 = useSsrAdapter();
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ if (style2) {
+ const mountStyle = () => {
+ const clsPrefix = clsPrefixRef === null || clsPrefixRef === void 0 ? void 0 : clsPrefixRef.value;
+ style2.mount({
+ id: clsPrefix === void 0 ? mountId : clsPrefix + mountId,
+ head: true,
+ props: {
+ bPrefix: clsPrefix ? `.${clsPrefix}-` : void 0
+ },
+ anchorMetaName: cssrAnchorMetaName,
+ ssr: ssrAdapter2,
+ parent: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget
+ });
+ if (!(NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.preflightStyleDisabled)) {
+ globalStyle.mount({
+ id: "n-global",
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ ssr: ssrAdapter2,
+ parent: NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget
+ });
+ }
+ };
+ if (ssrAdapter2) {
+ mountStyle();
+ } else {
+ onBeforeMount(mountStyle);
+ }
+ }
+ const mergedThemeRef = computed(() => {
+ var _a;
+ const {
+ theme: {
+ common: selfCommon,
+ self: self2,
+ peers = {}
+ } = {},
+ themeOverrides: selfOverrides = {},
+ builtinThemeOverrides: builtinOverrides = {}
+ } = props;
+ const {
+ common: selfCommonOverrides,
+ peers: peersOverrides
+ } = selfOverrides;
+ const {
+ common: globalCommon = void 0,
+ [resolveId]: {
+ common: globalSelfCommon = void 0,
+ self: globalSelf = void 0,
+ peers: globalPeers = {}
+ } = {}
+ } = (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeRef.value) || {};
+ const {
+ common: globalCommonOverrides = void 0,
+ [resolveId]: globalSelfOverrides = {}
+ } = (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeOverridesRef.value) || {};
+ const {
+ common: globalSelfCommonOverrides,
+ peers: globalPeersOverrides = {}
+ } = globalSelfOverrides;
+ const mergedCommon = merge$1({}, selfCommon || globalSelfCommon || globalCommon || defaultTheme.common, globalCommonOverrides, globalSelfCommonOverrides, selfCommonOverrides);
+ const mergedSelf = merge$1(
+ // {}, executed every time, no need for empty obj
+ (_a = self2 || globalSelf || defaultTheme.self) === null || _a === void 0 ? void 0 : _a(mergedCommon),
+ builtinOverrides,
+ globalSelfOverrides,
+ selfOverrides
+ );
+ return {
+ common: mergedCommon,
+ self: mergedSelf,
+ peers: merge$1({}, defaultTheme.peers, globalPeers, peers),
+ peerOverrides: merge$1({}, builtinOverrides.peers, globalPeersOverrides, peersOverrides)
+ };
+ });
+ return mergedThemeRef;
+}
+useTheme.props = {
+ theme: Object,
+ themeOverrides: Object,
+ builtinThemeOverrides: Object
+};
+const style$b = cB("base-icon", `
+ height: 1em;
+ width: 1em;
+ line-height: 1em;
+ text-align: center;
+ display: inline-block;
+ position: relative;
+ fill: currentColor;
+ transform: translateZ(0);
+`, [c("svg", `
+ height: 1em;
+ width: 1em;
+ `)]);
+const NBaseIcon = /* @__PURE__ */ defineComponent({
+ name: "BaseIcon",
+ props: {
+ role: String,
+ ariaLabel: String,
+ ariaDisabled: {
+ type: Boolean,
+ default: void 0
+ },
+ ariaHidden: {
+ type: Boolean,
+ default: void 0
+ },
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ onClick: Function,
+ onMousedown: Function,
+ onMouseup: Function
+ },
+ setup(props) {
+ useStyle("-base-icon", style$b, toRef(props, "clsPrefix"));
+ },
+ render() {
+ return h("i", {
+ class: `${this.clsPrefix}-base-icon`,
+ onClick: this.onClick,
+ onMousedown: this.onMousedown,
+ onMouseup: this.onMouseup,
+ role: this.role,
+ "aria-label": this.ariaLabel,
+ "aria-hidden": this.ariaHidden,
+ "aria-disabled": this.ariaDisabled
+ }, this.$slots);
+ }
+});
+const NIconSwitchTransition = /* @__PURE__ */ defineComponent({
+ name: "BaseIconSwitchTransition",
+ setup(_, {
+ slots
+ }) {
+ const isMountedRef = isMounted();
+ return () => h(Transition, {
+ name: "icon-switch-transition",
+ appear: isMountedRef.value
+ }, slots);
+ }
+});
+function replaceable(name2, icon) {
+ const IconComponent = /* @__PURE__ */ defineComponent({
+ render() {
+ return icon();
+ }
+ });
+ return /* @__PURE__ */ defineComponent({
+ name: upperFirst(name2),
+ setup() {
+ var _a;
+ const mergedIconsRef = (_a = inject(configProviderInjectionKey, null)) === null || _a === void 0 ? void 0 : _a.mergedIconsRef;
+ return () => {
+ var _a2;
+ const iconOverride = (_a2 = mergedIconsRef === null || mergedIconsRef === void 0 ? void 0 : mergedIconsRef.value) === null || _a2 === void 0 ? void 0 : _a2[name2];
+ return iconOverride ? iconOverride() : h(IconComponent, null);
+ };
+ }
+ });
+}
+const ErrorIcon$1 = replaceable("close", () => h("svg", {
+ viewBox: "0 0 12 12",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg",
+ "aria-hidden": true
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ fill: "none",
+ "fill-rule": "evenodd"
+}, h("g", {
+ fill: "currentColor",
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M2.08859116,2.2156945 L2.14644661,2.14644661 C2.32001296,1.97288026 2.58943736,1.95359511 2.7843055,2.08859116 L2.85355339,2.14644661 L6,5.293 L9.14644661,2.14644661 C9.34170876,1.95118446 9.65829124,1.95118446 9.85355339,2.14644661 C10.0488155,2.34170876 10.0488155,2.65829124 9.85355339,2.85355339 L6.707,6 L9.85355339,9.14644661 C10.0271197,9.32001296 10.0464049,9.58943736 9.91140884,9.7843055 L9.85355339,9.85355339 C9.67998704,10.0271197 9.41056264,10.0464049 9.2156945,9.91140884 L9.14644661,9.85355339 L6,6.707 L2.85355339,9.85355339 C2.65829124,10.0488155 2.34170876,10.0488155 2.14644661,9.85355339 C1.95118446,9.65829124 1.95118446,9.34170876 2.14644661,9.14644661 L5.293,6 L2.14644661,2.85355339 C1.97288026,2.67998704 1.95359511,2.41056264 2.08859116,2.2156945 L2.14644661,2.14644661 L2.08859116,2.2156945 Z"
+})))));
+const ErrorIcon = replaceable("error", () => h("svg", {
+ viewBox: "0 0 48 48",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ "fill-rule": "evenodd"
+}, h("g", {
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M24,4 C35.045695,4 44,12.954305 44,24 C44,35.045695 35.045695,44 24,44 C12.954305,44 4,35.045695 4,24 C4,12.954305 12.954305,4 24,4 Z M17.8838835,16.1161165 L17.7823881,16.0249942 C17.3266086,15.6583353 16.6733914,15.6583353 16.2176119,16.0249942 L16.1161165,16.1161165 L16.0249942,16.2176119 C15.6583353,16.6733914 15.6583353,17.3266086 16.0249942,17.7823881 L16.1161165,17.8838835 L22.233,24 L16.1161165,30.1161165 L16.0249942,30.2176119 C15.6583353,30.6733914 15.6583353,31.3266086 16.0249942,31.7823881 L16.1161165,31.8838835 L16.2176119,31.9750058 C16.6733914,32.3416647 17.3266086,32.3416647 17.7823881,31.9750058 L17.8838835,31.8838835 L24,25.767 L30.1161165,31.8838835 L30.2176119,31.9750058 C30.6733914,32.3416647 31.3266086,32.3416647 31.7823881,31.9750058 L31.8838835,31.8838835 L31.9750058,31.7823881 C32.3416647,31.3266086 32.3416647,30.6733914 31.9750058,30.2176119 L31.8838835,30.1161165 L25.767,24 L31.8838835,17.8838835 L31.9750058,17.7823881 C32.3416647,17.3266086 32.3416647,16.6733914 31.9750058,16.2176119 L31.8838835,16.1161165 L31.7823881,16.0249942 C31.3266086,15.6583353 30.6733914,15.6583353 30.2176119,16.0249942 L30.1161165,16.1161165 L24,22.233 L17.8838835,16.1161165 L17.7823881,16.0249942 L17.8838835,16.1161165 Z"
+})))));
+const InfoIcon = replaceable("info", () => h("svg", {
+ viewBox: "0 0 28 28",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ "fill-rule": "evenodd"
+}, h("g", {
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M14,2 C20.6274,2 26,7.37258 26,14 C26,20.6274 20.6274,26 14,26 C7.37258,26 2,20.6274 2,14 C2,7.37258 7.37258,2 14,2 Z M14,11 C13.4477,11 13,11.4477 13,12 L13,12 L13,20 C13,20.5523 13.4477,21 14,21 C14.5523,21 15,20.5523 15,20 L15,20 L15,12 C15,11.4477 14.5523,11 14,11 Z M14,6.75 C13.3096,6.75 12.75,7.30964 12.75,8 C12.75,8.69036 13.3096,9.25 14,9.25 C14.6904,9.25 15.25,8.69036 15.25,8 C15.25,7.30964 14.6904,6.75 14,6.75 Z"
+})))));
+const SuccessIcon = replaceable("success", () => h("svg", {
+ viewBox: "0 0 48 48",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ "fill-rule": "evenodd"
+}, h("g", {
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M24,4 C35.045695,4 44,12.954305 44,24 C44,35.045695 35.045695,44 24,44 C12.954305,44 4,35.045695 4,24 C4,12.954305 12.954305,4 24,4 Z M32.6338835,17.6161165 C32.1782718,17.1605048 31.4584514,17.1301307 30.9676119,17.5249942 L30.8661165,17.6161165 L20.75,27.732233 L17.1338835,24.1161165 C16.6457281,23.6279612 15.8542719,23.6279612 15.3661165,24.1161165 C14.9105048,24.5717282 14.8801307,25.2915486 15.2749942,25.7823881 L15.3661165,25.8838835 L19.8661165,30.3838835 C20.3217282,30.8394952 21.0415486,30.8698693 21.5323881,30.4750058 L21.6338835,30.3838835 L32.6338835,19.3838835 C33.1220388,18.8957281 33.1220388,18.1042719 32.6338835,17.6161165 Z"
+})))));
+const WarningIcon = replaceable("warning", () => h("svg", {
+ viewBox: "0 0 24 24",
+ version: "1.1",
+ xmlns: "http://www.w3.org/2000/svg"
+}, h("g", {
+ stroke: "none",
+ "stroke-width": "1",
+ "fill-rule": "evenodd"
+}, h("g", {
+ "fill-rule": "nonzero"
+}, h("path", {
+ d: "M12,2 C17.523,2 22,6.478 22,12 C22,17.522 17.523,22 12,22 C6.477,22 2,17.522 2,12 C2,6.478 6.477,2 12,2 Z M12.0018002,15.0037242 C11.450254,15.0037242 11.0031376,15.4508407 11.0031376,16.0023869 C11.0031376,16.553933 11.450254,17.0010495 12.0018002,17.0010495 C12.5533463,17.0010495 13.0004628,16.553933 13.0004628,16.0023869 C13.0004628,15.4508407 12.5533463,15.0037242 12.0018002,15.0037242 Z M11.99964,7 C11.4868042,7.00018474 11.0642719,7.38637706 11.0066858,7.8837365 L11,8.00036004 L11.0018003,13.0012393 L11.00857,13.117858 C11.0665141,13.6151758 11.4893244,14.0010638 12.0021602,14.0008793 C12.514996,14.0006946 12.9375283,13.6145023 12.9951144,13.1171428 L13.0018002,13.0005193 L13,7.99964009 L12.9932303,7.8830214 C12.9352861,7.38570354 12.5124758,6.99981552 11.99964,7 Z"
+})))));
+const {
+ cubicBezierEaseInOut: cubicBezierEaseInOut$3
+} = commonVariables$n;
+function iconSwitchTransition({
+ originalTransform = "",
+ left = 0,
+ top = 0,
+ transition = `all .3s ${cubicBezierEaseInOut$3} !important`
+} = {}) {
+ return [c("&.icon-switch-transition-enter-from, &.icon-switch-transition-leave-to", {
+ transform: `${originalTransform} scale(0.75)`,
+ left,
+ top,
+ opacity: 0
+ }), c("&.icon-switch-transition-enter-to, &.icon-switch-transition-leave-from", {
+ transform: `scale(1) ${originalTransform}`,
+ left,
+ top,
+ opacity: 1
+ }), c("&.icon-switch-transition-enter-active, &.icon-switch-transition-leave-active", {
+ transformOrigin: "center",
+ position: "absolute",
+ left,
+ top,
+ transition
+ })];
+}
+const style$a = cB("base-close", `
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ cursor: pointer;
+ background-color: transparent;
+ color: var(--n-close-icon-color);
+ border-radius: var(--n-close-border-radius);
+ height: var(--n-close-size);
+ width: var(--n-close-size);
+ font-size: var(--n-close-icon-size);
+ outline: none;
+ border: none;
+ position: relative;
+ padding: 0;
+`, [cM("absolute", `
+ height: var(--n-close-icon-size);
+ width: var(--n-close-icon-size);
+ `), c("&::before", `
+ content: "";
+ position: absolute;
+ width: var(--n-close-size);
+ height: var(--n-close-size);
+ left: 50%;
+ top: 50%;
+ transform: translateY(-50%) translateX(-50%);
+ transition: inherit;
+ border-radius: inherit;
+ `), cNotM("disabled", [c("&:hover", `
+ color: var(--n-close-icon-color-hover);
+ `), c("&:hover::before", `
+ background-color: var(--n-close-color-hover);
+ `), c("&:focus::before", `
+ background-color: var(--n-close-color-hover);
+ `), c("&:active", `
+ color: var(--n-close-icon-color-pressed);
+ `), c("&:active::before", `
+ background-color: var(--n-close-color-pressed);
+ `)]), cM("disabled", `
+ cursor: not-allowed;
+ color: var(--n-close-icon-color-disabled);
+ background-color: transparent;
+ `), cM("round", [c("&::before", `
+ border-radius: 50%;
+ `)])]);
+const NBaseClose = /* @__PURE__ */ defineComponent({
+ name: "BaseClose",
+ props: {
+ isButtonTag: {
+ type: Boolean,
+ default: true
+ },
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ focusable: {
+ type: Boolean,
+ default: true
+ },
+ round: Boolean,
+ onClick: Function,
+ absolute: Boolean
+ },
+ setup(props) {
+ useStyle("-base-close", style$a, toRef(props, "clsPrefix"));
+ return () => {
+ const {
+ clsPrefix,
+ disabled,
+ absolute,
+ round,
+ isButtonTag
+ } = props;
+ const Tag = isButtonTag ? "button" : "div";
+ return h(Tag, {
+ type: isButtonTag ? "button" : void 0,
+ tabindex: disabled || !props.focusable ? -1 : 0,
+ "aria-disabled": disabled,
+ "aria-label": "close",
+ role: isButtonTag ? void 0 : "button",
+ disabled,
+ class: [`${clsPrefix}-base-close`, absolute && `${clsPrefix}-base-close--absolute`, disabled && `${clsPrefix}-base-close--disabled`, round && `${clsPrefix}-base-close--round`],
+ onMousedown: (e) => {
+ if (!props.focusable) {
+ e.preventDefault();
+ }
+ },
+ onClick: props.onClick
+ }, h(NBaseIcon, {
+ clsPrefix
+ }, {
+ default: () => h(ErrorIcon$1, null)
+ }));
+ };
+ }
+});
+const NFadeInExpandTransition = /* @__PURE__ */ defineComponent({
+ name: "FadeInExpandTransition",
+ props: {
+ appear: Boolean,
+ group: Boolean,
+ mode: String,
+ onLeave: Function,
+ onAfterLeave: Function,
+ onAfterEnter: Function,
+ width: Boolean,
+ // reverse mode is only used in tree
+ // it make it from expanded to collapsed after mounted
+ reverse: Boolean
+ },
+ setup(props, {
+ slots
+ }) {
+ function handleBeforeLeave(el) {
+ if (props.width) {
+ el.style.maxWidth = `${el.offsetWidth}px`;
+ } else {
+ el.style.maxHeight = `${el.offsetHeight}px`;
+ }
+ void el.offsetWidth;
+ }
+ function handleLeave(el) {
+ if (props.width) {
+ el.style.maxWidth = "0";
+ } else {
+ el.style.maxHeight = "0";
+ }
+ void el.offsetWidth;
+ const {
+ onLeave
+ } = props;
+ if (onLeave) onLeave();
+ }
+ function handleAfterLeave(el) {
+ if (props.width) {
+ el.style.maxWidth = "";
+ } else {
+ el.style.maxHeight = "";
+ }
+ const {
+ onAfterLeave
+ } = props;
+ if (onAfterLeave) onAfterLeave();
+ }
+ function handleEnter(el) {
+ el.style.transition = "none";
+ if (props.width) {
+ const memorizedWidth = el.offsetWidth;
+ el.style.maxWidth = "0";
+ void el.offsetWidth;
+ el.style.transition = "";
+ el.style.maxWidth = `${memorizedWidth}px`;
+ } else {
+ if (props.reverse) {
+ el.style.maxHeight = `${el.offsetHeight}px`;
+ void el.offsetHeight;
+ el.style.transition = "";
+ el.style.maxHeight = "0";
+ } else {
+ const memorizedHeight = el.offsetHeight;
+ el.style.maxHeight = "0";
+ void el.offsetWidth;
+ el.style.transition = "";
+ el.style.maxHeight = `${memorizedHeight}px`;
+ }
+ }
+ void el.offsetWidth;
+ }
+ function handleAfterEnter(el) {
+ var _a;
+ if (props.width) {
+ el.style.maxWidth = "";
+ } else {
+ if (!props.reverse) {
+ el.style.maxHeight = "";
+ }
+ }
+ (_a = props.onAfterEnter) === null || _a === void 0 ? void 0 : _a.call(props);
+ }
+ return () => {
+ const {
+ group,
+ width,
+ appear,
+ mode
+ } = props;
+ const type = group ? TransitionGroup : Transition;
+ const resolvedProps = {
+ name: width ? "fade-in-width-expand-transition" : "fade-in-height-expand-transition",
+ appear,
+ onEnter: handleEnter,
+ onAfterEnter: handleAfterEnter,
+ onBeforeLeave: handleBeforeLeave,
+ onLeave: handleLeave,
+ onAfterLeave: handleAfterLeave
+ };
+ if (!group) {
+ resolvedProps.mode = mode;
+ }
+ return h(type, resolvedProps, slots);
+ };
+ }
+});
+const style$9 = c([c("@keyframes rotator", `
+ 0% {
+ -webkit-transform: rotate(0deg);
+ transform: rotate(0deg);
+ }
+ 100% {
+ -webkit-transform: rotate(360deg);
+ transform: rotate(360deg);
+ }`), cB("base-loading", `
+ position: relative;
+ line-height: 0;
+ width: 1em;
+ height: 1em;
+ `, [cE("transition-wrapper", `
+ position: absolute;
+ width: 100%;
+ height: 100%;
+ `, [iconSwitchTransition()]), cE("placeholder", `
+ position: absolute;
+ left: 50%;
+ top: 50%;
+ transform: translateX(-50%) translateY(-50%);
+ `, [iconSwitchTransition({
+ left: "50%",
+ top: "50%",
+ originalTransform: "translateX(-50%) translateY(-50%)"
+})]), cE("container", `
+ animation: rotator 3s linear infinite both;
+ `, [cE("icon", `
+ height: 1em;
+ width: 1em;
+ `)])])]);
+const duration = "1.6s";
+const exposedLoadingProps = {
+ strokeWidth: {
+ type: Number,
+ default: 28
+ },
+ stroke: {
+ type: String,
+ default: void 0
+ }
+};
+const NBaseLoading = /* @__PURE__ */ defineComponent({
+ name: "BaseLoading",
+ props: Object.assign({
+ clsPrefix: {
+ type: String,
+ required: true
+ },
+ show: {
+ type: Boolean,
+ default: true
+ },
+ scale: {
+ type: Number,
+ default: 1
+ },
+ radius: {
+ type: Number,
+ default: 100
+ }
+ }, exposedLoadingProps),
+ setup(props) {
+ useStyle("-base-loading", style$9, toRef(props, "clsPrefix"));
+ },
+ render() {
+ const {
+ clsPrefix,
+ radius,
+ strokeWidth,
+ stroke,
+ scale
+ } = this;
+ const scaledRadius = radius / scale;
+ return h("div", {
+ class: `${clsPrefix}-base-loading`,
+ role: "img",
+ "aria-label": "loading"
+ }, h(NIconSwitchTransition, null, {
+ default: () => this.show ? h("div", {
+ key: "icon",
+ class: `${clsPrefix}-base-loading__transition-wrapper`
+ }, h("div", {
+ class: `${clsPrefix}-base-loading__container`
+ }, h("svg", {
+ class: `${clsPrefix}-base-loading__icon`,
+ viewBox: `0 0 ${2 * scaledRadius} ${2 * scaledRadius}`,
+ xmlns: "http://www.w3.org/2000/svg",
+ style: {
+ color: stroke
+ }
+ }, h("g", null, h("animateTransform", {
+ attributeName: "transform",
+ type: "rotate",
+ values: `0 ${scaledRadius} ${scaledRadius};270 ${scaledRadius} ${scaledRadius}`,
+ begin: "0s",
+ dur: duration,
+ fill: "freeze",
+ repeatCount: "indefinite"
+ }), h("circle", {
+ class: `${clsPrefix}-base-loading__icon`,
+ fill: "none",
+ stroke: "currentColor",
+ "stroke-width": strokeWidth,
+ "stroke-linecap": "round",
+ cx: scaledRadius,
+ cy: scaledRadius,
+ r: radius - strokeWidth / 2,
+ "stroke-dasharray": 5.67 * radius,
+ "stroke-dashoffset": 18.48 * radius
+ }, h("animateTransform", {
+ attributeName: "transform",
+ type: "rotate",
+ values: `0 ${scaledRadius} ${scaledRadius};135 ${scaledRadius} ${scaledRadius};450 ${scaledRadius} ${scaledRadius}`,
+ begin: "0s",
+ dur: duration,
+ fill: "freeze",
+ repeatCount: "indefinite"
+ }), h("animate", {
+ attributeName: "stroke-dashoffset",
+ values: `${5.67 * radius};${1.42 * radius};${5.67 * radius}`,
+ begin: "0s",
+ dur: duration,
+ fill: "freeze",
+ repeatCount: "indefinite"
+ })))))) : h("div", {
+ key: "placeholder",
+ class: `${clsPrefix}-base-loading__placeholder`
+ }, this.$slots)
+ }));
+ }
+});
+const {
+ cubicBezierEaseInOut: cubicBezierEaseInOut$2
+} = commonVariables$n;
+function fadeInTransition({
+ name: name2 = "fade-in",
+ enterDuration = "0.2s",
+ leaveDuration = "0.2s",
+ enterCubicBezier = cubicBezierEaseInOut$2,
+ leaveCubicBezier = cubicBezierEaseInOut$2
+} = {}) {
+ return [c(`&.${name2}-transition-enter-active`, {
+ transition: `all ${enterDuration} ${enterCubicBezier}!important`
+ }), c(`&.${name2}-transition-leave-active`, {
+ transition: `all ${leaveDuration} ${leaveCubicBezier}!important`
+ }), c(`&.${name2}-transition-enter-from, &.${name2}-transition-leave-to`, {
+ opacity: 0
+ }), c(`&.${name2}-transition-leave-from, &.${name2}-transition-enter-to`, {
+ opacity: 1
+ })];
+}
+const base$1 = {
+ neutralBase: "#000",
+ neutralInvertBase: "#fff",
+ neutralTextBase: "#fff",
+ neutralPopover: "rgb(72, 72, 78)",
+ neutralCard: "rgb(24, 24, 28)",
+ neutralModal: "rgb(44, 44, 50)",
+ neutralBody: "rgb(16, 16, 20)",
+ alpha1: "0.9",
+ alpha2: "0.82",
+ alpha3: "0.52",
+ alpha4: "0.38",
+ alpha5: "0.28",
+ alphaClose: "0.52",
+ alphaDisabled: "0.38",
+ alphaDisabledInput: "0.06",
+ alphaPending: "0.09",
+ alphaTablePending: "0.06",
+ alphaTableStriped: "0.05",
+ alphaPressed: "0.05",
+ alphaAvatar: "0.18",
+ alphaRail: "0.2",
+ alphaProgressRail: "0.12",
+ alphaBorder: "0.24",
+ alphaDivider: "0.09",
+ alphaInput: "0.1",
+ alphaAction: "0.06",
+ alphaTab: "0.04",
+ alphaScrollbar: "0.2",
+ alphaScrollbarHover: "0.3",
+ alphaCode: "0.12",
+ alphaTag: "0.2",
+ // primary
+ primaryHover: "#7fe7c4",
+ primaryDefault: "#63e2b7",
+ primaryActive: "#5acea7",
+ primarySuppl: "rgb(42, 148, 125)",
+ // info
+ infoHover: "#8acbec",
+ infoDefault: "#70c0e8",
+ infoActive: "#66afd3",
+ infoSuppl: "rgb(56, 137, 197)",
+ // error
+ errorHover: "#e98b8b",
+ errorDefault: "#e88080",
+ errorActive: "#e57272",
+ errorSuppl: "rgb(208, 58, 82)",
+ // warning
+ warningHover: "#f5d599",
+ warningDefault: "#f2c97d",
+ warningActive: "#e6c260",
+ warningSuppl: "rgb(240, 138, 0)",
+ // success
+ successHover: "#7fe7c4",
+ successDefault: "#63e2b7",
+ successActive: "#5acea7",
+ successSuppl: "rgb(42, 148, 125)"
+};
+const baseBackgroundRgb$1 = rgba(base$1.neutralBase);
+const baseInvertBackgroundRgb$1 = rgba(base$1.neutralInvertBase);
+const overlayPrefix$1 = `rgba(${baseInvertBackgroundRgb$1.slice(0, 3).join(", ")}, `;
+function overlay$1(alpha) {
+ return `${overlayPrefix$1 + String(alpha)})`;
+}
+function neutral$1(alpha) {
+ const overlayRgba = Array.from(baseInvertBackgroundRgb$1);
+ overlayRgba[3] = Number(alpha);
+ return composite(baseBackgroundRgb$1, overlayRgba);
+}
+const derived$1 = Object.assign(Object.assign({
+ name: "common"
+}, commonVariables$n), {
+ baseColor: base$1.neutralBase,
+ // primary color
+ primaryColor: base$1.primaryDefault,
+ primaryColorHover: base$1.primaryHover,
+ primaryColorPressed: base$1.primaryActive,
+ primaryColorSuppl: base$1.primarySuppl,
+ // info color
+ infoColor: base$1.infoDefault,
+ infoColorHover: base$1.infoHover,
+ infoColorPressed: base$1.infoActive,
+ infoColorSuppl: base$1.infoSuppl,
+ // success color
+ successColor: base$1.successDefault,
+ successColorHover: base$1.successHover,
+ successColorPressed: base$1.successActive,
+ successColorSuppl: base$1.successSuppl,
+ // warning color
+ warningColor: base$1.warningDefault,
+ warningColorHover: base$1.warningHover,
+ warningColorPressed: base$1.warningActive,
+ warningColorSuppl: base$1.warningSuppl,
+ // error color
+ errorColor: base$1.errorDefault,
+ errorColorHover: base$1.errorHover,
+ errorColorPressed: base$1.errorActive,
+ errorColorSuppl: base$1.errorSuppl,
+ // text color
+ textColorBase: base$1.neutralTextBase,
+ textColor1: overlay$1(base$1.alpha1),
+ textColor2: overlay$1(base$1.alpha2),
+ textColor3: overlay$1(base$1.alpha3),
+ // textColor4: overlay(base.alpha4), // disabled, placeholder, icon
+ // textColor5: overlay(base.alpha5),
+ textColorDisabled: overlay$1(base$1.alpha4),
+ placeholderColor: overlay$1(base$1.alpha4),
+ placeholderColorDisabled: overlay$1(base$1.alpha5),
+ iconColor: overlay$1(base$1.alpha4),
+ iconColorDisabled: overlay$1(base$1.alpha5),
+ iconColorHover: overlay$1(Number(base$1.alpha4) * 1.25),
+ iconColorPressed: overlay$1(Number(base$1.alpha4) * 0.8),
+ opacity1: base$1.alpha1,
+ opacity2: base$1.alpha2,
+ opacity3: base$1.alpha3,
+ opacity4: base$1.alpha4,
+ opacity5: base$1.alpha5,
+ dividerColor: overlay$1(base$1.alphaDivider),
+ borderColor: overlay$1(base$1.alphaBorder),
+ // close
+ closeIconColorHover: overlay$1(Number(base$1.alphaClose)),
+ closeIconColor: overlay$1(Number(base$1.alphaClose)),
+ closeIconColorPressed: overlay$1(Number(base$1.alphaClose)),
+ closeColorHover: "rgba(255, 255, 255, .12)",
+ closeColorPressed: "rgba(255, 255, 255, .08)",
+ // clear
+ clearColor: overlay$1(base$1.alpha4),
+ clearColorHover: scaleColor(overlay$1(base$1.alpha4), {
+ alpha: 1.25
+ }),
+ clearColorPressed: scaleColor(overlay$1(base$1.alpha4), {
+ alpha: 0.8
+ }),
+ scrollbarColor: overlay$1(base$1.alphaScrollbar),
+ scrollbarColorHover: overlay$1(base$1.alphaScrollbarHover),
+ scrollbarWidth: "5px",
+ scrollbarHeight: "5px",
+ scrollbarBorderRadius: "5px",
+ progressRailColor: overlay$1(base$1.alphaProgressRail),
+ railColor: overlay$1(base$1.alphaRail),
+ popoverColor: base$1.neutralPopover,
+ tableColor: base$1.neutralCard,
+ cardColor: base$1.neutralCard,
+ modalColor: base$1.neutralModal,
+ bodyColor: base$1.neutralBody,
+ tagColor: neutral$1(base$1.alphaTag),
+ avatarColor: overlay$1(base$1.alphaAvatar),
+ invertedColor: base$1.neutralBase,
+ inputColor: overlay$1(base$1.alphaInput),
+ codeColor: overlay$1(base$1.alphaCode),
+ tabColor: overlay$1(base$1.alphaTab),
+ actionColor: overlay$1(base$1.alphaAction),
+ tableHeaderColor: overlay$1(base$1.alphaAction),
+ hoverColor: overlay$1(base$1.alphaPending),
+ tableColorHover: overlay$1(base$1.alphaTablePending),
+ tableColorStriped: overlay$1(base$1.alphaTableStriped),
+ pressedColor: overlay$1(base$1.alphaPressed),
+ opacityDisabled: base$1.alphaDisabled,
+ inputColorDisabled: overlay$1(base$1.alphaDisabledInput),
+ buttonColor2: "rgba(255, 255, 255, .08)",
+ buttonColor2Hover: "rgba(255, 255, 255, .12)",
+ buttonColor2Pressed: "rgba(255, 255, 255, .08)",
+ boxShadow1: "0 1px 2px -2px rgba(0, 0, 0, .24), 0 3px 6px 0 rgba(0, 0, 0, .18), 0 5px 12px 4px rgba(0, 0, 0, .12)",
+ boxShadow2: "0 3px 6px -4px rgba(0, 0, 0, .24), 0 6px 12px 0 rgba(0, 0, 0, .16), 0 9px 18px 8px rgba(0, 0, 0, .10)",
+ boxShadow3: "0 6px 16px -9px rgba(0, 0, 0, .08), 0 9px 28px 0 rgba(0, 0, 0, .05), 0 12px 48px 16px rgba(0, 0, 0, .03)"
+});
+const base = {
+ neutralBase: "#FFF",
+ neutralInvertBase: "#000",
+ neutralTextBase: "#000",
+ neutralPopover: "#fff",
+ neutralCard: "#fff",
+ neutralModal: "#fff",
+ neutralBody: "#fff",
+ alpha1: "0.82",
+ alpha2: "0.72",
+ alpha3: "0.38",
+ alpha4: "0.24",
+ // disabled text, placeholder, icon
+ alpha5: "0.18",
+ // disabled placeholder
+ alphaClose: "0.6",
+ alphaDisabled: "0.5",
+ alphaDisabledInput: "0.02",
+ alphaPending: "0.05",
+ alphaTablePending: "0.02",
+ alphaPressed: "0.07",
+ alphaAvatar: "0.2",
+ alphaRail: "0.14",
+ alphaProgressRail: ".08",
+ alphaBorder: "0.12",
+ alphaDivider: "0.06",
+ alphaInput: "0",
+ alphaAction: "0.02",
+ alphaTab: "0.04",
+ alphaScrollbar: "0.25",
+ alphaScrollbarHover: "0.4",
+ alphaCode: "0.05",
+ alphaTag: "0.02",
+ // primary
+ primaryHover: "#36ad6a",
+ primaryDefault: "#18a058",
+ primaryActive: "#0c7a43",
+ primarySuppl: "#36ad6a",
+ // info
+ infoHover: "#4098fc",
+ infoDefault: "#2080f0",
+ infoActive: "#1060c9",
+ infoSuppl: "#4098fc",
+ // error
+ errorHover: "#de576d",
+ errorDefault: "#d03050",
+ errorActive: "#ab1f3f",
+ errorSuppl: "#de576d",
+ // warning
+ warningHover: "#fcb040",
+ warningDefault: "#f0a020",
+ warningActive: "#c97c10",
+ warningSuppl: "#fcb040",
+ // success
+ successHover: "#36ad6a",
+ successDefault: "#18a058",
+ successActive: "#0c7a43",
+ successSuppl: "#36ad6a"
+};
+const baseBackgroundRgb = rgba(base.neutralBase);
+const baseInvertBackgroundRgb = rgba(base.neutralInvertBase);
+const overlayPrefix = `rgba(${baseInvertBackgroundRgb.slice(0, 3).join(", ")}, `;
+function overlay(alpha) {
+ return `${overlayPrefix + String(alpha)})`;
+}
+function neutral(alpha) {
+ const overlayRgba = Array.from(baseInvertBackgroundRgb);
+ overlayRgba[3] = Number(alpha);
+ return composite(baseBackgroundRgb, overlayRgba);
+}
+const derived = Object.assign(Object.assign({
+ name: "common"
+}, commonVariables$n), {
+ baseColor: base.neutralBase,
+ // primary color
+ primaryColor: base.primaryDefault,
+ primaryColorHover: base.primaryHover,
+ primaryColorPressed: base.primaryActive,
+ primaryColorSuppl: base.primarySuppl,
+ // info color
+ infoColor: base.infoDefault,
+ infoColorHover: base.infoHover,
+ infoColorPressed: base.infoActive,
+ infoColorSuppl: base.infoSuppl,
+ // success color
+ successColor: base.successDefault,
+ successColorHover: base.successHover,
+ successColorPressed: base.successActive,
+ successColorSuppl: base.successSuppl,
+ // warning color
+ warningColor: base.warningDefault,
+ warningColorHover: base.warningHover,
+ warningColorPressed: base.warningActive,
+ warningColorSuppl: base.warningSuppl,
+ // error color
+ errorColor: base.errorDefault,
+ errorColorHover: base.errorHover,
+ errorColorPressed: base.errorActive,
+ errorColorSuppl: base.errorSuppl,
+ // text color
+ textColorBase: base.neutralTextBase,
+ textColor1: "rgb(31, 34, 37)",
+ textColor2: "rgb(51, 54, 57)",
+ textColor3: "rgb(118, 124, 130)",
+ // textColor4: neutral(base.alpha4), // disabled, placeholder, icon
+ // textColor5: neutral(base.alpha5),
+ textColorDisabled: neutral(base.alpha4),
+ placeholderColor: neutral(base.alpha4),
+ placeholderColorDisabled: neutral(base.alpha5),
+ iconColor: neutral(base.alpha4),
+ iconColorHover: scaleColor(neutral(base.alpha4), {
+ lightness: 0.75
+ }),
+ iconColorPressed: scaleColor(neutral(base.alpha4), {
+ lightness: 0.9
+ }),
+ iconColorDisabled: neutral(base.alpha5),
+ opacity1: base.alpha1,
+ opacity2: base.alpha2,
+ opacity3: base.alpha3,
+ opacity4: base.alpha4,
+ opacity5: base.alpha5,
+ dividerColor: "rgb(239, 239, 245)",
+ borderColor: "rgb(224, 224, 230)",
+ // close
+ closeIconColor: neutral(Number(base.alphaClose)),
+ closeIconColorHover: neutral(Number(base.alphaClose)),
+ closeIconColorPressed: neutral(Number(base.alphaClose)),
+ closeColorHover: "rgba(0, 0, 0, .09)",
+ closeColorPressed: "rgba(0, 0, 0, .13)",
+ // clear
+ clearColor: neutral(base.alpha4),
+ clearColorHover: scaleColor(neutral(base.alpha4), {
+ lightness: 0.75
+ }),
+ clearColorPressed: scaleColor(neutral(base.alpha4), {
+ lightness: 0.9
+ }),
+ scrollbarColor: overlay(base.alphaScrollbar),
+ scrollbarColorHover: overlay(base.alphaScrollbarHover),
+ scrollbarWidth: "5px",
+ scrollbarHeight: "5px",
+ scrollbarBorderRadius: "5px",
+ progressRailColor: neutral(base.alphaProgressRail),
+ railColor: "rgb(219, 219, 223)",
+ popoverColor: base.neutralPopover,
+ tableColor: base.neutralCard,
+ cardColor: base.neutralCard,
+ modalColor: base.neutralModal,
+ bodyColor: base.neutralBody,
+ tagColor: "#eee",
+ avatarColor: neutral(base.alphaAvatar),
+ invertedColor: "rgb(0, 20, 40)",
+ inputColor: neutral(base.alphaInput),
+ codeColor: "rgb(244, 244, 248)",
+ tabColor: "rgb(247, 247, 250)",
+ actionColor: "rgb(250, 250, 252)",
+ tableHeaderColor: "rgb(250, 250, 252)",
+ hoverColor: "rgb(243, 243, 245)",
+ // use color with alpha since it can be nested with header filter & sorter effect
+ tableColorHover: "rgba(0, 0, 100, 0.03)",
+ tableColorStriped: "rgba(0, 0, 100, 0.02)",
+ pressedColor: "rgb(237, 237, 239)",
+ opacityDisabled: base.alphaDisabled,
+ inputColorDisabled: "rgb(250, 250, 252)",
+ // secondary button color
+ // can also be used in tertiary button & quaternary button
+ buttonColor2: "rgba(46, 51, 56, .05)",
+ buttonColor2Hover: "rgba(46, 51, 56, .09)",
+ buttonColor2Pressed: "rgba(46, 51, 56, .13)",
+ boxShadow1: "0 1px 2px -2px rgba(0, 0, 0, .08), 0 3px 6px 0 rgba(0, 0, 0, .06), 0 5px 12px 4px rgba(0, 0, 0, .04)",
+ boxShadow2: "0 3px 6px -4px rgba(0, 0, 0, .12), 0 6px 16px 0 rgba(0, 0, 0, .08), 0 9px 28px 8px rgba(0, 0, 0, .05)",
+ boxShadow3: "0 6px 16px -9px rgba(0, 0, 0, .08), 0 9px 28px 0 rgba(0, 0, 0, .05), 0 12px 48px 16px rgba(0, 0, 0, .03)"
+});
+const commonVars$d = {
+ railInsetHorizontalBottom: "auto 2px 4px 2px",
+ railInsetHorizontalTop: "4px 2px auto 2px",
+ railInsetVerticalRight: "2px 4px 2px auto",
+ railInsetVerticalLeft: "2px auto 2px 4px",
+ railColor: "transparent"
+};
+function self$1j(vars) {
+ const {
+ scrollbarColor,
+ scrollbarColorHover,
+ scrollbarHeight,
+ scrollbarWidth,
+ scrollbarBorderRadius
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$d), {
+ height: scrollbarHeight,
+ width: scrollbarWidth,
+ borderRadius: scrollbarBorderRadius,
+ color: scrollbarColor,
+ colorHover: scrollbarColorHover
+ });
+}
+const scrollbarLight = {
+ name: "Scrollbar",
+ common: derived,
+ self: self$1j
+};
+const scrollbarDark = {
+ name: "Scrollbar",
+ common: derived$1,
+ self: self$1j
+};
+const style$8 = cB("scrollbar", `
+ overflow: hidden;
+ position: relative;
+ z-index: auto;
+ height: 100%;
+ width: 100%;
+`, [c(">", [cB("scrollbar-container", `
+ width: 100%;
+ overflow: scroll;
+ height: 100%;
+ min-height: inherit;
+ max-height: inherit;
+ scrollbar-width: none;
+ `, [c("&::-webkit-scrollbar, &::-webkit-scrollbar-track-piece, &::-webkit-scrollbar-thumb", `
+ width: 0;
+ height: 0;
+ display: none;
+ `), c(">", [
+ // We can't set overflow hidden since it affects positioning.
+ cB("scrollbar-content", `
+ box-sizing: border-box;
+ min-width: 100%;
+ `)
+])])]), c(">, +", [cB("scrollbar-rail", `
+ position: absolute;
+ pointer-events: none;
+ user-select: none;
+ background: var(--n-scrollbar-rail-color);
+ -webkit-user-select: none;
+ `, [cM("horizontal", `
+ height: var(--n-scrollbar-height);
+ `, [c(">", [cE("scrollbar", `
+ height: var(--n-scrollbar-height);
+ border-radius: var(--n-scrollbar-border-radius);
+ right: 0;
+ `)])]), cM("horizontal--top", `
+ top: var(--n-scrollbar-rail-top-horizontal-top);
+ right: var(--n-scrollbar-rail-right-horizontal-top);
+ bottom: var(--n-scrollbar-rail-bottom-horizontal-top);
+ left: var(--n-scrollbar-rail-left-horizontal-top);
+ `), cM("horizontal--bottom", `
+ top: var(--n-scrollbar-rail-top-horizontal-bottom);
+ right: var(--n-scrollbar-rail-right-horizontal-bottom);
+ bottom: var(--n-scrollbar-rail-bottom-horizontal-bottom);
+ left: var(--n-scrollbar-rail-left-horizontal-bottom);
+ `), cM("vertical", `
+ width: var(--n-scrollbar-width);
+ `, [c(">", [cE("scrollbar", `
+ width: var(--n-scrollbar-width);
+ border-radius: var(--n-scrollbar-border-radius);
+ bottom: 0;
+ `)])]), cM("vertical--left", `
+ top: var(--n-scrollbar-rail-top-vertical-left);
+ right: var(--n-scrollbar-rail-right-vertical-left);
+ bottom: var(--n-scrollbar-rail-bottom-vertical-left);
+ left: var(--n-scrollbar-rail-left-vertical-left);
+ `), cM("vertical--right", `
+ top: var(--n-scrollbar-rail-top-vertical-right);
+ right: var(--n-scrollbar-rail-right-vertical-right);
+ bottom: var(--n-scrollbar-rail-bottom-vertical-right);
+ left: var(--n-scrollbar-rail-left-vertical-right);
+ `), cM("disabled", [c(">", [cE("scrollbar", "pointer-events: none;")])]), c(">", [cE("scrollbar", `
+ z-index: 1;
+ position: absolute;
+ cursor: pointer;
+ pointer-events: all;
+ background-color: var(--n-scrollbar-color);
+ transition: background-color .2s var(--n-scrollbar-bezier);
+ `, [fadeInTransition(), c("&:hover", "background-color: var(--n-scrollbar-color-hover);")])])])])]);
+const scrollbarProps$1 = Object.assign(Object.assign({}, useTheme.props), {
+ duration: {
+ type: Number,
+ default: 0
+ },
+ scrollable: {
+ type: Boolean,
+ default: true
+ },
+ xScrollable: Boolean,
+ trigger: {
+ type: String,
+ default: "hover"
+ },
+ useUnifiedContainer: Boolean,
+ triggerDisplayManually: Boolean,
+ // If container is set, resize observer won't not attached
+ container: Function,
+ content: Function,
+ containerClass: String,
+ containerStyle: [String, Object],
+ contentClass: [String, Array],
+ contentStyle: [String, Object],
+ horizontalRailStyle: [String, Object],
+ verticalRailStyle: [String, Object],
+ onScroll: Function,
+ onWheel: Function,
+ onResize: Function,
+ internalOnUpdateScrollLeft: Function,
+ internalHoistYRail: Boolean,
+ yPlacement: {
+ type: String,
+ default: "right"
+ },
+ xPlacement: {
+ type: String,
+ default: "bottom"
+ }
+});
+const Scrollbar$1 = /* @__PURE__ */ defineComponent({
+ name: "Scrollbar",
+ props: scrollbarProps$1,
+ inheritAttrs: false,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const rtlEnabledRef = useRtl("Scrollbar", mergedRtlRef, mergedClsPrefixRef);
+ const wrapperRef = ref(null);
+ const containerRef = ref(null);
+ const contentRef = ref(null);
+ const yRailRef = ref(null);
+ const xRailRef = ref(null);
+ const contentHeightRef = ref(null);
+ const contentWidthRef = ref(null);
+ const containerHeightRef = ref(null);
+ const containerWidthRef = ref(null);
+ const yRailSizeRef = ref(null);
+ const xRailSizeRef = ref(null);
+ const containerScrollTopRef = ref(0);
+ const containerScrollLeftRef = ref(0);
+ const isShowXBarRef = ref(false);
+ const isShowYBarRef = ref(false);
+ let yBarPressed = false;
+ let xBarPressed = false;
+ let xBarVanishTimerId;
+ let yBarVanishTimerId;
+ let memoYTop = 0;
+ let memoXLeft = 0;
+ let memoMouseX = 0;
+ let memoMouseY = 0;
+ const isIos2 = useIsIos();
+ const themeRef = useTheme("Scrollbar", "-scrollbar", style$8, scrollbarLight, props, mergedClsPrefixRef);
+ const yBarSizeRef = computed(() => {
+ const {
+ value: containerHeight
+ } = containerHeightRef;
+ const {
+ value: contentHeight
+ } = contentHeightRef;
+ const {
+ value: yRailSize
+ } = yRailSizeRef;
+ if (containerHeight === null || contentHeight === null || yRailSize === null) {
+ return 0;
+ } else {
+ return Math.min(containerHeight, yRailSize * containerHeight / contentHeight + depx(themeRef.value.self.width) * 1.5);
+ }
+ });
+ const yBarSizePxRef = computed(() => {
+ return `${yBarSizeRef.value}px`;
+ });
+ const xBarSizeRef = computed(() => {
+ const {
+ value: containerWidth
+ } = containerWidthRef;
+ const {
+ value: contentWidth
+ } = contentWidthRef;
+ const {
+ value: xRailSize
+ } = xRailSizeRef;
+ if (containerWidth === null || contentWidth === null || xRailSize === null) {
+ return 0;
+ } else {
+ return xRailSize * containerWidth / contentWidth + depx(themeRef.value.self.height) * 1.5;
+ }
+ });
+ const xBarSizePxRef = computed(() => {
+ return `${xBarSizeRef.value}px`;
+ });
+ const yBarTopRef = computed(() => {
+ const {
+ value: containerHeight
+ } = containerHeightRef;
+ const {
+ value: containerScrollTop
+ } = containerScrollTopRef;
+ const {
+ value: contentHeight
+ } = contentHeightRef;
+ const {
+ value: yRailSize
+ } = yRailSizeRef;
+ if (containerHeight === null || contentHeight === null || yRailSize === null) {
+ return 0;
+ } else {
+ const heightDiff = contentHeight - containerHeight;
+ if (!heightDiff) return 0;
+ return containerScrollTop / heightDiff * (yRailSize - yBarSizeRef.value);
+ }
+ });
+ const yBarTopPxRef = computed(() => {
+ return `${yBarTopRef.value}px`;
+ });
+ const xBarLeftRef = computed(() => {
+ const {
+ value: containerWidth
+ } = containerWidthRef;
+ const {
+ value: containerScrollLeft
+ } = containerScrollLeftRef;
+ const {
+ value: contentWidth
+ } = contentWidthRef;
+ const {
+ value: xRailSize
+ } = xRailSizeRef;
+ if (containerWidth === null || contentWidth === null || xRailSize === null) {
+ return 0;
+ } else {
+ const widthDiff = contentWidth - containerWidth;
+ if (!widthDiff) return 0;
+ return containerScrollLeft / widthDiff * (xRailSize - xBarSizeRef.value);
+ }
+ });
+ const xBarLeftPxRef = computed(() => {
+ return `${xBarLeftRef.value}px`;
+ });
+ const needYBarRef = computed(() => {
+ const {
+ value: containerHeight
+ } = containerHeightRef;
+ const {
+ value: contentHeight
+ } = contentHeightRef;
+ return containerHeight !== null && contentHeight !== null && contentHeight > containerHeight;
+ });
+ const needXBarRef = computed(() => {
+ const {
+ value: containerWidth
+ } = containerWidthRef;
+ const {
+ value: contentWidth
+ } = contentWidthRef;
+ return containerWidth !== null && contentWidth !== null && contentWidth > containerWidth;
+ });
+ const mergedShowXBarRef = computed(() => {
+ const {
+ trigger: trigger2
+ } = props;
+ return trigger2 === "none" || isShowXBarRef.value;
+ });
+ const mergedShowYBarRef = computed(() => {
+ const {
+ trigger: trigger2
+ } = props;
+ return trigger2 === "none" || isShowYBarRef.value;
+ });
+ const mergedContainerRef = computed(() => {
+ const {
+ container
+ } = props;
+ if (container) return container();
+ return containerRef.value;
+ });
+ const mergedContentRef = computed(() => {
+ const {
+ content
+ } = props;
+ if (content) return content();
+ return contentRef.value;
+ });
+ const scrollTo = (options, y) => {
+ if (!props.scrollable) return;
+ if (typeof options === "number") {
+ scrollToPosition2(options, y !== null && y !== void 0 ? y : 0, 0, false, "auto");
+ return;
+ }
+ const {
+ left,
+ top,
+ index,
+ elSize,
+ position,
+ behavior,
+ el,
+ debounce = true
+ } = options;
+ if (left !== void 0 || top !== void 0) {
+ scrollToPosition2(left !== null && left !== void 0 ? left : 0, top !== null && top !== void 0 ? top : 0, 0, false, behavior);
+ }
+ if (el !== void 0) {
+ scrollToPosition2(0, el.offsetTop, el.offsetHeight, debounce, behavior);
+ } else if (index !== void 0 && elSize !== void 0) {
+ scrollToPosition2(0, index * elSize, elSize, debounce, behavior);
+ } else if (position === "bottom") {
+ scrollToPosition2(0, Number.MAX_SAFE_INTEGER, 0, false, behavior);
+ } else if (position === "top") {
+ scrollToPosition2(0, 0, 0, false, behavior);
+ }
+ };
+ const activateState = useReactivated(() => {
+ if (!props.container) {
+ scrollTo({
+ top: containerScrollTopRef.value,
+ left: containerScrollLeftRef.value
+ });
+ }
+ });
+ const handleContentResize = () => {
+ if (activateState.isDeactivated) return;
+ sync();
+ };
+ const handleContainerResize = (e) => {
+ if (activateState.isDeactivated) return;
+ const {
+ onResize
+ } = props;
+ if (onResize) onResize(e);
+ sync();
+ };
+ const scrollBy = (options, y) => {
+ if (!props.scrollable) return;
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (!container) return;
+ if (typeof options === "object") {
+ container.scrollBy(options);
+ } else {
+ container.scrollBy(options, y || 0);
+ }
+ };
+ function scrollToPosition2(left, top, elSize, debounce, behavior) {
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (!container) return;
+ if (debounce) {
+ const {
+ scrollTop,
+ offsetHeight
+ } = container;
+ if (top > scrollTop) {
+ if (top + elSize <= scrollTop + offsetHeight) ;
+ else {
+ container.scrollTo({
+ left,
+ top: top + elSize - offsetHeight,
+ behavior
+ });
+ }
+ return;
+ }
+ }
+ container.scrollTo({
+ left,
+ top,
+ behavior
+ });
+ }
+ function handleMouseEnterWrapper() {
+ showXBar();
+ showYBar();
+ sync();
+ }
+ function handleMouseLeaveWrapper() {
+ hideBar();
+ }
+ function hideBar() {
+ hideYBar();
+ hideXBar();
+ }
+ function hideYBar() {
+ if (yBarVanishTimerId !== void 0) {
+ window.clearTimeout(yBarVanishTimerId);
+ }
+ yBarVanishTimerId = window.setTimeout(() => {
+ isShowYBarRef.value = false;
+ }, props.duration);
+ }
+ function hideXBar() {
+ if (xBarVanishTimerId !== void 0) {
+ window.clearTimeout(xBarVanishTimerId);
+ }
+ xBarVanishTimerId = window.setTimeout(() => {
+ isShowXBarRef.value = false;
+ }, props.duration);
+ }
+ function showXBar() {
+ if (xBarVanishTimerId !== void 0) {
+ window.clearTimeout(xBarVanishTimerId);
+ }
+ isShowXBarRef.value = true;
+ }
+ function showYBar() {
+ if (yBarVanishTimerId !== void 0) {
+ window.clearTimeout(yBarVanishTimerId);
+ }
+ isShowYBarRef.value = true;
+ }
+ function handleScroll(e) {
+ const {
+ onScroll
+ } = props;
+ if (onScroll) onScroll(e);
+ syncScrollState();
+ }
+ function syncScrollState() {
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (container) {
+ containerScrollTopRef.value = container.scrollTop;
+ containerScrollLeftRef.value = container.scrollLeft * ((rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? -1 : 1);
+ }
+ }
+ function syncPositionState() {
+ const {
+ value: content
+ } = mergedContentRef;
+ if (content) {
+ contentHeightRef.value = content.offsetHeight;
+ contentWidthRef.value = content.offsetWidth;
+ }
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (container) {
+ containerHeightRef.value = container.offsetHeight;
+ containerWidthRef.value = container.offsetWidth;
+ }
+ const {
+ value: xRailEl
+ } = xRailRef;
+ const {
+ value: yRailEl
+ } = yRailRef;
+ if (xRailEl) {
+ xRailSizeRef.value = xRailEl.offsetWidth;
+ }
+ if (yRailEl) {
+ yRailSizeRef.value = yRailEl.offsetHeight;
+ }
+ }
+ function syncUnifiedContainer() {
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (container) {
+ containerScrollTopRef.value = container.scrollTop;
+ containerScrollLeftRef.value = container.scrollLeft * ((rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? -1 : 1);
+ containerHeightRef.value = container.offsetHeight;
+ containerWidthRef.value = container.offsetWidth;
+ contentHeightRef.value = container.scrollHeight;
+ contentWidthRef.value = container.scrollWidth;
+ }
+ const {
+ value: xRailEl
+ } = xRailRef;
+ const {
+ value: yRailEl
+ } = yRailRef;
+ if (xRailEl) {
+ xRailSizeRef.value = xRailEl.offsetWidth;
+ }
+ if (yRailEl) {
+ yRailSizeRef.value = yRailEl.offsetHeight;
+ }
+ }
+ function sync() {
+ if (!props.scrollable) return;
+ if (props.useUnifiedContainer) {
+ syncUnifiedContainer();
+ } else {
+ syncPositionState();
+ syncScrollState();
+ }
+ }
+ function isMouseUpAway(e) {
+ var _a;
+ return !((_a = wrapperRef.value) === null || _a === void 0 ? void 0 : _a.contains(getPreciseEventTarget(e)));
+ }
+ function handleXScrollMouseDown(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ xBarPressed = true;
+ on("mousemove", window, handleXScrollMouseMove, true);
+ on("mouseup", window, handleXScrollMouseUp, true);
+ memoXLeft = containerScrollLeftRef.value;
+ memoMouseX = (rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? window.innerWidth - e.clientX : e.clientX;
+ }
+ function handleXScrollMouseMove(e) {
+ if (!xBarPressed) return;
+ if (xBarVanishTimerId !== void 0) {
+ window.clearTimeout(xBarVanishTimerId);
+ }
+ if (yBarVanishTimerId !== void 0) {
+ window.clearTimeout(yBarVanishTimerId);
+ }
+ const {
+ value: containerWidth
+ } = containerWidthRef;
+ const {
+ value: contentWidth
+ } = contentWidthRef;
+ const {
+ value: xBarSize
+ } = xBarSizeRef;
+ if (containerWidth === null || contentWidth === null) return;
+ const dX = (rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? window.innerWidth - e.clientX - memoMouseX : e.clientX - memoMouseX;
+ const dScrollLeft = dX * (contentWidth - containerWidth) / (containerWidth - xBarSize);
+ const toScrollLeftUpperBound = contentWidth - containerWidth;
+ let toScrollLeft = memoXLeft + dScrollLeft;
+ toScrollLeft = Math.min(toScrollLeftUpperBound, toScrollLeft);
+ toScrollLeft = Math.max(toScrollLeft, 0);
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (container) {
+ container.scrollLeft = toScrollLeft * ((rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? -1 : 1);
+ const {
+ internalOnUpdateScrollLeft
+ } = props;
+ if (internalOnUpdateScrollLeft) internalOnUpdateScrollLeft(toScrollLeft);
+ }
+ }
+ function handleXScrollMouseUp(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ off("mousemove", window, handleXScrollMouseMove, true);
+ off("mouseup", window, handleXScrollMouseUp, true);
+ xBarPressed = false;
+ sync();
+ if (isMouseUpAway(e)) {
+ hideBar();
+ }
+ }
+ function handleYScrollMouseDown(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ yBarPressed = true;
+ on("mousemove", window, handleYScrollMouseMove, true);
+ on("mouseup", window, handleYScrollMouseUp, true);
+ memoYTop = containerScrollTopRef.value;
+ memoMouseY = e.clientY;
+ }
+ function handleYScrollMouseMove(e) {
+ if (!yBarPressed) return;
+ if (xBarVanishTimerId !== void 0) {
+ window.clearTimeout(xBarVanishTimerId);
+ }
+ if (yBarVanishTimerId !== void 0) {
+ window.clearTimeout(yBarVanishTimerId);
+ }
+ const {
+ value: containerHeight
+ } = containerHeightRef;
+ const {
+ value: contentHeight
+ } = contentHeightRef;
+ const {
+ value: yBarSize
+ } = yBarSizeRef;
+ if (containerHeight === null || contentHeight === null) return;
+ const dY = e.clientY - memoMouseY;
+ const dScrollTop = dY * (contentHeight - containerHeight) / (containerHeight - yBarSize);
+ const toScrollTopUpperBound = contentHeight - containerHeight;
+ let toScrollTop = memoYTop + dScrollTop;
+ toScrollTop = Math.min(toScrollTopUpperBound, toScrollTop);
+ toScrollTop = Math.max(toScrollTop, 0);
+ const {
+ value: container
+ } = mergedContainerRef;
+ if (container) {
+ container.scrollTop = toScrollTop;
+ }
+ }
+ function handleYScrollMouseUp(e) {
+ e.preventDefault();
+ e.stopPropagation();
+ off("mousemove", window, handleYScrollMouseMove, true);
+ off("mouseup", window, handleYScrollMouseUp, true);
+ yBarPressed = false;
+ sync();
+ if (isMouseUpAway(e)) {
+ hideBar();
+ }
+ }
+ watchEffect(() => {
+ const {
+ value: needXBar
+ } = needXBarRef;
+ const {
+ value: needYBar
+ } = needYBarRef;
+ const {
+ value: mergedClsPrefix
+ } = mergedClsPrefixRef;
+ const {
+ value: xRailEl
+ } = xRailRef;
+ const {
+ value: yRailEl
+ } = yRailRef;
+ if (xRailEl) {
+ if (!needXBar) {
+ xRailEl.classList.add(`${mergedClsPrefix}-scrollbar-rail--disabled`);
+ } else {
+ xRailEl.classList.remove(`${mergedClsPrefix}-scrollbar-rail--disabled`);
+ }
+ }
+ if (yRailEl) {
+ if (!needYBar) {
+ yRailEl.classList.add(`${mergedClsPrefix}-scrollbar-rail--disabled`);
+ } else {
+ yRailEl.classList.remove(`${mergedClsPrefix}-scrollbar-rail--disabled`);
+ }
+ }
+ });
+ onMounted(() => {
+ if (props.container) return;
+ sync();
+ });
+ onBeforeUnmount(() => {
+ if (xBarVanishTimerId !== void 0) {
+ window.clearTimeout(xBarVanishTimerId);
+ }
+ if (yBarVanishTimerId !== void 0) {
+ window.clearTimeout(yBarVanishTimerId);
+ }
+ off("mousemove", window, handleYScrollMouseMove, true);
+ off("mouseup", window, handleYScrollMouseUp, true);
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ },
+ self: {
+ color,
+ colorHover,
+ height,
+ width,
+ borderRadius,
+ railInsetHorizontalTop,
+ railInsetHorizontalBottom,
+ railInsetVerticalRight,
+ railInsetVerticalLeft,
+ railColor
+ }
+ } = themeRef.value;
+ const {
+ top: railTopHorizontalTop,
+ right: railRightHorizontalTop,
+ bottom: railBottomHorizontalTop,
+ left: railLeftHorizontalTop
+ } = getMargin(railInsetHorizontalTop);
+ const {
+ top: railTopHorizontalBottom,
+ right: railRightHorizontalBottom,
+ bottom: railBottomHorizontalBottom,
+ left: railLeftHorizontalBottom
+ } = getMargin(railInsetHorizontalBottom);
+ const {
+ top: railTopVerticalRight,
+ right: railRightVerticalRight,
+ bottom: railBottomVerticalRight,
+ left: railLeftVerticalRight
+ } = getMargin((rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? rtlInset(railInsetVerticalRight) : railInsetVerticalRight);
+ const {
+ top: railTopVerticalLeft,
+ right: railRightVerticalLeft,
+ bottom: railBottomVerticalLeft,
+ left: railLeftVerticalLeft
+ } = getMargin((rtlEnabledRef === null || rtlEnabledRef === void 0 ? void 0 : rtlEnabledRef.value) ? rtlInset(railInsetVerticalLeft) : railInsetVerticalLeft);
+ return {
+ "--n-scrollbar-bezier": cubicBezierEaseInOut2,
+ "--n-scrollbar-color": color,
+ "--n-scrollbar-color-hover": colorHover,
+ "--n-scrollbar-border-radius": borderRadius,
+ "--n-scrollbar-width": width,
+ "--n-scrollbar-height": height,
+ "--n-scrollbar-rail-top-horizontal-top": railTopHorizontalTop,
+ "--n-scrollbar-rail-right-horizontal-top": railRightHorizontalTop,
+ "--n-scrollbar-rail-bottom-horizontal-top": railBottomHorizontalTop,
+ "--n-scrollbar-rail-left-horizontal-top": railLeftHorizontalTop,
+ "--n-scrollbar-rail-top-horizontal-bottom": railTopHorizontalBottom,
+ "--n-scrollbar-rail-right-horizontal-bottom": railRightHorizontalBottom,
+ "--n-scrollbar-rail-bottom-horizontal-bottom": railBottomHorizontalBottom,
+ "--n-scrollbar-rail-left-horizontal-bottom": railLeftHorizontalBottom,
+ "--n-scrollbar-rail-top-vertical-right": railTopVerticalRight,
+ "--n-scrollbar-rail-right-vertical-right": railRightVerticalRight,
+ "--n-scrollbar-rail-bottom-vertical-right": railBottomVerticalRight,
+ "--n-scrollbar-rail-left-vertical-right": railLeftVerticalRight,
+ "--n-scrollbar-rail-top-vertical-left": railTopVerticalLeft,
+ "--n-scrollbar-rail-right-vertical-left": railRightVerticalLeft,
+ "--n-scrollbar-rail-bottom-vertical-left": railBottomVerticalLeft,
+ "--n-scrollbar-rail-left-vertical-left": railLeftVerticalLeft,
+ "--n-scrollbar-rail-color": railColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("scrollbar", void 0, cssVarsRef, props) : void 0;
+ const exposedMethods = {
+ scrollTo,
+ scrollBy,
+ sync,
+ syncUnifiedContainer,
+ handleMouseEnterWrapper,
+ handleMouseLeaveWrapper
+ };
+ return Object.assign(Object.assign({}, exposedMethods), {
+ mergedClsPrefix: mergedClsPrefixRef,
+ rtlEnabled: rtlEnabledRef,
+ containerScrollTop: containerScrollTopRef,
+ wrapperRef,
+ containerRef,
+ contentRef,
+ yRailRef,
+ xRailRef,
+ needYBar: needYBarRef,
+ needXBar: needXBarRef,
+ yBarSizePx: yBarSizePxRef,
+ xBarSizePx: xBarSizePxRef,
+ yBarTopPx: yBarTopPxRef,
+ xBarLeftPx: xBarLeftPxRef,
+ isShowXBar: mergedShowXBarRef,
+ isShowYBar: mergedShowYBarRef,
+ isIos: isIos2,
+ handleScroll,
+ handleContentResize,
+ handleContainerResize,
+ handleYScrollMouseDown,
+ handleXScrollMouseDown,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ });
+ },
+ render() {
+ var _a;
+ const {
+ $slots,
+ mergedClsPrefix,
+ triggerDisplayManually,
+ rtlEnabled,
+ internalHoistYRail,
+ yPlacement,
+ xPlacement,
+ xScrollable
+ } = this;
+ if (!this.scrollable) return (_a = $slots.default) === null || _a === void 0 ? void 0 : _a.call($slots);
+ const triggerIsNone = this.trigger === "none";
+ const createYRail = (className, style2) => {
+ return h("div", {
+ ref: "yRailRef",
+ class: [`${mergedClsPrefix}-scrollbar-rail`, `${mergedClsPrefix}-scrollbar-rail--vertical`, `${mergedClsPrefix}-scrollbar-rail--vertical--${yPlacement}`, className],
+ "data-scrollbar-rail": true,
+ style: [style2 || "", this.verticalRailStyle],
+ "aria-hidden": true
+ }, h(triggerIsNone ? Wrapper : Transition, triggerIsNone ? null : {
+ name: "fade-in-transition"
+ }, {
+ default: () => this.needYBar && this.isShowYBar && !this.isIos ? h("div", {
+ class: `${mergedClsPrefix}-scrollbar-rail__scrollbar`,
+ style: {
+ height: this.yBarSizePx,
+ top: this.yBarTopPx
+ },
+ onMousedown: this.handleYScrollMouseDown
+ }) : null
+ }));
+ };
+ const createChildren = () => {
+ var _a2, _b;
+ (_a2 = this.onRender) === null || _a2 === void 0 ? void 0 : _a2.call(this);
+ return h("div", mergeProps(this.$attrs, {
+ role: "none",
+ ref: "wrapperRef",
+ class: [`${mergedClsPrefix}-scrollbar`, this.themeClass, rtlEnabled && `${mergedClsPrefix}-scrollbar--rtl`],
+ style: this.cssVars,
+ onMouseenter: triggerDisplayManually ? void 0 : this.handleMouseEnterWrapper,
+ onMouseleave: triggerDisplayManually ? void 0 : this.handleMouseLeaveWrapper
+ }), [this.container ? (_b = $slots.default) === null || _b === void 0 ? void 0 : _b.call($slots) : h("div", {
+ role: "none",
+ ref: "containerRef",
+ class: [`${mergedClsPrefix}-scrollbar-container`, this.containerClass],
+ style: this.containerStyle,
+ onScroll: this.handleScroll,
+ onWheel: this.onWheel
+ }, h(VResizeObserver, {
+ onResize: this.handleContentResize
+ }, {
+ default: () => h("div", {
+ ref: "contentRef",
+ role: "none",
+ style: [{
+ width: this.xScrollable ? "fit-content" : null
+ }, this.contentStyle],
+ class: [`${mergedClsPrefix}-scrollbar-content`, this.contentClass]
+ }, $slots)
+ })), internalHoistYRail ? null : createYRail(void 0, void 0), xScrollable && h("div", {
+ ref: "xRailRef",
+ class: [`${mergedClsPrefix}-scrollbar-rail`, `${mergedClsPrefix}-scrollbar-rail--horizontal`, `${mergedClsPrefix}-scrollbar-rail--horizontal--${xPlacement}`],
+ style: this.horizontalRailStyle,
+ "data-scrollbar-rail": true,
+ "aria-hidden": true
+ }, h(triggerIsNone ? Wrapper : Transition, triggerIsNone ? null : {
+ name: "fade-in-transition"
+ }, {
+ default: () => this.needXBar && this.isShowXBar && !this.isIos ? h("div", {
+ class: `${mergedClsPrefix}-scrollbar-rail__scrollbar`,
+ style: {
+ width: this.xBarSizePx,
+ right: rtlEnabled ? this.xBarLeftPx : void 0,
+ left: rtlEnabled ? void 0 : this.xBarLeftPx
+ },
+ onMousedown: this.handleXScrollMouseDown
+ }) : null
+ }))]);
+ };
+ const scrollbarNode = this.container ? createChildren() : h(VResizeObserver, {
+ onResize: this.handleContainerResize
+ }, {
+ default: createChildren
+ });
+ if (internalHoistYRail) {
+ return h(Fragment, null, scrollbarNode, createYRail(this.themeClass, this.cssVars));
+ } else {
+ return scrollbarNode;
+ }
+ }
+});
+const XScrollbar = Scrollbar$1;
+const commonVars$c = {
+ iconSizeTiny: "28px",
+ iconSizeSmall: "34px",
+ iconSizeMedium: "40px",
+ iconSizeLarge: "46px",
+ iconSizeHuge: "52px"
+};
+function self$1i(vars) {
+ const {
+ textColorDisabled,
+ iconColor,
+ textColor2,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ fontSizeHuge
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$c), {
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ fontSizeHuge,
+ textColor: textColorDisabled,
+ iconColor,
+ extraTextColor: textColor2
+ });
+}
+const emptyLight = {
+ name: "Empty",
+ common: derived,
+ self: self$1i
+};
+const emptyDark = {
+ name: "Empty",
+ common: derived$1,
+ self: self$1i
+};
+const commonVariables$m = {
+ height: "calc(var(--n-option-height) * 7.6)",
+ paddingTiny: "4px 0",
+ paddingSmall: "4px 0",
+ paddingMedium: "4px 0",
+ paddingLarge: "4px 0",
+ paddingHuge: "4px 0",
+ optionPaddingTiny: "0 12px",
+ optionPaddingSmall: "0 12px",
+ optionPaddingMedium: "0 12px",
+ optionPaddingLarge: "0 12px",
+ optionPaddingHuge: "0 12px",
+ loadingSize: "18px"
+};
+function self$1h(vars) {
+ const {
+ borderRadius,
+ popoverColor,
+ textColor3,
+ dividerColor,
+ textColor2,
+ primaryColorPressed,
+ textColorDisabled,
+ primaryColor,
+ opacityDisabled,
+ hoverColor,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ fontSizeHuge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ heightHuge
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$m), {
+ optionFontSizeTiny: fontSizeTiny,
+ optionFontSizeSmall: fontSizeSmall,
+ optionFontSizeMedium: fontSizeMedium,
+ optionFontSizeLarge: fontSizeLarge,
+ optionFontSizeHuge: fontSizeHuge,
+ optionHeightTiny: heightTiny,
+ optionHeightSmall: heightSmall,
+ optionHeightMedium: heightMedium,
+ optionHeightLarge: heightLarge,
+ optionHeightHuge: heightHuge,
+ borderRadius,
+ color: popoverColor,
+ groupHeaderTextColor: textColor3,
+ actionDividerColor: dividerColor,
+ optionTextColor: textColor2,
+ optionTextColorPressed: primaryColorPressed,
+ optionTextColorDisabled: textColorDisabled,
+ optionTextColorActive: primaryColor,
+ optionOpacityDisabled: opacityDisabled,
+ optionCheckColor: primaryColor,
+ optionColorPending: hoverColor,
+ optionColorActive: "rgba(0, 0, 0, 0)",
+ optionColorActivePending: hoverColor,
+ actionTextColor: textColor2,
+ loadingColor: primaryColor
+ });
+}
+const internalSelectMenuLight = createTheme({
+ name: "InternalSelectMenu",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight,
+ Empty: emptyLight
+ },
+ self: self$1h
+});
+const internalSelectMenuDark = {
+ name: "InternalSelectMenu",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark,
+ Empty: emptyDark
+ },
+ self: self$1h
+};
+const {
+ cubicBezierEaseIn: cubicBezierEaseIn$1,
+ cubicBezierEaseOut: cubicBezierEaseOut$1
+} = commonVariables$n;
+function fadeInScaleUpTransition({
+ transformOrigin = "inherit",
+ duration: duration2 = ".2s",
+ enterScale = ".9",
+ originalTransform = "",
+ originalTransition = ""
+} = {}) {
+ return [c("&.fade-in-scale-up-transition-leave-active", {
+ transformOrigin,
+ transition: `opacity ${duration2} ${cubicBezierEaseIn$1}, transform ${duration2} ${cubicBezierEaseIn$1} ${originalTransition && `,${originalTransition}`}`
+ }), c("&.fade-in-scale-up-transition-enter-active", {
+ transformOrigin,
+ transition: `opacity ${duration2} ${cubicBezierEaseOut$1}, transform ${duration2} ${cubicBezierEaseOut$1} ${originalTransition && `,${originalTransition}`}`
+ }), c("&.fade-in-scale-up-transition-enter-from, &.fade-in-scale-up-transition-leave-to", {
+ opacity: 0,
+ transform: `${originalTransform} scale(${enterScale})`
+ }), c("&.fade-in-scale-up-transition-leave-from, &.fade-in-scale-up-transition-enter-to", {
+ opacity: 1,
+ transform: `${originalTransform} scale(1)`
+ })];
+}
+const commonVariables$l = {
+ space: "6px",
+ spaceArrow: "10px",
+ arrowOffset: "10px",
+ arrowOffsetVertical: "10px",
+ arrowHeight: "6px",
+ padding: "8px 14px"
+};
+function self$1g(vars) {
+ const {
+ boxShadow2,
+ popoverColor,
+ textColor2,
+ borderRadius,
+ fontSize: fontSize2,
+ dividerColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$l), {
+ fontSize: fontSize2,
+ borderRadius,
+ color: popoverColor,
+ dividerColor,
+ textColor: textColor2,
+ boxShadow: boxShadow2
+ });
+}
+const popoverLight = {
+ name: "Popover",
+ common: derived,
+ self: self$1g
+};
+const popoverDark = {
+ name: "Popover",
+ common: derived$1,
+ self: self$1g
+};
+const commonVariables$k = {
+ closeIconSizeTiny: "12px",
+ closeIconSizeSmall: "12px",
+ closeIconSizeMedium: "14px",
+ closeIconSizeLarge: "14px",
+ closeSizeTiny: "16px",
+ closeSizeSmall: "16px",
+ closeSizeMedium: "18px",
+ closeSizeLarge: "18px",
+ padding: "0 7px",
+ closeMargin: "0 0 0 4px"
+};
+const tagDark = {
+ name: "Tag",
+ common: derived$1,
+ self(vars) {
+ const {
+ textColor2,
+ primaryColorHover,
+ primaryColorPressed,
+ primaryColor,
+ infoColor,
+ successColor,
+ warningColor,
+ errorColor,
+ baseColor,
+ borderColor,
+ tagColor,
+ opacityDisabled,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ borderRadiusSmall: borderRadius,
+ fontSizeMini,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ heightMini,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ buttonColor2Hover,
+ buttonColor2Pressed,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$k), {
+ closeBorderRadius: borderRadius,
+ heightTiny: heightMini,
+ heightSmall: heightTiny,
+ heightMedium: heightSmall,
+ heightLarge: heightMedium,
+ borderRadius,
+ opacityDisabled,
+ fontSizeTiny: fontSizeMini,
+ fontSizeSmall: fontSizeTiny,
+ fontSizeMedium: fontSizeSmall,
+ fontSizeLarge: fontSizeMedium,
+ fontWeightStrong,
+ // checked
+ textColorCheckable: textColor2,
+ textColorHoverCheckable: textColor2,
+ textColorPressedCheckable: textColor2,
+ textColorChecked: baseColor,
+ colorCheckable: "#0000",
+ colorHoverCheckable: buttonColor2Hover,
+ colorPressedCheckable: buttonColor2Pressed,
+ colorChecked: primaryColor,
+ colorCheckedHover: primaryColorHover,
+ colorCheckedPressed: primaryColorPressed,
+ // default
+ border: `1px solid ${borderColor}`,
+ textColor: textColor2,
+ color: tagColor,
+ colorBordered: "#0000",
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ borderPrimary: `1px solid ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ textColorPrimary: primaryColor,
+ colorPrimary: changeColor(primaryColor, {
+ alpha: 0.16
+ }),
+ colorBorderedPrimary: "#0000",
+ closeIconColorPrimary: scaleColor(primaryColor, {
+ lightness: 0.7
+ }),
+ closeIconColorHoverPrimary: scaleColor(primaryColor, {
+ lightness: 0.7
+ }),
+ closeIconColorPressedPrimary: scaleColor(primaryColor, {
+ lightness: 0.7
+ }),
+ closeColorHoverPrimary: changeColor(primaryColor, {
+ alpha: 0.16
+ }),
+ closeColorPressedPrimary: changeColor(primaryColor, {
+ alpha: 0.12
+ }),
+ borderInfo: `1px solid ${changeColor(infoColor, {
+ alpha: 0.3
+ })}`,
+ textColorInfo: infoColor,
+ colorInfo: changeColor(infoColor, {
+ alpha: 0.16
+ }),
+ colorBorderedInfo: "#0000",
+ closeIconColorInfo: scaleColor(infoColor, {
+ alpha: 0.7
+ }),
+ closeIconColorHoverInfo: scaleColor(infoColor, {
+ alpha: 0.7
+ }),
+ closeIconColorPressedInfo: scaleColor(infoColor, {
+ alpha: 0.7
+ }),
+ closeColorHoverInfo: changeColor(infoColor, {
+ alpha: 0.16
+ }),
+ closeColorPressedInfo: changeColor(infoColor, {
+ alpha: 0.12
+ }),
+ borderSuccess: `1px solid ${changeColor(successColor, {
+ alpha: 0.3
+ })}`,
+ textColorSuccess: successColor,
+ colorSuccess: changeColor(successColor, {
+ alpha: 0.16
+ }),
+ colorBorderedSuccess: "#0000",
+ closeIconColorSuccess: scaleColor(successColor, {
+ alpha: 0.7
+ }),
+ closeIconColorHoverSuccess: scaleColor(successColor, {
+ alpha: 0.7
+ }),
+ closeIconColorPressedSuccess: scaleColor(successColor, {
+ alpha: 0.7
+ }),
+ closeColorHoverSuccess: changeColor(successColor, {
+ alpha: 0.16
+ }),
+ closeColorPressedSuccess: changeColor(successColor, {
+ alpha: 0.12
+ }),
+ borderWarning: `1px solid ${changeColor(warningColor, {
+ alpha: 0.3
+ })}`,
+ textColorWarning: warningColor,
+ colorWarning: changeColor(warningColor, {
+ alpha: 0.16
+ }),
+ colorBorderedWarning: "#0000",
+ closeIconColorWarning: scaleColor(warningColor, {
+ alpha: 0.7
+ }),
+ closeIconColorHoverWarning: scaleColor(warningColor, {
+ alpha: 0.7
+ }),
+ closeIconColorPressedWarning: scaleColor(warningColor, {
+ alpha: 0.7
+ }),
+ closeColorHoverWarning: changeColor(warningColor, {
+ alpha: 0.16
+ }),
+ closeColorPressedWarning: changeColor(warningColor, {
+ alpha: 0.11
+ }),
+ borderError: `1px solid ${changeColor(errorColor, {
+ alpha: 0.3
+ })}`,
+ textColorError: errorColor,
+ colorError: changeColor(errorColor, {
+ alpha: 0.16
+ }),
+ colorBorderedError: "#0000",
+ closeIconColorError: scaleColor(errorColor, {
+ alpha: 0.7
+ }),
+ closeIconColorHoverError: scaleColor(errorColor, {
+ alpha: 0.7
+ }),
+ closeIconColorPressedError: scaleColor(errorColor, {
+ alpha: 0.7
+ }),
+ closeColorHoverError: changeColor(errorColor, {
+ alpha: 0.16
+ }),
+ closeColorPressedError: changeColor(errorColor, {
+ alpha: 0.12
+ })
+ });
+ }
+};
+function self$1f(vars) {
+ const {
+ textColor2,
+ primaryColorHover,
+ primaryColorPressed,
+ primaryColor,
+ infoColor,
+ successColor,
+ warningColor,
+ errorColor,
+ baseColor,
+ borderColor,
+ opacityDisabled,
+ tagColor,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ borderRadiusSmall: borderRadius,
+ fontSizeMini,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ heightMini,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ closeColorHover,
+ closeColorPressed,
+ buttonColor2Hover,
+ buttonColor2Pressed,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$k), {
+ closeBorderRadius: borderRadius,
+ heightTiny: heightMini,
+ heightSmall: heightTiny,
+ heightMedium: heightSmall,
+ heightLarge: heightMedium,
+ borderRadius,
+ opacityDisabled,
+ fontSizeTiny: fontSizeMini,
+ fontSizeSmall: fontSizeTiny,
+ fontSizeMedium: fontSizeSmall,
+ fontSizeLarge: fontSizeMedium,
+ fontWeightStrong,
+ // checked
+ textColorCheckable: textColor2,
+ textColorHoverCheckable: textColor2,
+ textColorPressedCheckable: textColor2,
+ textColorChecked: baseColor,
+ colorCheckable: "#0000",
+ colorHoverCheckable: buttonColor2Hover,
+ colorPressedCheckable: buttonColor2Pressed,
+ colorChecked: primaryColor,
+ colorCheckedHover: primaryColorHover,
+ colorCheckedPressed: primaryColorPressed,
+ // default
+ border: `1px solid ${borderColor}`,
+ textColor: textColor2,
+ color: tagColor,
+ colorBordered: "rgb(250, 250, 252)",
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ borderPrimary: `1px solid ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ textColorPrimary: primaryColor,
+ colorPrimary: changeColor(primaryColor, {
+ alpha: 0.12
+ }),
+ colorBorderedPrimary: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ closeIconColorPrimary: primaryColor,
+ closeIconColorHoverPrimary: primaryColor,
+ closeIconColorPressedPrimary: primaryColor,
+ closeColorHoverPrimary: changeColor(primaryColor, {
+ alpha: 0.12
+ }),
+ closeColorPressedPrimary: changeColor(primaryColor, {
+ alpha: 0.18
+ }),
+ borderInfo: `1px solid ${changeColor(infoColor, {
+ alpha: 0.3
+ })}`,
+ textColorInfo: infoColor,
+ colorInfo: changeColor(infoColor, {
+ alpha: 0.12
+ }),
+ colorBorderedInfo: changeColor(infoColor, {
+ alpha: 0.1
+ }),
+ closeIconColorInfo: infoColor,
+ closeIconColorHoverInfo: infoColor,
+ closeIconColorPressedInfo: infoColor,
+ closeColorHoverInfo: changeColor(infoColor, {
+ alpha: 0.12
+ }),
+ closeColorPressedInfo: changeColor(infoColor, {
+ alpha: 0.18
+ }),
+ borderSuccess: `1px solid ${changeColor(successColor, {
+ alpha: 0.3
+ })}`,
+ textColorSuccess: successColor,
+ colorSuccess: changeColor(successColor, {
+ alpha: 0.12
+ }),
+ colorBorderedSuccess: changeColor(successColor, {
+ alpha: 0.1
+ }),
+ closeIconColorSuccess: successColor,
+ closeIconColorHoverSuccess: successColor,
+ closeIconColorPressedSuccess: successColor,
+ closeColorHoverSuccess: changeColor(successColor, {
+ alpha: 0.12
+ }),
+ closeColorPressedSuccess: changeColor(successColor, {
+ alpha: 0.18
+ }),
+ borderWarning: `1px solid ${changeColor(warningColor, {
+ alpha: 0.35
+ })}`,
+ textColorWarning: warningColor,
+ colorWarning: changeColor(warningColor, {
+ alpha: 0.15
+ }),
+ colorBorderedWarning: changeColor(warningColor, {
+ alpha: 0.12
+ }),
+ closeIconColorWarning: warningColor,
+ closeIconColorHoverWarning: warningColor,
+ closeIconColorPressedWarning: warningColor,
+ closeColorHoverWarning: changeColor(warningColor, {
+ alpha: 0.12
+ }),
+ closeColorPressedWarning: changeColor(warningColor, {
+ alpha: 0.18
+ }),
+ borderError: `1px solid ${changeColor(errorColor, {
+ alpha: 0.23
+ })}`,
+ textColorError: errorColor,
+ colorError: changeColor(errorColor, {
+ alpha: 0.1
+ }),
+ colorBorderedError: changeColor(errorColor, {
+ alpha: 0.08
+ }),
+ closeIconColorError: errorColor,
+ closeIconColorHoverError: errorColor,
+ closeIconColorPressedError: errorColor,
+ closeColorHoverError: changeColor(errorColor, {
+ alpha: 0.12
+ }),
+ closeColorPressedError: changeColor(errorColor, {
+ alpha: 0.18
+ })
+ });
+}
+const tagLight = {
+ name: "Tag",
+ common: derived,
+ self: self$1f
+};
+const commonVariables$j = {
+ paddingSingle: "0 26px 0 12px",
+ paddingMultiple: "3px 26px 0 12px",
+ clearSize: "16px",
+ arrowSize: "16px"
+};
+const internalSelectionDark = {
+ name: "InternalSelection",
+ common: derived$1,
+ peers: {
+ Popover: popoverDark
+ },
+ self(vars) {
+ const {
+ borderRadius,
+ textColor2,
+ textColorDisabled,
+ inputColor,
+ inputColorDisabled,
+ primaryColor,
+ primaryColorHover,
+ warningColor,
+ warningColorHover,
+ errorColor,
+ errorColorHover,
+ iconColor,
+ iconColorDisabled,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ placeholderColor,
+ placeholderColorDisabled,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontWeight
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$j), {
+ fontWeight,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadius,
+ // default
+ textColor: textColor2,
+ textColorDisabled,
+ placeholderColor,
+ placeholderColorDisabled,
+ color: inputColor,
+ colorDisabled: inputColorDisabled,
+ colorActive: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ border: "1px solid #0000",
+ borderHover: `1px solid ${primaryColorHover}`,
+ borderActive: `1px solid ${primaryColor}`,
+ borderFocus: `1px solid ${primaryColorHover}`,
+ boxShadowHover: "none",
+ boxShadowActive: `0 0 8px 0 ${changeColor(primaryColor, {
+ alpha: 0.4
+ })}`,
+ boxShadowFocus: `0 0 8px 0 ${changeColor(primaryColor, {
+ alpha: 0.4
+ })}`,
+ caretColor: primaryColor,
+ arrowColor: iconColor,
+ arrowColorDisabled: iconColorDisabled,
+ loadingColor: primaryColor,
+ // warning
+ borderWarning: `1px solid ${warningColor}`,
+ borderHoverWarning: `1px solid ${warningColorHover}`,
+ borderActiveWarning: `1px solid ${warningColor}`,
+ borderFocusWarning: `1px solid ${warningColorHover}`,
+ boxShadowHoverWarning: "none",
+ boxShadowActiveWarning: `0 0 8px 0 ${changeColor(warningColor, {
+ alpha: 0.4
+ })}`,
+ boxShadowFocusWarning: `0 0 8px 0 ${changeColor(warningColor, {
+ alpha: 0.4
+ })}`,
+ colorActiveWarning: changeColor(warningColor, {
+ alpha: 0.1
+ }),
+ caretColorWarning: warningColor,
+ // error
+ borderError: `1px solid ${errorColor}`,
+ borderHoverError: `1px solid ${errorColorHover}`,
+ borderActiveError: `1px solid ${errorColor}`,
+ borderFocusError: `1px solid ${errorColorHover}`,
+ boxShadowHoverError: "none",
+ boxShadowActiveError: `0 0 8px 0 ${changeColor(errorColor, {
+ alpha: 0.4
+ })}`,
+ boxShadowFocusError: `0 0 8px 0 ${changeColor(errorColor, {
+ alpha: 0.4
+ })}`,
+ colorActiveError: changeColor(errorColor, {
+ alpha: 0.1
+ }),
+ caretColorError: errorColor,
+ clearColor,
+ clearColorHover,
+ clearColorPressed
+ });
+ }
+};
+function self$1e(vars) {
+ const {
+ borderRadius,
+ textColor2,
+ textColorDisabled,
+ inputColor,
+ inputColorDisabled,
+ primaryColor,
+ primaryColorHover,
+ warningColor,
+ warningColorHover,
+ errorColor,
+ errorColorHover,
+ borderColor,
+ iconColor,
+ iconColorDisabled,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ placeholderColor,
+ placeholderColorDisabled,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontWeight
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$j), {
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadius,
+ fontWeight,
+ // default
+ textColor: textColor2,
+ textColorDisabled,
+ placeholderColor,
+ placeholderColorDisabled,
+ color: inputColor,
+ colorDisabled: inputColorDisabled,
+ colorActive: inputColor,
+ border: `1px solid ${borderColor}`,
+ borderHover: `1px solid ${primaryColorHover}`,
+ borderActive: `1px solid ${primaryColor}`,
+ borderFocus: `1px solid ${primaryColorHover}`,
+ boxShadowHover: "none",
+ boxShadowActive: `0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.2
+ })}`,
+ boxShadowFocus: `0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.2
+ })}`,
+ caretColor: primaryColor,
+ arrowColor: iconColor,
+ arrowColorDisabled: iconColorDisabled,
+ loadingColor: primaryColor,
+ // warning
+ borderWarning: `1px solid ${warningColor}`,
+ borderHoverWarning: `1px solid ${warningColorHover}`,
+ borderActiveWarning: `1px solid ${warningColor}`,
+ borderFocusWarning: `1px solid ${warningColorHover}`,
+ boxShadowHoverWarning: "none",
+ boxShadowActiveWarning: `0 0 0 2px ${changeColor(warningColor, {
+ alpha: 0.2
+ })}`,
+ boxShadowFocusWarning: `0 0 0 2px ${changeColor(warningColor, {
+ alpha: 0.2
+ })}`,
+ colorActiveWarning: inputColor,
+ caretColorWarning: warningColor,
+ // error
+ borderError: `1px solid ${errorColor}`,
+ borderHoverError: `1px solid ${errorColorHover}`,
+ borderActiveError: `1px solid ${errorColor}`,
+ borderFocusError: `1px solid ${errorColorHover}`,
+ boxShadowHoverError: "none",
+ boxShadowActiveError: `0 0 0 2px ${changeColor(errorColor, {
+ alpha: 0.2
+ })}`,
+ boxShadowFocusError: `0 0 0 2px ${changeColor(errorColor, {
+ alpha: 0.2
+ })}`,
+ colorActiveError: inputColor,
+ caretColorError: errorColor,
+ clearColor,
+ clearColorHover,
+ clearColorPressed
+ });
+}
+const internalSelectionLight = createTheme({
+ name: "InternalSelection",
+ common: derived,
+ peers: {
+ Popover: popoverLight
+ },
+ self: self$1e
+});
+const {
+ cubicBezierEaseInOut: cubicBezierEaseInOut$1
+} = commonVariables$n;
+function fadeInWidthExpandTransition({
+ duration: duration2 = ".2s",
+ delay = ".1s"
+} = {}) {
+ return [c("&.fade-in-width-expand-transition-leave-from, &.fade-in-width-expand-transition-enter-to", {
+ opacity: 1
+ }), c("&.fade-in-width-expand-transition-leave-to, &.fade-in-width-expand-transition-enter-from", `
+ opacity: 0!important;
+ margin-left: 0!important;
+ margin-right: 0!important;
+ `), c("&.fade-in-width-expand-transition-leave-active", `
+ overflow: hidden;
+ transition:
+ opacity ${duration2} ${cubicBezierEaseInOut$1},
+ max-width ${duration2} ${cubicBezierEaseInOut$1} ${delay},
+ margin-left ${duration2} ${cubicBezierEaseInOut$1} ${delay},
+ margin-right ${duration2} ${cubicBezierEaseInOut$1} ${delay};
+ `), c("&.fade-in-width-expand-transition-enter-active", `
+ overflow: hidden;
+ transition:
+ opacity ${duration2} ${cubicBezierEaseInOut$1} ${delay},
+ max-width ${duration2} ${cubicBezierEaseInOut$1},
+ margin-left ${duration2} ${cubicBezierEaseInOut$1},
+ margin-right ${duration2} ${cubicBezierEaseInOut$1};
+ `)];
+}
+const style$7 = cB("base-wave", `
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ border-radius: inherit;
+`);
+const NBaseWave = /* @__PURE__ */ defineComponent({
+ name: "BaseWave",
+ props: {
+ clsPrefix: {
+ type: String,
+ required: true
+ }
+ },
+ setup(props) {
+ useStyle("-base-wave", style$7, toRef(props, "clsPrefix"));
+ const selfRef = ref(null);
+ const activeRef = ref(false);
+ let animationTimerId = null;
+ onBeforeUnmount(() => {
+ if (animationTimerId !== null) {
+ window.clearTimeout(animationTimerId);
+ }
+ });
+ return {
+ active: activeRef,
+ selfRef,
+ play() {
+ if (animationTimerId !== null) {
+ window.clearTimeout(animationTimerId);
+ activeRef.value = false;
+ animationTimerId = null;
+ }
+ void nextTick(() => {
+ var _a;
+ void ((_a = selfRef.value) === null || _a === void 0 ? void 0 : _a.offsetHeight);
+ activeRef.value = true;
+ animationTimerId = window.setTimeout(() => {
+ activeRef.value = false;
+ animationTimerId = null;
+ }, 1e3);
+ });
+ }
+ };
+ },
+ render() {
+ const {
+ clsPrefix
+ } = this;
+ return h("div", {
+ ref: "selfRef",
+ "aria-hidden": true,
+ class: [`${clsPrefix}-base-wave`, this.active && `${clsPrefix}-base-wave--active`]
+ });
+ }
+});
+const commonVars$b = {
+ iconMargin: "11px 8px 0 12px",
+ iconMarginRtl: "11px 12px 0 8px",
+ iconSize: "24px",
+ closeIconSize: "16px",
+ closeSize: "20px",
+ closeMargin: "13px 14px 0 0",
+ closeMarginRtl: "13px 0 0 14px",
+ padding: "13px"
+};
+const alertDark = {
+ name: "Alert",
+ common: derived$1,
+ self(vars) {
+ const {
+ lineHeight: lineHeight2,
+ borderRadius,
+ fontWeightStrong,
+ dividerColor,
+ inputColor,
+ textColor1,
+ textColor2,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ infoColorSuppl,
+ successColorSuppl,
+ warningColorSuppl,
+ errorColorSuppl,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$b), {
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ titleFontWeight: fontWeightStrong,
+ borderRadius,
+ border: `1px solid ${dividerColor}`,
+ color: inputColor,
+ titleTextColor: textColor1,
+ iconColor: textColor2,
+ contentTextColor: textColor2,
+ closeBorderRadius: borderRadius,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ borderInfo: `1px solid ${changeColor(infoColorSuppl, {
+ alpha: 0.35
+ })}`,
+ colorInfo: changeColor(infoColorSuppl, {
+ alpha: 0.25
+ }),
+ titleTextColorInfo: textColor1,
+ iconColorInfo: infoColorSuppl,
+ contentTextColorInfo: textColor2,
+ closeColorHoverInfo: closeColorHover,
+ closeColorPressedInfo: closeColorPressed,
+ closeIconColorInfo: closeIconColor,
+ closeIconColorHoverInfo: closeIconColorHover,
+ closeIconColorPressedInfo: closeIconColorPressed,
+ borderSuccess: `1px solid ${changeColor(successColorSuppl, {
+ alpha: 0.35
+ })}`,
+ colorSuccess: changeColor(successColorSuppl, {
+ alpha: 0.25
+ }),
+ titleTextColorSuccess: textColor1,
+ iconColorSuccess: successColorSuppl,
+ contentTextColorSuccess: textColor2,
+ closeColorHoverSuccess: closeColorHover,
+ closeColorPressedSuccess: closeColorPressed,
+ closeIconColorSuccess: closeIconColor,
+ closeIconColorHoverSuccess: closeIconColorHover,
+ closeIconColorPressedSuccess: closeIconColorPressed,
+ borderWarning: `1px solid ${changeColor(warningColorSuppl, {
+ alpha: 0.35
+ })}`,
+ colorWarning: changeColor(warningColorSuppl, {
+ alpha: 0.25
+ }),
+ titleTextColorWarning: textColor1,
+ iconColorWarning: warningColorSuppl,
+ contentTextColorWarning: textColor2,
+ closeColorHoverWarning: closeColorHover,
+ closeColorPressedWarning: closeColorPressed,
+ closeIconColorWarning: closeIconColor,
+ closeIconColorHoverWarning: closeIconColorHover,
+ closeIconColorPressedWarning: closeIconColorPressed,
+ borderError: `1px solid ${changeColor(errorColorSuppl, {
+ alpha: 0.35
+ })}`,
+ colorError: changeColor(errorColorSuppl, {
+ alpha: 0.25
+ }),
+ titleTextColorError: textColor1,
+ iconColorError: errorColorSuppl,
+ contentTextColorError: textColor2,
+ closeColorHoverError: closeColorHover,
+ closeColorPressedError: closeColorPressed,
+ closeIconColorError: closeIconColor,
+ closeIconColorHoverError: closeIconColorHover,
+ closeIconColorPressedError: closeIconColorPressed
+ });
+ }
+};
+function self$1d(vars) {
+ const {
+ lineHeight: lineHeight2,
+ borderRadius,
+ fontWeightStrong,
+ baseColor,
+ dividerColor,
+ actionColor,
+ textColor1,
+ textColor2,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ infoColor,
+ successColor,
+ warningColor,
+ errorColor,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$b), {
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ titleFontWeight: fontWeightStrong,
+ borderRadius,
+ border: `1px solid ${dividerColor}`,
+ color: actionColor,
+ titleTextColor: textColor1,
+ iconColor: textColor2,
+ contentTextColor: textColor2,
+ closeBorderRadius: borderRadius,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ borderInfo: `1px solid ${composite(baseColor, changeColor(infoColor, {
+ alpha: 0.25
+ }))}`,
+ colorInfo: composite(baseColor, changeColor(infoColor, {
+ alpha: 0.08
+ })),
+ titleTextColorInfo: textColor1,
+ iconColorInfo: infoColor,
+ contentTextColorInfo: textColor2,
+ closeColorHoverInfo: closeColorHover,
+ closeColorPressedInfo: closeColorPressed,
+ closeIconColorInfo: closeIconColor,
+ closeIconColorHoverInfo: closeIconColorHover,
+ closeIconColorPressedInfo: closeIconColorPressed,
+ borderSuccess: `1px solid ${composite(baseColor, changeColor(successColor, {
+ alpha: 0.25
+ }))}`,
+ colorSuccess: composite(baseColor, changeColor(successColor, {
+ alpha: 0.08
+ })),
+ titleTextColorSuccess: textColor1,
+ iconColorSuccess: successColor,
+ contentTextColorSuccess: textColor2,
+ closeColorHoverSuccess: closeColorHover,
+ closeColorPressedSuccess: closeColorPressed,
+ closeIconColorSuccess: closeIconColor,
+ closeIconColorHoverSuccess: closeIconColorHover,
+ closeIconColorPressedSuccess: closeIconColorPressed,
+ borderWarning: `1px solid ${composite(baseColor, changeColor(warningColor, {
+ alpha: 0.33
+ }))}`,
+ colorWarning: composite(baseColor, changeColor(warningColor, {
+ alpha: 0.08
+ })),
+ titleTextColorWarning: textColor1,
+ iconColorWarning: warningColor,
+ contentTextColorWarning: textColor2,
+ closeColorHoverWarning: closeColorHover,
+ closeColorPressedWarning: closeColorPressed,
+ closeIconColorWarning: closeIconColor,
+ closeIconColorHoverWarning: closeIconColorHover,
+ closeIconColorPressedWarning: closeIconColorPressed,
+ borderError: `1px solid ${composite(baseColor, changeColor(errorColor, {
+ alpha: 0.25
+ }))}`,
+ colorError: composite(baseColor, changeColor(errorColor, {
+ alpha: 0.08
+ })),
+ titleTextColorError: textColor1,
+ iconColorError: errorColor,
+ contentTextColorError: textColor2,
+ closeColorHoverError: closeColorHover,
+ closeColorPressedError: closeColorPressed,
+ closeIconColorError: closeIconColor,
+ closeIconColorHoverError: closeIconColorHover,
+ closeIconColorPressedError: closeIconColorPressed
+ });
+}
+const alertLight = {
+ name: "Alert",
+ common: derived,
+ self: self$1d
+};
+const {
+ cubicBezierEaseInOut,
+ cubicBezierEaseOut,
+ cubicBezierEaseIn
+} = commonVariables$n;
+function fadeInHeightExpandTransition({
+ overflow = "hidden",
+ duration: duration2 = ".3s",
+ originalTransition = "",
+ leavingDelay = "0s",
+ foldPadding = false,
+ enterToProps = void 0,
+ leaveToProps = void 0,
+ reverse = false
+} = {}) {
+ const enterClass = reverse ? "leave" : "enter";
+ const leaveClass = reverse ? "enter" : "leave";
+ return [c(`&.fade-in-height-expand-transition-${leaveClass}-from,
+ &.fade-in-height-expand-transition-${enterClass}-to`, Object.assign(Object.assign({}, enterToProps), {
+ opacity: 1
+ })), c(`&.fade-in-height-expand-transition-${leaveClass}-to,
+ &.fade-in-height-expand-transition-${enterClass}-from`, Object.assign(Object.assign({}, leaveToProps), {
+ opacity: 0,
+ marginTop: "0 !important",
+ marginBottom: "0 !important",
+ paddingTop: foldPadding ? "0 !important" : void 0,
+ paddingBottom: foldPadding ? "0 !important" : void 0
+ })), c(`&.fade-in-height-expand-transition-${leaveClass}-active`, `
+ overflow: ${overflow};
+ transition:
+ max-height ${duration2} ${cubicBezierEaseInOut} ${leavingDelay},
+ opacity ${duration2} ${cubicBezierEaseOut} ${leavingDelay},
+ margin-top ${duration2} ${cubicBezierEaseInOut} ${leavingDelay},
+ margin-bottom ${duration2} ${cubicBezierEaseInOut} ${leavingDelay},
+ padding-top ${duration2} ${cubicBezierEaseInOut} ${leavingDelay},
+ padding-bottom ${duration2} ${cubicBezierEaseInOut} ${leavingDelay}
+ ${originalTransition ? `,${originalTransition}` : ""}
+ `), c(`&.fade-in-height-expand-transition-${enterClass}-active`, `
+ overflow: ${overflow};
+ transition:
+ max-height ${duration2} ${cubicBezierEaseInOut},
+ opacity ${duration2} ${cubicBezierEaseIn},
+ margin-top ${duration2} ${cubicBezierEaseInOut},
+ margin-bottom ${duration2} ${cubicBezierEaseInOut},
+ padding-top ${duration2} ${cubicBezierEaseInOut},
+ padding-bottom ${duration2} ${cubicBezierEaseInOut}
+ ${originalTransition ? `,${originalTransition}` : ""}
+ `)];
+}
+const commonVars$a = {
+ linkFontSize: "13px",
+ linkPadding: "0 0 0 16px",
+ railWidth: "4px"
+};
+function self$1c(vars) {
+ const {
+ borderRadius,
+ railColor,
+ primaryColor,
+ primaryColorHover,
+ primaryColorPressed,
+ textColor2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$a), {
+ borderRadius,
+ railColor,
+ railColorActive: primaryColor,
+ linkColor: changeColor(primaryColor, {
+ alpha: 0.15
+ }),
+ linkTextColor: textColor2,
+ linkTextColorHover: primaryColorHover,
+ linkTextColorPressed: primaryColorPressed,
+ linkTextColorActive: primaryColor
+ });
+}
+const anchorLight = {
+ name: "Anchor",
+ common: derived,
+ self: self$1c
+};
+const anchorDark = {
+ name: "Anchor",
+ common: derived$1,
+ self: self$1c
+};
+const isChrome = isBrowser$1 && "chrome" in window;
+isBrowser$1 && navigator.userAgent.includes("Firefox");
+const isSafari = isBrowser$1 && navigator.userAgent.includes("Safari") && !isChrome;
+const commonVariables$i = {
+ paddingTiny: "0 8px",
+ paddingSmall: "0 10px",
+ paddingMedium: "0 12px",
+ paddingLarge: "0 14px",
+ clearSize: "16px"
+};
+const inputDark = {
+ name: "Input",
+ common: derived$1,
+ self(vars) {
+ const {
+ textColor2,
+ textColor3,
+ textColorDisabled,
+ primaryColor,
+ primaryColorHover,
+ inputColor,
+ inputColorDisabled,
+ warningColor,
+ warningColorHover,
+ errorColor,
+ errorColorHover,
+ borderRadius,
+ lineHeight: lineHeight2,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ placeholderColor,
+ placeholderColorDisabled,
+ iconColor,
+ iconColorDisabled,
+ iconColorHover,
+ iconColorPressed,
+ fontWeight
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$i), {
+ fontWeight,
+ countTextColorDisabled: textColorDisabled,
+ countTextColor: textColor3,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ lineHeight: lineHeight2,
+ lineHeightTextarea: lineHeight2,
+ borderRadius,
+ iconSize: "16px",
+ groupLabelColor: inputColor,
+ textColor: textColor2,
+ textColorDisabled,
+ textDecorationColor: textColor2,
+ groupLabelTextColor: textColor2,
+ caretColor: primaryColor,
+ placeholderColor,
+ placeholderColorDisabled,
+ color: inputColor,
+ colorDisabled: inputColorDisabled,
+ colorFocus: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ groupLabelBorder: "1px solid #0000",
+ border: "1px solid #0000",
+ borderHover: `1px solid ${primaryColorHover}`,
+ borderDisabled: "1px solid #0000",
+ borderFocus: `1px solid ${primaryColorHover}`,
+ boxShadowFocus: `0 0 8px 0 ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ loadingColor: primaryColor,
+ // warning
+ loadingColorWarning: warningColor,
+ borderWarning: `1px solid ${warningColor}`,
+ borderHoverWarning: `1px solid ${warningColorHover}`,
+ colorFocusWarning: changeColor(warningColor, {
+ alpha: 0.1
+ }),
+ borderFocusWarning: `1px solid ${warningColorHover}`,
+ boxShadowFocusWarning: `0 0 8px 0 ${changeColor(warningColor, {
+ alpha: 0.3
+ })}`,
+ caretColorWarning: warningColor,
+ // error
+ loadingColorError: errorColor,
+ borderError: `1px solid ${errorColor}`,
+ borderHoverError: `1px solid ${errorColorHover}`,
+ colorFocusError: changeColor(errorColor, {
+ alpha: 0.1
+ }),
+ borderFocusError: `1px solid ${errorColorHover}`,
+ boxShadowFocusError: `0 0 8px 0 ${changeColor(errorColor, {
+ alpha: 0.3
+ })}`,
+ caretColorError: errorColor,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ iconColor,
+ iconColorDisabled,
+ iconColorHover,
+ iconColorPressed,
+ suffixTextColor: textColor2
+ });
+ }
+};
+function self$1b(vars) {
+ const {
+ textColor2,
+ textColor3,
+ textColorDisabled,
+ primaryColor,
+ primaryColorHover,
+ inputColor,
+ inputColorDisabled,
+ borderColor,
+ warningColor,
+ warningColorHover,
+ errorColor,
+ errorColorHover,
+ borderRadius,
+ lineHeight: lineHeight2,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ actionColor,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ placeholderColor,
+ placeholderColorDisabled,
+ iconColor,
+ iconColorDisabled,
+ iconColorHover,
+ iconColorPressed,
+ fontWeight
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$i), {
+ fontWeight,
+ countTextColorDisabled: textColorDisabled,
+ countTextColor: textColor3,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ lineHeight: lineHeight2,
+ lineHeightTextarea: lineHeight2,
+ borderRadius,
+ iconSize: "16px",
+ groupLabelColor: actionColor,
+ groupLabelTextColor: textColor2,
+ textColor: textColor2,
+ textColorDisabled,
+ textDecorationColor: textColor2,
+ caretColor: primaryColor,
+ placeholderColor,
+ placeholderColorDisabled,
+ color: inputColor,
+ colorDisabled: inputColorDisabled,
+ colorFocus: inputColor,
+ groupLabelBorder: `1px solid ${borderColor}`,
+ border: `1px solid ${borderColor}`,
+ borderHover: `1px solid ${primaryColorHover}`,
+ borderDisabled: `1px solid ${borderColor}`,
+ borderFocus: `1px solid ${primaryColorHover}`,
+ boxShadowFocus: `0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.2
+ })}`,
+ loadingColor: primaryColor,
+ // warning
+ loadingColorWarning: warningColor,
+ borderWarning: `1px solid ${warningColor}`,
+ borderHoverWarning: `1px solid ${warningColorHover}`,
+ colorFocusWarning: inputColor,
+ borderFocusWarning: `1px solid ${warningColorHover}`,
+ boxShadowFocusWarning: `0 0 0 2px ${changeColor(warningColor, {
+ alpha: 0.2
+ })}`,
+ caretColorWarning: warningColor,
+ // error
+ loadingColorError: errorColor,
+ borderError: `1px solid ${errorColor}`,
+ borderHoverError: `1px solid ${errorColorHover}`,
+ colorFocusError: inputColor,
+ borderFocusError: `1px solid ${errorColorHover}`,
+ boxShadowFocusError: `0 0 0 2px ${changeColor(errorColor, {
+ alpha: 0.2
+ })}`,
+ caretColorError: errorColor,
+ clearColor,
+ clearColorHover,
+ clearColorPressed,
+ iconColor,
+ iconColorDisabled,
+ iconColorHover,
+ iconColorPressed,
+ suffixTextColor: textColor2
+ });
+}
+const inputLight = {
+ name: "Input",
+ common: derived,
+ self: self$1b
+};
+function self$1a(vars) {
+ const {
+ boxShadow2
+ } = vars;
+ return {
+ menuBoxShadow: boxShadow2
+ };
+}
+const autoCompleteLight = createTheme({
+ name: "AutoComplete",
+ common: derived,
+ peers: {
+ InternalSelectMenu: internalSelectMenuLight,
+ Input: inputLight
+ },
+ self: self$1a
+});
+const autoCompleteDark = {
+ name: "AutoComplete",
+ common: derived$1,
+ peers: {
+ InternalSelectMenu: internalSelectMenuDark,
+ Input: inputDark
+ },
+ self: self$1a
+};
+function self$19(vars) {
+ const {
+ borderRadius,
+ avatarColor,
+ cardColor,
+ fontSize: fontSize2,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ heightHuge,
+ modalColor,
+ popoverColor
+ } = vars;
+ return {
+ borderRadius,
+ fontSize: fontSize2,
+ border: `2px solid ${cardColor}`,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ heightHuge,
+ color: composite(cardColor, avatarColor),
+ colorModal: composite(modalColor, avatarColor),
+ colorPopover: composite(popoverColor, avatarColor)
+ };
+}
+const avatarLight = {
+ name: "Avatar",
+ common: derived,
+ self: self$19
+};
+const avatarDark = {
+ name: "Avatar",
+ common: derived$1,
+ self: self$19
+};
+function self$18() {
+ return {
+ gap: "-12px"
+ };
+}
+const avatarGroupLight = createTheme({
+ name: "AvatarGroup",
+ common: derived,
+ peers: {
+ Avatar: avatarLight
+ },
+ self: self$18
+});
+const avatarGroupDark = {
+ name: "AvatarGroup",
+ common: derived$1,
+ peers: {
+ Avatar: avatarDark
+ },
+ self: self$18
+};
+const commonVariables$h = {
+ width: "44px",
+ height: "44px",
+ borderRadius: "22px",
+ iconSize: "26px"
+};
+const backTopDark = {
+ name: "BackTop",
+ common: derived$1,
+ self(vars) {
+ const {
+ popoverColor,
+ textColor2,
+ primaryColorHover,
+ primaryColorPressed
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$h), {
+ color: popoverColor,
+ textColor: textColor2,
+ iconColor: textColor2,
+ iconColorHover: primaryColorHover,
+ iconColorPressed: primaryColorPressed,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .12)",
+ boxShadowHover: "0 2px 12px 0px rgba(0, 0, 0, .18)",
+ boxShadowPressed: "0 2px 12px 0px rgba(0, 0, 0, .18)"
+ });
+ }
+};
+function self$17(vars) {
+ const {
+ popoverColor,
+ textColor2,
+ primaryColorHover,
+ primaryColorPressed
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$h), {
+ color: popoverColor,
+ textColor: textColor2,
+ iconColor: textColor2,
+ iconColorHover: primaryColorHover,
+ iconColorPressed: primaryColorPressed,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .12)",
+ boxShadowHover: "0 2px 12px 0px rgba(0, 0, 0, .18)",
+ boxShadowPressed: "0 2px 12px 0px rgba(0, 0, 0, .18)"
+ });
+}
+const backTopLight = {
+ name: "BackTop",
+ common: derived,
+ self: self$17
+};
+const badgeDark = {
+ name: "Badge",
+ common: derived$1,
+ self(vars) {
+ const {
+ errorColorSuppl,
+ infoColorSuppl,
+ successColorSuppl,
+ warningColorSuppl,
+ fontFamily: fontFamily2
+ } = vars;
+ return {
+ color: errorColorSuppl,
+ colorInfo: infoColorSuppl,
+ colorSuccess: successColorSuppl,
+ colorError: errorColorSuppl,
+ colorWarning: warningColorSuppl,
+ fontSize: "12px",
+ fontFamily: fontFamily2
+ };
+ }
+};
+function self$16(vars) {
+ const {
+ errorColor,
+ infoColor,
+ successColor,
+ warningColor,
+ fontFamily: fontFamily2
+ } = vars;
+ return {
+ color: errorColor,
+ colorInfo: infoColor,
+ colorSuccess: successColor,
+ colorError: errorColor,
+ colorWarning: warningColor,
+ fontSize: "12px",
+ fontFamily: fontFamily2
+ };
+}
+const badgeLight = {
+ name: "Badge",
+ common: derived,
+ self: self$16
+};
+const commonVariables$g = {
+ fontWeightActive: "400"
+};
+function self$15(vars) {
+ const {
+ fontSize: fontSize2,
+ textColor3,
+ textColor2,
+ borderRadius,
+ buttonColor2Hover,
+ buttonColor2Pressed
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$g), {
+ fontSize: fontSize2,
+ itemLineHeight: "1.25",
+ itemTextColor: textColor3,
+ itemTextColorHover: textColor2,
+ itemTextColorPressed: textColor2,
+ itemTextColorActive: textColor2,
+ itemBorderRadius: borderRadius,
+ itemColorHover: buttonColor2Hover,
+ itemColorPressed: buttonColor2Pressed,
+ separatorColor: textColor3
+ });
+}
+const breadcrumbLight = {
+ name: "Breadcrumb",
+ common: derived,
+ self: self$15
+};
+const breadcrumbDark = {
+ name: "Breadcrumb",
+ common: derived$1,
+ self: self$15
+};
+function createHoverColor(rgb) {
+ return composite(rgb, [255, 255, 255, 0.16]);
+}
+function createPressedColor(rgb) {
+ return composite(rgb, [0, 0, 0, 0.12]);
+}
+const buttonGroupInjectionKey = createInjectionKey("n-button-group");
+const commonVariables$f = {
+ paddingTiny: "0 6px",
+ paddingSmall: "0 10px",
+ paddingMedium: "0 14px",
+ paddingLarge: "0 18px",
+ paddingRoundTiny: "0 10px",
+ paddingRoundSmall: "0 14px",
+ paddingRoundMedium: "0 18px",
+ paddingRoundLarge: "0 22px",
+ iconMarginTiny: "6px",
+ iconMarginSmall: "6px",
+ iconMarginMedium: "6px",
+ iconMarginLarge: "6px",
+ iconSizeTiny: "14px",
+ iconSizeSmall: "18px",
+ iconSizeMedium: "18px",
+ iconSizeLarge: "20px",
+ rippleDuration: ".6s"
+};
+function self$14(vars) {
+ const {
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadius,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ opacityDisabled,
+ textColor2,
+ textColor3,
+ primaryColorHover,
+ primaryColorPressed,
+ borderColor,
+ primaryColor,
+ baseColor,
+ infoColor,
+ infoColorHover,
+ infoColorPressed,
+ successColor,
+ successColorHover,
+ successColorPressed,
+ warningColor,
+ warningColorHover,
+ warningColorPressed,
+ errorColor,
+ errorColorHover,
+ errorColorPressed,
+ fontWeight,
+ buttonColor2,
+ buttonColor2Hover,
+ buttonColor2Pressed,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$f), {
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadiusTiny: borderRadius,
+ borderRadiusSmall: borderRadius,
+ borderRadiusMedium: borderRadius,
+ borderRadiusLarge: borderRadius,
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ opacityDisabled,
+ // secondary
+ colorOpacitySecondary: "0.16",
+ colorOpacitySecondaryHover: "0.22",
+ colorOpacitySecondaryPressed: "0.28",
+ colorSecondary: buttonColor2,
+ colorSecondaryHover: buttonColor2Hover,
+ colorSecondaryPressed: buttonColor2Pressed,
+ // tertiary
+ colorTertiary: buttonColor2,
+ colorTertiaryHover: buttonColor2Hover,
+ colorTertiaryPressed: buttonColor2Pressed,
+ // quaternary
+ colorQuaternary: "#0000",
+ colorQuaternaryHover: buttonColor2Hover,
+ colorQuaternaryPressed: buttonColor2Pressed,
+ // default type
+ color: "#0000",
+ colorHover: "#0000",
+ colorPressed: "#0000",
+ colorFocus: "#0000",
+ colorDisabled: "#0000",
+ textColor: textColor2,
+ textColorTertiary: textColor3,
+ textColorHover: primaryColorHover,
+ textColorPressed: primaryColorPressed,
+ textColorFocus: primaryColorHover,
+ textColorDisabled: textColor2,
+ textColorText: textColor2,
+ textColorTextHover: primaryColorHover,
+ textColorTextPressed: primaryColorPressed,
+ textColorTextFocus: primaryColorHover,
+ textColorTextDisabled: textColor2,
+ textColorGhost: textColor2,
+ textColorGhostHover: primaryColorHover,
+ textColorGhostPressed: primaryColorPressed,
+ textColorGhostFocus: primaryColorHover,
+ textColorGhostDisabled: textColor2,
+ border: `1px solid ${borderColor}`,
+ borderHover: `1px solid ${primaryColorHover}`,
+ borderPressed: `1px solid ${primaryColorPressed}`,
+ borderFocus: `1px solid ${primaryColorHover}`,
+ borderDisabled: `1px solid ${borderColor}`,
+ rippleColor: primaryColor,
+ // primary
+ colorPrimary: primaryColor,
+ colorHoverPrimary: primaryColorHover,
+ colorPressedPrimary: primaryColorPressed,
+ colorFocusPrimary: primaryColorHover,
+ colorDisabledPrimary: primaryColor,
+ textColorPrimary: baseColor,
+ textColorHoverPrimary: baseColor,
+ textColorPressedPrimary: baseColor,
+ textColorFocusPrimary: baseColor,
+ textColorDisabledPrimary: baseColor,
+ textColorTextPrimary: primaryColor,
+ textColorTextHoverPrimary: primaryColorHover,
+ textColorTextPressedPrimary: primaryColorPressed,
+ textColorTextFocusPrimary: primaryColorHover,
+ textColorTextDisabledPrimary: textColor2,
+ textColorGhostPrimary: primaryColor,
+ textColorGhostHoverPrimary: primaryColorHover,
+ textColorGhostPressedPrimary: primaryColorPressed,
+ textColorGhostFocusPrimary: primaryColorHover,
+ textColorGhostDisabledPrimary: primaryColor,
+ borderPrimary: `1px solid ${primaryColor}`,
+ borderHoverPrimary: `1px solid ${primaryColorHover}`,
+ borderPressedPrimary: `1px solid ${primaryColorPressed}`,
+ borderFocusPrimary: `1px solid ${primaryColorHover}`,
+ borderDisabledPrimary: `1px solid ${primaryColor}`,
+ rippleColorPrimary: primaryColor,
+ // info
+ colorInfo: infoColor,
+ colorHoverInfo: infoColorHover,
+ colorPressedInfo: infoColorPressed,
+ colorFocusInfo: infoColorHover,
+ colorDisabledInfo: infoColor,
+ textColorInfo: baseColor,
+ textColorHoverInfo: baseColor,
+ textColorPressedInfo: baseColor,
+ textColorFocusInfo: baseColor,
+ textColorDisabledInfo: baseColor,
+ textColorTextInfo: infoColor,
+ textColorTextHoverInfo: infoColorHover,
+ textColorTextPressedInfo: infoColorPressed,
+ textColorTextFocusInfo: infoColorHover,
+ textColorTextDisabledInfo: textColor2,
+ textColorGhostInfo: infoColor,
+ textColorGhostHoverInfo: infoColorHover,
+ textColorGhostPressedInfo: infoColorPressed,
+ textColorGhostFocusInfo: infoColorHover,
+ textColorGhostDisabledInfo: infoColor,
+ borderInfo: `1px solid ${infoColor}`,
+ borderHoverInfo: `1px solid ${infoColorHover}`,
+ borderPressedInfo: `1px solid ${infoColorPressed}`,
+ borderFocusInfo: `1px solid ${infoColorHover}`,
+ borderDisabledInfo: `1px solid ${infoColor}`,
+ rippleColorInfo: infoColor,
+ // success
+ colorSuccess: successColor,
+ colorHoverSuccess: successColorHover,
+ colorPressedSuccess: successColorPressed,
+ colorFocusSuccess: successColorHover,
+ colorDisabledSuccess: successColor,
+ textColorSuccess: baseColor,
+ textColorHoverSuccess: baseColor,
+ textColorPressedSuccess: baseColor,
+ textColorFocusSuccess: baseColor,
+ textColorDisabledSuccess: baseColor,
+ textColorTextSuccess: successColor,
+ textColorTextHoverSuccess: successColorHover,
+ textColorTextPressedSuccess: successColorPressed,
+ textColorTextFocusSuccess: successColorHover,
+ textColorTextDisabledSuccess: textColor2,
+ textColorGhostSuccess: successColor,
+ textColorGhostHoverSuccess: successColorHover,
+ textColorGhostPressedSuccess: successColorPressed,
+ textColorGhostFocusSuccess: successColorHover,
+ textColorGhostDisabledSuccess: successColor,
+ borderSuccess: `1px solid ${successColor}`,
+ borderHoverSuccess: `1px solid ${successColorHover}`,
+ borderPressedSuccess: `1px solid ${successColorPressed}`,
+ borderFocusSuccess: `1px solid ${successColorHover}`,
+ borderDisabledSuccess: `1px solid ${successColor}`,
+ rippleColorSuccess: successColor,
+ // warning
+ colorWarning: warningColor,
+ colorHoverWarning: warningColorHover,
+ colorPressedWarning: warningColorPressed,
+ colorFocusWarning: warningColorHover,
+ colorDisabledWarning: warningColor,
+ textColorWarning: baseColor,
+ textColorHoverWarning: baseColor,
+ textColorPressedWarning: baseColor,
+ textColorFocusWarning: baseColor,
+ textColorDisabledWarning: baseColor,
+ textColorTextWarning: warningColor,
+ textColorTextHoverWarning: warningColorHover,
+ textColorTextPressedWarning: warningColorPressed,
+ textColorTextFocusWarning: warningColorHover,
+ textColorTextDisabledWarning: textColor2,
+ textColorGhostWarning: warningColor,
+ textColorGhostHoverWarning: warningColorHover,
+ textColorGhostPressedWarning: warningColorPressed,
+ textColorGhostFocusWarning: warningColorHover,
+ textColorGhostDisabledWarning: warningColor,
+ borderWarning: `1px solid ${warningColor}`,
+ borderHoverWarning: `1px solid ${warningColorHover}`,
+ borderPressedWarning: `1px solid ${warningColorPressed}`,
+ borderFocusWarning: `1px solid ${warningColorHover}`,
+ borderDisabledWarning: `1px solid ${warningColor}`,
+ rippleColorWarning: warningColor,
+ // error
+ colorError: errorColor,
+ colorHoverError: errorColorHover,
+ colorPressedError: errorColorPressed,
+ colorFocusError: errorColorHover,
+ colorDisabledError: errorColor,
+ textColorError: baseColor,
+ textColorHoverError: baseColor,
+ textColorPressedError: baseColor,
+ textColorFocusError: baseColor,
+ textColorDisabledError: baseColor,
+ textColorTextError: errorColor,
+ textColorTextHoverError: errorColorHover,
+ textColorTextPressedError: errorColorPressed,
+ textColorTextFocusError: errorColorHover,
+ textColorTextDisabledError: textColor2,
+ textColorGhostError: errorColor,
+ textColorGhostHoverError: errorColorHover,
+ textColorGhostPressedError: errorColorPressed,
+ textColorGhostFocusError: errorColorHover,
+ textColorGhostDisabledError: errorColor,
+ borderError: `1px solid ${errorColor}`,
+ borderHoverError: `1px solid ${errorColorHover}`,
+ borderPressedError: `1px solid ${errorColorPressed}`,
+ borderFocusError: `1px solid ${errorColorHover}`,
+ borderDisabledError: `1px solid ${errorColor}`,
+ rippleColorError: errorColor,
+ waveOpacity: "0.6",
+ fontWeight,
+ fontWeightStrong
+ });
+}
+const buttonLight = {
+ name: "Button",
+ common: derived,
+ self: self$14
+};
+const buttonDark = {
+ name: "Button",
+ common: derived$1,
+ self(vars) {
+ const commonSelf = self$14(vars);
+ commonSelf.waveOpacity = "0.8";
+ commonSelf.colorOpacitySecondary = "0.16";
+ commonSelf.colorOpacitySecondaryHover = "0.2";
+ commonSelf.colorOpacitySecondaryPressed = "0.12";
+ return commonSelf;
+ }
+};
+const style$6 = c([cB("button", `
+ margin: 0;
+ font-weight: var(--n-font-weight);
+ line-height: 1;
+ font-family: inherit;
+ padding: var(--n-padding);
+ height: var(--n-height);
+ font-size: var(--n-font-size);
+ border-radius: var(--n-border-radius);
+ color: var(--n-text-color);
+ background-color: var(--n-color);
+ width: var(--n-width);
+ white-space: nowrap;
+ outline: none;
+ position: relative;
+ z-index: auto;
+ border: none;
+ display: inline-flex;
+ flex-wrap: nowrap;
+ flex-shrink: 0;
+ align-items: center;
+ justify-content: center;
+ user-select: none;
+ -webkit-user-select: none;
+ text-align: center;
+ cursor: pointer;
+ text-decoration: none;
+ transition:
+ color .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ opacity .3s var(--n-bezier),
+ border-color .3s var(--n-bezier);
+ `, [cM("color", [cE("border", {
+ borderColor: "var(--n-border-color)"
+}), cM("disabled", [cE("border", {
+ borderColor: "var(--n-border-color-disabled)"
+})]), cNotM("disabled", [c("&:focus", [cE("state-border", {
+ borderColor: "var(--n-border-color-focus)"
+})]), c("&:hover", [cE("state-border", {
+ borderColor: "var(--n-border-color-hover)"
+})]), c("&:active", [cE("state-border", {
+ borderColor: "var(--n-border-color-pressed)"
+})]), cM("pressed", [cE("state-border", {
+ borderColor: "var(--n-border-color-pressed)"
+})])])]), cM("disabled", {
+ backgroundColor: "var(--n-color-disabled)",
+ color: "var(--n-text-color-disabled)"
+}, [cE("border", {
+ border: "var(--n-border-disabled)"
+})]), cNotM("disabled", [c("&:focus", {
+ backgroundColor: "var(--n-color-focus)",
+ color: "var(--n-text-color-focus)"
+}, [cE("state-border", {
+ border: "var(--n-border-focus)"
+})]), c("&:hover", {
+ backgroundColor: "var(--n-color-hover)",
+ color: "var(--n-text-color-hover)"
+}, [cE("state-border", {
+ border: "var(--n-border-hover)"
+})]), c("&:active", {
+ backgroundColor: "var(--n-color-pressed)",
+ color: "var(--n-text-color-pressed)"
+}, [cE("state-border", {
+ border: "var(--n-border-pressed)"
+})]), cM("pressed", {
+ backgroundColor: "var(--n-color-pressed)",
+ color: "var(--n-text-color-pressed)"
+}, [cE("state-border", {
+ border: "var(--n-border-pressed)"
+})])]), cM("loading", "cursor: wait;"), cB("base-wave", `
+ pointer-events: none;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ animation-iteration-count: 1;
+ animation-duration: var(--n-ripple-duration);
+ animation-timing-function: var(--n-bezier-ease-out), var(--n-bezier-ease-out);
+ `, [cM("active", {
+ zIndex: 1,
+ animationName: "button-wave-spread, button-wave-opacity"
+})]), isBrowser$1 && "MozBoxSizing" in document.createElement("div").style ? c("&::moz-focus-inner", {
+ border: 0
+}) : null, cE("border, state-border", `
+ position: absolute;
+ left: 0;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ border-radius: inherit;
+ transition: border-color .3s var(--n-bezier);
+ pointer-events: none;
+ `), cE("border", {
+ border: "var(--n-border)"
+}), cE("state-border", {
+ border: "var(--n-border)",
+ borderColor: "#0000",
+ zIndex: 1
+}), cE("icon", `
+ margin: var(--n-icon-margin);
+ margin-left: 0;
+ height: var(--n-icon-size);
+ width: var(--n-icon-size);
+ max-width: var(--n-icon-size);
+ font-size: var(--n-icon-size);
+ position: relative;
+ flex-shrink: 0;
+ `, [cB("icon-slot", `
+ height: var(--n-icon-size);
+ width: var(--n-icon-size);
+ position: absolute;
+ left: 0;
+ top: 50%;
+ transform: translateY(-50%);
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ `, [iconSwitchTransition({
+ top: "50%",
+ originalTransform: "translateY(-50%)"
+})]), fadeInWidthExpandTransition()]), cE("content", `
+ display: flex;
+ align-items: center;
+ flex-wrap: nowrap;
+ min-width: 0;
+ `, [c("~", [cE("icon", {
+ margin: "var(--n-icon-margin)",
+ marginRight: 0
+})])]), cM("block", `
+ display: flex;
+ width: 100%;
+ `), cM("dashed", [cE("border, state-border", {
+ borderStyle: "dashed !important"
+})]), cM("disabled", {
+ cursor: "not-allowed",
+ opacity: "var(--n-opacity-disabled)"
+})]), c("@keyframes button-wave-spread", {
+ from: {
+ boxShadow: "0 0 0.5px 0 var(--n-ripple-color)"
+ },
+ to: {
+ // don't use exact 5px since chrome will display the animation with glitches
+ boxShadow: "0 0 0.5px 4.5px var(--n-ripple-color)"
+ }
+}), c("@keyframes button-wave-opacity", {
+ from: {
+ opacity: "var(--n-wave-opacity)"
+ },
+ to: {
+ opacity: 0
+ }
+})]);
+const buttonProps = Object.assign(Object.assign({}, useTheme.props), {
+ color: String,
+ textColor: String,
+ text: Boolean,
+ block: Boolean,
+ loading: Boolean,
+ disabled: Boolean,
+ circle: Boolean,
+ size: String,
+ ghost: Boolean,
+ round: Boolean,
+ secondary: Boolean,
+ tertiary: Boolean,
+ quaternary: Boolean,
+ strong: Boolean,
+ focusable: {
+ type: Boolean,
+ default: true
+ },
+ keyboard: {
+ type: Boolean,
+ default: true
+ },
+ tag: {
+ type: String,
+ default: "button"
+ },
+ type: {
+ type: String,
+ default: "default"
+ },
+ dashed: Boolean,
+ renderIcon: Function,
+ iconPlacement: {
+ type: String,
+ default: "left"
+ },
+ attrType: {
+ type: String,
+ default: "button"
+ },
+ bordered: {
+ type: Boolean,
+ default: true
+ },
+ onClick: [Function, Array],
+ nativeFocusBehavior: {
+ type: Boolean,
+ default: !isSafari
+ }
+});
+const Button = /* @__PURE__ */ defineComponent({
+ name: "Button",
+ props: buttonProps,
+ setup(props) {
+ const selfElRef = ref(null);
+ const waveElRef = ref(null);
+ const enterPressedRef = ref(false);
+ const showBorderRef = useMemo(() => {
+ return !props.quaternary && !props.tertiary && !props.secondary && !props.text && (!props.color || props.ghost || props.dashed) && props.bordered;
+ });
+ const NButtonGroup = inject(buttonGroupInjectionKey, {});
+ const {
+ mergedSizeRef
+ } = useFormItem({}, {
+ defaultSize: "medium",
+ mergedSize: (NFormItem) => {
+ const {
+ size: size2
+ } = props;
+ if (size2) return size2;
+ const {
+ size: buttonGroupSize
+ } = NButtonGroup;
+ if (buttonGroupSize) return buttonGroupSize;
+ const {
+ mergedSize: formItemSize
+ } = NFormItem || {};
+ if (formItemSize) {
+ return formItemSize.value;
+ }
+ return "medium";
+ }
+ });
+ const mergedFocusableRef = computed(() => {
+ return props.focusable && !props.disabled;
+ });
+ const handleMousedown = (e) => {
+ var _a;
+ if (!mergedFocusableRef.value) {
+ e.preventDefault();
+ }
+ if (props.nativeFocusBehavior) {
+ return;
+ }
+ e.preventDefault();
+ if (props.disabled) {
+ return;
+ }
+ if (mergedFocusableRef.value) {
+ (_a = selfElRef.value) === null || _a === void 0 ? void 0 : _a.focus({
+ preventScroll: true
+ });
+ }
+ };
+ const handleClick2 = (e) => {
+ var _a;
+ if (!props.disabled && !props.loading) {
+ const {
+ onClick
+ } = props;
+ if (onClick) call(onClick, e);
+ if (!props.text) {
+ (_a = waveElRef.value) === null || _a === void 0 ? void 0 : _a.play();
+ }
+ }
+ };
+ const handleKeyup = (e) => {
+ switch (e.key) {
+ case "Enter":
+ if (!props.keyboard) {
+ return;
+ }
+ enterPressedRef.value = false;
+ }
+ };
+ const handleKeydown = (e) => {
+ switch (e.key) {
+ case "Enter":
+ if (!props.keyboard || props.loading) {
+ e.preventDefault();
+ return;
+ }
+ enterPressedRef.value = true;
+ }
+ };
+ const handleBlur = () => {
+ enterPressedRef.value = false;
+ };
+ const {
+ inlineThemeDisabled,
+ mergedClsPrefixRef,
+ mergedRtlRef
+ } = useConfig(props);
+ const themeRef = useTheme("Button", "-button", style$6, buttonLight, props, mergedClsPrefixRef);
+ const rtlEnabledRef = useRtl("Button", mergedRtlRef, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const theme = themeRef.value;
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2,
+ cubicBezierEaseOut: cubicBezierEaseOut2
+ },
+ self: self2
+ } = theme;
+ const {
+ rippleDuration,
+ opacityDisabled,
+ fontWeight,
+ fontWeightStrong
+ } = self2;
+ const size2 = mergedSizeRef.value;
+ const {
+ dashed,
+ type,
+ ghost,
+ text,
+ color,
+ round,
+ circle,
+ textColor,
+ secondary,
+ tertiary,
+ quaternary,
+ strong
+ } = props;
+ const fontProps = {
+ "--n-font-weight": strong ? fontWeightStrong : fontWeight
+ };
+ let colorProps = {
+ "--n-color": "initial",
+ "--n-color-hover": "initial",
+ "--n-color-pressed": "initial",
+ "--n-color-focus": "initial",
+ "--n-color-disabled": "initial",
+ "--n-ripple-color": "initial",
+ "--n-text-color": "initial",
+ "--n-text-color-hover": "initial",
+ "--n-text-color-pressed": "initial",
+ "--n-text-color-focus": "initial",
+ "--n-text-color-disabled": "initial"
+ };
+ const typeIsTertiary = type === "tertiary";
+ const typeIsDefault = type === "default";
+ const mergedType = typeIsTertiary ? "default" : type;
+ if (text) {
+ const propTextColor = textColor || color;
+ const mergedTextColor = propTextColor || self2[createKey("textColorText", mergedType)];
+ colorProps = {
+ "--n-color": "#0000",
+ "--n-color-hover": "#0000",
+ "--n-color-pressed": "#0000",
+ "--n-color-focus": "#0000",
+ "--n-color-disabled": "#0000",
+ "--n-ripple-color": "#0000",
+ "--n-text-color": mergedTextColor,
+ "--n-text-color-hover": propTextColor ? createHoverColor(propTextColor) : self2[createKey("textColorTextHover", mergedType)],
+ "--n-text-color-pressed": propTextColor ? createPressedColor(propTextColor) : self2[createKey("textColorTextPressed", mergedType)],
+ "--n-text-color-focus": propTextColor ? createHoverColor(propTextColor) : self2[createKey("textColorTextHover", mergedType)],
+ "--n-text-color-disabled": propTextColor || self2[createKey("textColorTextDisabled", mergedType)]
+ };
+ } else if (ghost || dashed) {
+ const mergedTextColor = textColor || color;
+ colorProps = {
+ "--n-color": "#0000",
+ "--n-color-hover": "#0000",
+ "--n-color-pressed": "#0000",
+ "--n-color-focus": "#0000",
+ "--n-color-disabled": "#0000",
+ "--n-ripple-color": color || self2[createKey("rippleColor", mergedType)],
+ "--n-text-color": mergedTextColor || self2[createKey("textColorGhost", mergedType)],
+ "--n-text-color-hover": mergedTextColor ? createHoverColor(mergedTextColor) : self2[createKey("textColorGhostHover", mergedType)],
+ "--n-text-color-pressed": mergedTextColor ? createPressedColor(mergedTextColor) : self2[createKey("textColorGhostPressed", mergedType)],
+ "--n-text-color-focus": mergedTextColor ? createHoverColor(mergedTextColor) : self2[createKey("textColorGhostHover", mergedType)],
+ "--n-text-color-disabled": mergedTextColor || self2[createKey("textColorGhostDisabled", mergedType)]
+ };
+ } else if (secondary) {
+ const typeTextColor = typeIsDefault ? self2.textColor : typeIsTertiary ? self2.textColorTertiary : self2[createKey("color", mergedType)];
+ const mergedTextColor = color || typeTextColor;
+ const isColoredType = type !== "default" && type !== "tertiary";
+ colorProps = {
+ "--n-color": isColoredType ? changeColor(mergedTextColor, {
+ alpha: Number(self2.colorOpacitySecondary)
+ }) : self2.colorSecondary,
+ "--n-color-hover": isColoredType ? changeColor(mergedTextColor, {
+ alpha: Number(self2.colorOpacitySecondaryHover)
+ }) : self2.colorSecondaryHover,
+ "--n-color-pressed": isColoredType ? changeColor(mergedTextColor, {
+ alpha: Number(self2.colorOpacitySecondaryPressed)
+ }) : self2.colorSecondaryPressed,
+ "--n-color-focus": isColoredType ? changeColor(mergedTextColor, {
+ alpha: Number(self2.colorOpacitySecondaryHover)
+ }) : self2.colorSecondaryHover,
+ "--n-color-disabled": self2.colorSecondary,
+ "--n-ripple-color": "#0000",
+ "--n-text-color": mergedTextColor,
+ "--n-text-color-hover": mergedTextColor,
+ "--n-text-color-pressed": mergedTextColor,
+ "--n-text-color-focus": mergedTextColor,
+ "--n-text-color-disabled": mergedTextColor
+ };
+ } else if (tertiary || quaternary) {
+ const typeColor = typeIsDefault ? self2.textColor : typeIsTertiary ? self2.textColorTertiary : self2[createKey("color", mergedType)];
+ const mergedColor = color || typeColor;
+ if (tertiary) {
+ colorProps["--n-color"] = self2.colorTertiary;
+ colorProps["--n-color-hover"] = self2.colorTertiaryHover;
+ colorProps["--n-color-pressed"] = self2.colorTertiaryPressed;
+ colorProps["--n-color-focus"] = self2.colorSecondaryHover;
+ colorProps["--n-color-disabled"] = self2.colorTertiary;
+ } else {
+ colorProps["--n-color"] = self2.colorQuaternary;
+ colorProps["--n-color-hover"] = self2.colorQuaternaryHover;
+ colorProps["--n-color-pressed"] = self2.colorQuaternaryPressed;
+ colorProps["--n-color-focus"] = self2.colorQuaternaryHover;
+ colorProps["--n-color-disabled"] = self2.colorQuaternary;
+ }
+ colorProps["--n-ripple-color"] = "#0000";
+ colorProps["--n-text-color"] = mergedColor;
+ colorProps["--n-text-color-hover"] = mergedColor;
+ colorProps["--n-text-color-pressed"] = mergedColor;
+ colorProps["--n-text-color-focus"] = mergedColor;
+ colorProps["--n-text-color-disabled"] = mergedColor;
+ } else {
+ colorProps = {
+ "--n-color": color || self2[createKey("color", mergedType)],
+ "--n-color-hover": color ? createHoverColor(color) : self2[createKey("colorHover", mergedType)],
+ "--n-color-pressed": color ? createPressedColor(color) : self2[createKey("colorPressed", mergedType)],
+ "--n-color-focus": color ? createHoverColor(color) : self2[createKey("colorFocus", mergedType)],
+ "--n-color-disabled": color || self2[createKey("colorDisabled", mergedType)],
+ "--n-ripple-color": color || self2[createKey("rippleColor", mergedType)],
+ "--n-text-color": textColor || (color ? self2.textColorPrimary : typeIsTertiary ? self2.textColorTertiary : self2[createKey("textColor", mergedType)]),
+ "--n-text-color-hover": textColor || (color ? self2.textColorHoverPrimary : self2[createKey("textColorHover", mergedType)]),
+ "--n-text-color-pressed": textColor || (color ? self2.textColorPressedPrimary : self2[createKey("textColorPressed", mergedType)]),
+ "--n-text-color-focus": textColor || (color ? self2.textColorFocusPrimary : self2[createKey("textColorFocus", mergedType)]),
+ "--n-text-color-disabled": textColor || (color ? self2.textColorDisabledPrimary : self2[createKey("textColorDisabled", mergedType)])
+ };
+ }
+ let borderProps = {
+ "--n-border": "initial",
+ "--n-border-hover": "initial",
+ "--n-border-pressed": "initial",
+ "--n-border-focus": "initial",
+ "--n-border-disabled": "initial"
+ };
+ if (text) {
+ borderProps = {
+ "--n-border": "none",
+ "--n-border-hover": "none",
+ "--n-border-pressed": "none",
+ "--n-border-focus": "none",
+ "--n-border-disabled": "none"
+ };
+ } else {
+ borderProps = {
+ "--n-border": self2[createKey("border", mergedType)],
+ "--n-border-hover": self2[createKey("borderHover", mergedType)],
+ "--n-border-pressed": self2[createKey("borderPressed", mergedType)],
+ "--n-border-focus": self2[createKey("borderFocus", mergedType)],
+ "--n-border-disabled": self2[createKey("borderDisabled", mergedType)]
+ };
+ }
+ const {
+ [createKey("height", size2)]: height,
+ [createKey("fontSize", size2)]: fontSize2,
+ [createKey("padding", size2)]: padding,
+ [createKey("paddingRound", size2)]: paddingRound,
+ [createKey("iconSize", size2)]: iconSize,
+ [createKey("borderRadius", size2)]: borderRadius,
+ [createKey("iconMargin", size2)]: iconMargin,
+ waveOpacity
+ } = self2;
+ const sizeProps = {
+ "--n-width": circle && !text ? height : "initial",
+ "--n-height": text ? "initial" : height,
+ "--n-font-size": fontSize2,
+ "--n-padding": circle ? "initial" : text ? "initial" : round ? paddingRound : padding,
+ "--n-icon-size": iconSize,
+ "--n-icon-margin": iconMargin,
+ "--n-border-radius": text ? "initial" : circle || round ? height : borderRadius
+ };
+ return Object.assign(Object.assign(Object.assign(Object.assign({
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-bezier-ease-out": cubicBezierEaseOut2,
+ "--n-ripple-duration": rippleDuration,
+ "--n-opacity-disabled": opacityDisabled,
+ "--n-wave-opacity": waveOpacity
+ }, fontProps), colorProps), borderProps), sizeProps);
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("button", computed(() => {
+ let hash = "";
+ const {
+ dashed,
+ type,
+ ghost,
+ text,
+ color,
+ round,
+ circle,
+ textColor,
+ secondary,
+ tertiary,
+ quaternary,
+ strong
+ } = props;
+ if (dashed) hash += "a";
+ if (ghost) hash += "b";
+ if (text) hash += "c";
+ if (round) hash += "d";
+ if (circle) hash += "e";
+ if (secondary) hash += "f";
+ if (tertiary) hash += "g";
+ if (quaternary) hash += "h";
+ if (strong) hash += "i";
+ if (color) hash += `j${color2Class(color)}`;
+ if (textColor) hash += `k${color2Class(textColor)}`;
+ const {
+ value: size2
+ } = mergedSizeRef;
+ hash += `l${size2[0]}`;
+ hash += `m${type[0]}`;
+ return hash;
+ }), cssVarsRef, props) : void 0;
+ return {
+ selfElRef,
+ waveElRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedFocusable: mergedFocusableRef,
+ mergedSize: mergedSizeRef,
+ showBorder: showBorderRef,
+ enterPressed: enterPressedRef,
+ rtlEnabled: rtlEnabledRef,
+ handleMousedown,
+ handleKeydown,
+ handleBlur,
+ handleKeyup,
+ handleClick: handleClick2,
+ customColorCssVars: computed(() => {
+ const {
+ color
+ } = props;
+ if (!color) return null;
+ const hoverColor = createHoverColor(color);
+ return {
+ "--n-border-color": color,
+ "--n-border-color-hover": hoverColor,
+ "--n-border-color-pressed": createPressedColor(color),
+ "--n-border-color-focus": hoverColor,
+ "--n-border-color-disabled": color
+ };
+ }),
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const {
+ mergedClsPrefix,
+ tag: Component,
+ onRender
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ const children = resolveWrappedSlot(this.$slots.default, (children2) => children2 && h("span", {
+ class: `${mergedClsPrefix}-button__content`
+ }, children2));
+ return h(Component, {
+ ref: "selfElRef",
+ class: [
+ this.themeClass,
+ `${mergedClsPrefix}-button`,
+ `${mergedClsPrefix}-button--${this.type}-type`,
+ `${mergedClsPrefix}-button--${this.mergedSize}-type`,
+ this.rtlEnabled && `${mergedClsPrefix}-button--rtl`,
+ this.disabled && `${mergedClsPrefix}-button--disabled`,
+ this.block && `${mergedClsPrefix}-button--block`,
+ this.enterPressed && `${mergedClsPrefix}-button--pressed`,
+ !this.text && this.dashed && `${mergedClsPrefix}-button--dashed`,
+ this.color && `${mergedClsPrefix}-button--color`,
+ this.secondary && `${mergedClsPrefix}-button--secondary`,
+ this.loading && `${mergedClsPrefix}-button--loading`,
+ this.ghost && `${mergedClsPrefix}-button--ghost`
+ // required for button group border collapse
+ ],
+ tabindex: this.mergedFocusable ? 0 : -1,
+ type: this.attrType,
+ style: this.cssVars,
+ disabled: this.disabled,
+ onClick: this.handleClick,
+ onBlur: this.handleBlur,
+ onMousedown: this.handleMousedown,
+ onKeyup: this.handleKeyup,
+ onKeydown: this.handleKeydown
+ }, this.iconPlacement === "right" && children, h(NFadeInExpandTransition, {
+ width: true
+ }, {
+ default: () => resolveWrappedSlot(this.$slots.icon, (children2) => (this.loading || this.renderIcon || children2) && h("span", {
+ class: `${mergedClsPrefix}-button__icon`,
+ style: {
+ margin: isSlotEmpty(this.$slots.default) ? "0" : ""
+ }
+ }, h(NIconSwitchTransition, null, {
+ default: () => this.loading ? h(NBaseLoading, {
+ clsPrefix: mergedClsPrefix,
+ key: "loading",
+ class: `${mergedClsPrefix}-icon-slot`,
+ strokeWidth: 20
+ }) : h("div", {
+ key: "icon",
+ class: `${mergedClsPrefix}-icon-slot`,
+ role: "none"
+ }, this.renderIcon ? this.renderIcon() : children2)
+ })))
+ }), this.iconPlacement === "left" && children, !this.text ? h(NBaseWave, {
+ ref: "waveElRef",
+ clsPrefix: mergedClsPrefix
+ }) : null, this.showBorder ? h("div", {
+ "aria-hidden": true,
+ class: `${mergedClsPrefix}-button__border`,
+ style: this.customColorCssVars
+ }) : null, this.showBorder ? h("div", {
+ "aria-hidden": true,
+ class: `${mergedClsPrefix}-button__state-border`,
+ style: this.customColorCssVars
+ }) : null);
+ }
+});
+const XButton = Button;
+const commonVariables$e = {
+ titleFontSize: "22px"
+};
+function self$13(vars) {
+ const {
+ borderRadius,
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ textColor2,
+ textColor1,
+ textColorDisabled,
+ dividerColor,
+ fontWeightStrong,
+ primaryColor,
+ baseColor,
+ hoverColor,
+ cardColor,
+ modalColor,
+ popoverColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$e), {
+ borderRadius,
+ borderColor: composite(cardColor, dividerColor),
+ borderColorModal: composite(modalColor, dividerColor),
+ borderColorPopover: composite(popoverColor, dividerColor),
+ textColor: textColor2,
+ titleFontWeight: fontWeightStrong,
+ titleTextColor: textColor1,
+ dayTextColor: textColorDisabled,
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ dateColorCurrent: primaryColor,
+ dateTextColorCurrent: baseColor,
+ cellColorHover: composite(cardColor, hoverColor),
+ cellColorHoverModal: composite(modalColor, hoverColor),
+ cellColorHoverPopover: composite(popoverColor, hoverColor),
+ cellColor: cardColor,
+ cellColorModal: modalColor,
+ cellColorPopover: popoverColor,
+ barColor: primaryColor
+ });
+}
+const calendarLight = createTheme({
+ name: "Calendar",
+ common: derived,
+ peers: {
+ Button: buttonLight
+ },
+ self: self$13
+});
+const calendarDark = {
+ name: "Calendar",
+ common: derived$1,
+ peers: {
+ Button: buttonDark
+ },
+ self: self$13
+};
+const commonVariables$d = {
+ paddingSmall: "12px 16px 12px",
+ paddingMedium: "19px 24px 20px",
+ paddingLarge: "23px 32px 24px",
+ paddingHuge: "27px 40px 28px",
+ titleFontSizeSmall: "16px",
+ titleFontSizeMedium: "18px",
+ titleFontSizeLarge: "18px",
+ titleFontSizeHuge: "18px",
+ closeIconSize: "18px",
+ closeSize: "22px"
+};
+function self$12(vars) {
+ const {
+ primaryColor,
+ borderRadius,
+ lineHeight: lineHeight2,
+ fontSize: fontSize2,
+ cardColor,
+ textColor2,
+ textColor1,
+ dividerColor,
+ fontWeightStrong,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ modalColor,
+ boxShadow1,
+ popoverColor,
+ actionColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$d), {
+ lineHeight: lineHeight2,
+ color: cardColor,
+ colorModal: modalColor,
+ colorPopover: popoverColor,
+ colorTarget: primaryColor,
+ colorEmbedded: actionColor,
+ colorEmbeddedModal: actionColor,
+ colorEmbeddedPopover: actionColor,
+ textColor: textColor2,
+ titleTextColor: textColor1,
+ borderColor: dividerColor,
+ actionColor,
+ titleFontWeight: fontWeightStrong,
+ closeColorHover,
+ closeColorPressed,
+ closeBorderRadius: borderRadius,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ fontSizeSmall: fontSize2,
+ fontSizeMedium: fontSize2,
+ fontSizeLarge: fontSize2,
+ fontSizeHuge: fontSize2,
+ boxShadow: boxShadow1,
+ borderRadius
+ });
+}
+const cardLight = {
+ name: "Card",
+ common: derived,
+ self: self$12
+};
+const cardDark = {
+ name: "Card",
+ common: derived$1,
+ self(vars) {
+ const commonSelf = self$12(vars);
+ const {
+ cardColor,
+ modalColor,
+ popoverColor
+ } = vars;
+ commonSelf.colorEmbedded = cardColor;
+ commonSelf.colorEmbeddedModal = modalColor;
+ commonSelf.colorEmbeddedPopover = popoverColor;
+ return commonSelf;
+ }
+};
+const style$5 = c([cB("card", `
+ font-size: var(--n-font-size);
+ line-height: var(--n-line-height);
+ display: flex;
+ flex-direction: column;
+ width: 100%;
+ box-sizing: border-box;
+ position: relative;
+ border-radius: var(--n-border-radius);
+ background-color: var(--n-color);
+ color: var(--n-text-color);
+ word-break: break-word;
+ transition:
+ color .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier),
+ border-color .3s var(--n-bezier);
+ `, [asModal({
+ background: "var(--n-color-modal)"
+}), cM("hoverable", [c("&:hover", "box-shadow: var(--n-box-shadow);")]), cM("content-segmented", [c(">", [cE("content", {
+ paddingTop: "var(--n-padding-bottom)"
+})])]), cM("content-soft-segmented", [c(">", [cE("content", `
+ margin: 0 var(--n-padding-left);
+ padding: var(--n-padding-bottom) 0;
+ `)])]), cM("footer-segmented", [c(">", [cE("footer", {
+ paddingTop: "var(--n-padding-bottom)"
+})])]), cM("footer-soft-segmented", [c(">", [cE("footer", `
+ padding: var(--n-padding-bottom) 0;
+ margin: 0 var(--n-padding-left);
+ `)])]), c(">", [cB("card-header", `
+ box-sizing: border-box;
+ display: flex;
+ align-items: center;
+ font-size: var(--n-title-font-size);
+ padding:
+ var(--n-padding-top)
+ var(--n-padding-left)
+ var(--n-padding-bottom)
+ var(--n-padding-left);
+ `, [cE("main", `
+ font-weight: var(--n-title-font-weight);
+ transition: color .3s var(--n-bezier);
+ flex: 1;
+ min-width: 0;
+ color: var(--n-title-text-color);
+ `), cE("extra", `
+ display: flex;
+ align-items: center;
+ font-size: var(--n-font-size);
+ font-weight: 400;
+ transition: color .3s var(--n-bezier);
+ color: var(--n-text-color);
+ `), cE("close", `
+ margin: 0 0 0 8px;
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ `)]), cE("action", `
+ box-sizing: border-box;
+ transition:
+ background-color .3s var(--n-bezier),
+ border-color .3s var(--n-bezier);
+ background-clip: padding-box;
+ background-color: var(--n-action-color);
+ `), cE("content", "flex: 1; min-width: 0;"), cE("content, footer", `
+ box-sizing: border-box;
+ padding: 0 var(--n-padding-left) var(--n-padding-bottom) var(--n-padding-left);
+ font-size: var(--n-font-size);
+ `, [c("&:first-child", {
+ paddingTop: "var(--n-padding-bottom)"
+})]), cE("action", `
+ background-color: var(--n-action-color);
+ padding: var(--n-padding-bottom) var(--n-padding-left);
+ border-bottom-left-radius: var(--n-border-radius);
+ border-bottom-right-radius: var(--n-border-radius);
+ `)]), cB("card-cover", `
+ overflow: hidden;
+ width: 100%;
+ border-radius: var(--n-border-radius) var(--n-border-radius) 0 0;
+ `, [c("img", `
+ display: block;
+ width: 100%;
+ `)]), cM("bordered", `
+ border: 1px solid var(--n-border-color);
+ `, [c("&:target", "border-color: var(--n-color-target);")]), cM("action-segmented", [c(">", [cE("action", [c("&:not(:first-child)", {
+ borderTop: "1px solid var(--n-border-color)"
+})])])]), cM("content-segmented, content-soft-segmented", [c(">", [cE("content", {
+ transition: "border-color 0.3s var(--n-bezier)"
+}, [c("&:not(:first-child)", {
+ borderTop: "1px solid var(--n-border-color)"
+})])])]), cM("footer-segmented, footer-soft-segmented", [c(">", [cE("footer", {
+ transition: "border-color 0.3s var(--n-bezier)"
+}, [c("&:not(:first-child)", {
+ borderTop: "1px solid var(--n-border-color)"
+})])])]), cM("embedded", `
+ background-color: var(--n-color-embedded);
+ `)]), insideModal(cB("card", `
+ background: var(--n-color-modal);
+ `, [cM("embedded", `
+ background-color: var(--n-color-embedded-modal);
+ `)])), insidePopover(cB("card", `
+ background: var(--n-color-popover);
+ `, [cM("embedded", `
+ background-color: var(--n-color-embedded-popover);
+ `)]))]);
+const cardBaseProps = {
+ title: [String, Function],
+ contentClass: String,
+ contentStyle: [Object, String],
+ headerClass: String,
+ headerStyle: [Object, String],
+ headerExtraClass: String,
+ headerExtraStyle: [Object, String],
+ footerClass: String,
+ footerStyle: [Object, String],
+ embedded: Boolean,
+ segmented: {
+ type: [Boolean, Object],
+ default: false
+ },
+ size: {
+ type: String,
+ default: "medium"
+ },
+ bordered: {
+ type: Boolean,
+ default: true
+ },
+ closable: Boolean,
+ hoverable: Boolean,
+ role: String,
+ onClose: [Function, Array],
+ tag: {
+ type: String,
+ default: "div"
+ },
+ cover: Function,
+ content: [String, Function],
+ footer: Function,
+ action: Function,
+ headerExtra: Function
+};
+const cardBasePropKeys = keysOf(cardBaseProps);
+const cardProps = Object.assign(Object.assign({}, useTheme.props), cardBaseProps);
+const NCard = /* @__PURE__ */ defineComponent({
+ name: "Card",
+ props: cardProps,
+ setup(props) {
+ const handleCloseClick = () => {
+ const {
+ onClose
+ } = props;
+ if (onClose) call(onClose);
+ };
+ const {
+ inlineThemeDisabled,
+ mergedClsPrefixRef,
+ mergedRtlRef
+ } = useConfig(props);
+ const themeRef = useTheme("Card", "-card", style$5, cardLight, props, mergedClsPrefixRef);
+ const rtlEnabledRef = useRtl("Card", mergedRtlRef, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ size: size2
+ } = props;
+ const {
+ self: {
+ color,
+ colorModal,
+ colorTarget,
+ textColor,
+ titleTextColor,
+ titleFontWeight,
+ borderColor,
+ actionColor,
+ borderRadius,
+ lineHeight: lineHeight2,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ closeBorderRadius,
+ closeIconSize,
+ closeSize,
+ boxShadow,
+ colorPopover,
+ colorEmbedded,
+ colorEmbeddedModal,
+ colorEmbeddedPopover,
+ [createKey("padding", size2)]: padding,
+ [createKey("fontSize", size2)]: fontSize2,
+ [createKey("titleFontSize", size2)]: titleFontSize
+ },
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ }
+ } = themeRef.value;
+ const {
+ top: paddingTop,
+ left: paddingLeft,
+ bottom: paddingBottom
+ } = getMargin(padding);
+ return {
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-border-radius": borderRadius,
+ "--n-color": color,
+ "--n-color-modal": colorModal,
+ "--n-color-popover": colorPopover,
+ "--n-color-embedded": colorEmbedded,
+ "--n-color-embedded-modal": colorEmbeddedModal,
+ "--n-color-embedded-popover": colorEmbeddedPopover,
+ "--n-color-target": colorTarget,
+ "--n-text-color": textColor,
+ "--n-line-height": lineHeight2,
+ "--n-action-color": actionColor,
+ "--n-title-text-color": titleTextColor,
+ "--n-title-font-weight": titleFontWeight,
+ "--n-close-icon-color": closeIconColor,
+ "--n-close-icon-color-hover": closeIconColorHover,
+ "--n-close-icon-color-pressed": closeIconColorPressed,
+ "--n-close-color-hover": closeColorHover,
+ "--n-close-color-pressed": closeColorPressed,
+ "--n-border-color": borderColor,
+ "--n-box-shadow": boxShadow,
+ // size
+ "--n-padding-top": paddingTop,
+ "--n-padding-bottom": paddingBottom,
+ "--n-padding-left": paddingLeft,
+ "--n-font-size": fontSize2,
+ "--n-title-font-size": titleFontSize,
+ "--n-close-size": closeSize,
+ "--n-close-icon-size": closeIconSize,
+ "--n-close-border-radius": closeBorderRadius
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("card", computed(() => {
+ return props.size[0];
+ }), cssVarsRef, props) : void 0;
+ return {
+ rtlEnabled: rtlEnabledRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedTheme: themeRef,
+ handleCloseClick,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const {
+ segmented,
+ bordered,
+ hoverable,
+ mergedClsPrefix,
+ rtlEnabled,
+ onRender,
+ embedded,
+ tag: Component,
+ $slots
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ return h(Component, {
+ class: [`${mergedClsPrefix}-card`, this.themeClass, embedded && `${mergedClsPrefix}-card--embedded`, {
+ [`${mergedClsPrefix}-card--rtl`]: rtlEnabled,
+ [`${mergedClsPrefix}-card--content${typeof segmented !== "boolean" && segmented.content === "soft" ? "-soft" : ""}-segmented`]: segmented === true || segmented !== false && segmented.content,
+ [`${mergedClsPrefix}-card--footer${typeof segmented !== "boolean" && segmented.footer === "soft" ? "-soft" : ""}-segmented`]: segmented === true || segmented !== false && segmented.footer,
+ [`${mergedClsPrefix}-card--action-segmented`]: segmented === true || segmented !== false && segmented.action,
+ [`${mergedClsPrefix}-card--bordered`]: bordered,
+ [`${mergedClsPrefix}-card--hoverable`]: hoverable
+ }],
+ style: this.cssVars,
+ role: this.role
+ }, resolveWrappedSlot($slots.cover, (children) => {
+ const mergedChildren = this.cover ? ensureValidVNode([this.cover()]) : children;
+ return mergedChildren && h("div", {
+ class: `${mergedClsPrefix}-card-cover`,
+ role: "none"
+ }, mergedChildren);
+ }), resolveWrappedSlot($slots.header, (children) => {
+ const {
+ title
+ } = this;
+ const mergedChildren = title ? ensureValidVNode(typeof title === "function" ? [title()] : [title]) : children;
+ return mergedChildren || this.closable ? h("div", {
+ class: [`${mergedClsPrefix}-card-header`, this.headerClass],
+ style: this.headerStyle,
+ role: "heading"
+ }, h("div", {
+ class: `${mergedClsPrefix}-card-header__main`,
+ role: "heading"
+ }, mergedChildren), resolveWrappedSlot($slots["header-extra"], (children2) => {
+ const mergedChildren2 = this.headerExtra ? ensureValidVNode([this.headerExtra()]) : children2;
+ return mergedChildren2 && h("div", {
+ class: [`${mergedClsPrefix}-card-header__extra`, this.headerExtraClass],
+ style: this.headerExtraStyle
+ }, mergedChildren2);
+ }), this.closable && h(NBaseClose, {
+ clsPrefix: mergedClsPrefix,
+ class: `${mergedClsPrefix}-card-header__close`,
+ onClick: this.handleCloseClick,
+ absolute: true
+ })) : null;
+ }), resolveWrappedSlot($slots.default, (children) => {
+ const {
+ content
+ } = this;
+ const mergedChildren = content ? ensureValidVNode(typeof content === "function" ? [content()] : [content]) : children;
+ return mergedChildren && h("div", {
+ class: [`${mergedClsPrefix}-card__content`, this.contentClass],
+ style: this.contentStyle,
+ role: "none"
+ }, mergedChildren);
+ }), resolveWrappedSlot($slots.footer, (children) => {
+ const mergedChildren = this.footer ? ensureValidVNode([this.footer()]) : children;
+ return mergedChildren && h("div", {
+ class: [`${mergedClsPrefix}-card__footer`, this.footerClass],
+ style: this.footerStyle,
+ role: "none"
+ }, mergedChildren);
+ }), resolveWrappedSlot($slots.action, (children) => {
+ const mergedChildren = this.action ? ensureValidVNode([this.action()]) : children;
+ return mergedChildren && h("div", {
+ class: `${mergedClsPrefix}-card__action`,
+ role: "none"
+ }, mergedChildren);
+ }));
+ }
+});
+function self$11() {
+ return {
+ dotSize: "8px",
+ dotColor: "rgba(255, 255, 255, .3)",
+ dotColorActive: "rgba(255, 255, 255, 1)",
+ dotColorFocus: "rgba(255, 255, 255, .5)",
+ dotLineWidth: "16px",
+ dotLineWidthActive: "24px",
+ arrowColor: "#eee"
+ };
+}
+const carouselLight = {
+ name: "Carousel",
+ common: derived,
+ self: self$11
+};
+const carouselDark = {
+ name: "Carousel",
+ common: derived$1,
+ self: self$11
+};
+const commonVariables$c = {
+ sizeSmall: "14px",
+ sizeMedium: "16px",
+ sizeLarge: "18px",
+ labelPadding: "0 8px",
+ labelFontWeight: "400"
+};
+function self$10(vars) {
+ const {
+ baseColor,
+ inputColorDisabled,
+ cardColor,
+ modalColor,
+ popoverColor,
+ textColorDisabled,
+ borderColor,
+ primaryColor,
+ textColor2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadiusSmall,
+ lineHeight: lineHeight2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$c), {
+ labelLineHeight: lineHeight2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadius: borderRadiusSmall,
+ color: baseColor,
+ colorChecked: primaryColor,
+ colorDisabled: inputColorDisabled,
+ colorDisabledChecked: inputColorDisabled,
+ colorTableHeader: cardColor,
+ colorTableHeaderModal: modalColor,
+ colorTableHeaderPopover: popoverColor,
+ checkMarkColor: baseColor,
+ checkMarkColorDisabled: textColorDisabled,
+ checkMarkColorDisabledChecked: textColorDisabled,
+ border: `1px solid ${borderColor}`,
+ borderDisabled: `1px solid ${borderColor}`,
+ borderDisabledChecked: `1px solid ${borderColor}`,
+ borderChecked: `1px solid ${primaryColor}`,
+ borderFocus: `1px solid ${primaryColor}`,
+ boxShadowFocus: `0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ textColor: textColor2,
+ textColorDisabled
+ });
+}
+const checkboxLight = {
+ name: "Checkbox",
+ common: derived,
+ self: self$10
+};
+const checkboxDark = {
+ name: "Checkbox",
+ common: derived$1,
+ self(vars) {
+ const {
+ cardColor
+ } = vars;
+ const commonSelf = self$10(vars);
+ commonSelf.color = "#0000";
+ commonSelf.checkMarkColor = cardColor;
+ return commonSelf;
+ }
+};
+function self$$(vars) {
+ const {
+ borderRadius,
+ boxShadow2,
+ popoverColor,
+ textColor2,
+ textColor3,
+ primaryColor,
+ textColorDisabled,
+ dividerColor,
+ hoverColor,
+ fontSizeMedium,
+ heightMedium
+ } = vars;
+ return {
+ menuBorderRadius: borderRadius,
+ menuColor: popoverColor,
+ menuBoxShadow: boxShadow2,
+ menuDividerColor: dividerColor,
+ menuHeight: "calc(var(--n-option-height) * 6.6)",
+ optionArrowColor: textColor3,
+ optionHeight: heightMedium,
+ optionFontSize: fontSizeMedium,
+ optionColorHover: hoverColor,
+ optionTextColor: textColor2,
+ optionTextColorActive: primaryColor,
+ optionTextColorDisabled: textColorDisabled,
+ optionCheckMarkColor: primaryColor,
+ loadingColor: primaryColor,
+ columnWidth: "180px"
+ };
+}
+const cascaderLight = createTheme({
+ name: "Cascader",
+ common: derived,
+ peers: {
+ InternalSelectMenu: internalSelectMenuLight,
+ InternalSelection: internalSelectionLight,
+ Scrollbar: scrollbarLight,
+ Checkbox: checkboxLight,
+ Empty: emptyLight
+ },
+ self: self$$
+});
+const cascaderDark = {
+ name: "Cascader",
+ common: derived$1,
+ peers: {
+ InternalSelectMenu: internalSelectMenuDark,
+ InternalSelection: internalSelectionDark,
+ Scrollbar: scrollbarDark,
+ Checkbox: checkboxDark,
+ Empty: emptyLight
+ },
+ self: self$$
+};
+const checkboxGroupInjectionKey = createInjectionKey("n-checkbox-group");
+const renderCheckMark = () => h("svg", {
+ viewBox: "0 0 64 64",
+ class: "check-icon"
+}, h("path", {
+ d: "M50.42,16.76L22.34,39.45l-8.1-11.46c-1.12-1.58-3.3-1.96-4.88-0.84c-1.58,1.12-1.95,3.3-0.84,4.88l10.26,14.51 c0.56,0.79,1.42,1.31,2.38,1.45c0.16,0.02,0.32,0.03,0.48,0.03c0.8,0,1.57-0.27,2.2-0.78l30.99-25.03c1.5-1.21,1.74-3.42,0.52-4.92 C54.13,15.78,51.93,15.55,50.42,16.76z"
+}));
+const renderLineMark = () => h("svg", {
+ viewBox: "0 0 100 100",
+ class: "line-icon"
+}, h("path", {
+ d: "M80.2,55.5H21.4c-2.8,0-5.1-2.5-5.1-5.5l0,0c0-3,2.3-5.5,5.1-5.5h58.7c2.8,0,5.1,2.5,5.1,5.5l0,0C85.2,53.1,82.9,55.5,80.2,55.5z"
+}));
+const style$4 = c([
+ cB("checkbox", `
+ font-size: var(--n-font-size);
+ outline: none;
+ cursor: pointer;
+ display: inline-flex;
+ flex-wrap: nowrap;
+ align-items: flex-start;
+ word-break: break-word;
+ line-height: var(--n-size);
+ --n-merged-color-table: var(--n-color-table);
+ `, [cM("show-label", "line-height: var(--n-label-line-height);"), c("&:hover", [cB("checkbox-box", [cE("border", "border: var(--n-border-checked);")])]), c("&:focus:not(:active)", [cB("checkbox-box", [cE("border", `
+ border: var(--n-border-focus);
+ box-shadow: var(--n-box-shadow-focus);
+ `)])]), cM("inside-table", [cB("checkbox-box", `
+ background-color: var(--n-merged-color-table);
+ `)]), cM("checked", [cB("checkbox-box", `
+ background-color: var(--n-color-checked);
+ `, [cB("checkbox-icon", [
+ // if not set width to 100%, safari & old chrome won't display the icon
+ c(".check-icon", `
+ opacity: 1;
+ transform: scale(1);
+ `)
+ ])])]), cM("indeterminate", [cB("checkbox-box", [cB("checkbox-icon", [c(".check-icon", `
+ opacity: 0;
+ transform: scale(.5);
+ `), c(".line-icon", `
+ opacity: 1;
+ transform: scale(1);
+ `)])])]), cM("checked, indeterminate", [c("&:focus:not(:active)", [cB("checkbox-box", [cE("border", `
+ border: var(--n-border-checked);
+ box-shadow: var(--n-box-shadow-focus);
+ `)])]), cB("checkbox-box", `
+ background-color: var(--n-color-checked);
+ border-left: 0;
+ border-top: 0;
+ `, [cE("border", {
+ border: "var(--n-border-checked)"
+ })])]), cM("disabled", {
+ cursor: "not-allowed"
+ }, [cM("checked", [cB("checkbox-box", `
+ background-color: var(--n-color-disabled-checked);
+ `, [cE("border", {
+ border: "var(--n-border-disabled-checked)"
+ }), cB("checkbox-icon", [c(".check-icon, .line-icon", {
+ fill: "var(--n-check-mark-color-disabled-checked)"
+ })])])]), cB("checkbox-box", `
+ background-color: var(--n-color-disabled);
+ `, [cE("border", `
+ border: var(--n-border-disabled);
+ `), cB("checkbox-icon", [c(".check-icon, .line-icon", `
+ fill: var(--n-check-mark-color-disabled);
+ `)])]), cE("label", `
+ color: var(--n-text-color-disabled);
+ `)]), cB("checkbox-box-wrapper", `
+ position: relative;
+ width: var(--n-size);
+ flex-shrink: 0;
+ flex-grow: 0;
+ user-select: none;
+ -webkit-user-select: none;
+ `), cB("checkbox-box", `
+ position: absolute;
+ left: 0;
+ top: 50%;
+ transform: translateY(-50%);
+ height: var(--n-size);
+ width: var(--n-size);
+ display: inline-block;
+ box-sizing: border-box;
+ border-radius: var(--n-border-radius);
+ background-color: var(--n-color);
+ transition: background-color 0.3s var(--n-bezier);
+ `, [cE("border", `
+ transition:
+ border-color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier);
+ border-radius: inherit;
+ position: absolute;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ border: var(--n-border);
+ `), cB("checkbox-icon", `
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ position: absolute;
+ left: 1px;
+ right: 1px;
+ top: 1px;
+ bottom: 1px;
+ `, [c(".check-icon, .line-icon", `
+ width: 100%;
+ fill: var(--n-check-mark-color);
+ opacity: 0;
+ transform: scale(0.5);
+ transform-origin: center;
+ transition:
+ fill 0.3s var(--n-bezier),
+ transform 0.3s var(--n-bezier),
+ opacity 0.3s var(--n-bezier),
+ border-color 0.3s var(--n-bezier);
+ `), iconSwitchTransition({
+ left: "1px",
+ top: "1px"
+ })])]), cE("label", `
+ color: var(--n-text-color);
+ transition: color .3s var(--n-bezier);
+ user-select: none;
+ -webkit-user-select: none;
+ padding: var(--n-label-padding);
+ font-weight: var(--n-label-font-weight);
+ `, [c("&:empty", {
+ display: "none"
+ })])]),
+ // modal table header checkbox
+ insideModal(cB("checkbox", `
+ --n-merged-color-table: var(--n-color-table-modal);
+ `)),
+ // popover table header checkbox
+ insidePopover(cB("checkbox", `
+ --n-merged-color-table: var(--n-color-table-popover);
+ `))
+]);
+const checkboxProps = Object.assign(Object.assign({}, useTheme.props), {
+ size: String,
+ checked: {
+ type: [Boolean, String, Number],
+ default: void 0
+ },
+ defaultChecked: {
+ type: [Boolean, String, Number],
+ default: false
+ },
+ value: [String, Number],
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ indeterminate: Boolean,
+ label: String,
+ focusable: {
+ type: Boolean,
+ default: true
+ },
+ checkedValue: {
+ type: [Boolean, String, Number],
+ default: true
+ },
+ uncheckedValue: {
+ type: [Boolean, String, Number],
+ default: false
+ },
+ "onUpdate:checked": [Function, Array],
+ onUpdateChecked: [Function, Array],
+ // private
+ privateInsideTable: Boolean,
+ // deprecated
+ onChange: [Function, Array]
+});
+const __unplugin_components_0$2 = /* @__PURE__ */ defineComponent({
+ name: "Checkbox",
+ props: checkboxProps,
+ setup(props) {
+ const NCheckboxGroup = inject(checkboxGroupInjectionKey, null);
+ const selfRef = ref(null);
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const uncontrolledCheckedRef = ref(props.defaultChecked);
+ const controlledCheckedRef = toRef(props, "checked");
+ const mergedCheckedRef = useMergedState(controlledCheckedRef, uncontrolledCheckedRef);
+ const renderedCheckedRef = useMemo(() => {
+ if (NCheckboxGroup) {
+ const groupValueSet = NCheckboxGroup.valueSetRef.value;
+ if (groupValueSet && props.value !== void 0) {
+ return groupValueSet.has(props.value);
+ }
+ return false;
+ } else {
+ return mergedCheckedRef.value === props.checkedValue;
+ }
+ });
+ const formItem = useFormItem(props, {
+ mergedSize(NFormItem) {
+ const {
+ size: size2
+ } = props;
+ if (size2 !== void 0) return size2;
+ if (NCheckboxGroup) {
+ const {
+ value: mergedSize
+ } = NCheckboxGroup.mergedSizeRef;
+ if (mergedSize !== void 0) {
+ return mergedSize;
+ }
+ }
+ if (NFormItem) {
+ const {
+ mergedSize
+ } = NFormItem;
+ if (mergedSize !== void 0) return mergedSize.value;
+ }
+ return "medium";
+ },
+ mergedDisabled(NFormItem) {
+ const {
+ disabled
+ } = props;
+ if (disabled !== void 0) return disabled;
+ if (NCheckboxGroup) {
+ if (NCheckboxGroup.disabledRef.value) return true;
+ const {
+ maxRef: {
+ value: max
+ },
+ checkedCountRef
+ } = NCheckboxGroup;
+ if (max !== void 0 && checkedCountRef.value >= max && !renderedCheckedRef.value) {
+ return true;
+ }
+ const {
+ minRef: {
+ value: min
+ }
+ } = NCheckboxGroup;
+ if (min !== void 0 && checkedCountRef.value <= min && renderedCheckedRef.value) {
+ return true;
+ }
+ }
+ if (NFormItem) {
+ return NFormItem.disabled.value;
+ }
+ return false;
+ }
+ });
+ const {
+ mergedDisabledRef,
+ mergedSizeRef
+ } = formItem;
+ const themeRef = useTheme("Checkbox", "-checkbox", style$4, checkboxLight, props, mergedClsPrefixRef);
+ function toggle(e) {
+ if (NCheckboxGroup && props.value !== void 0) {
+ NCheckboxGroup.toggleCheckbox(!renderedCheckedRef.value, props.value);
+ } else {
+ const {
+ onChange,
+ "onUpdate:checked": _onUpdateCheck,
+ onUpdateChecked
+ } = props;
+ const {
+ nTriggerFormInput,
+ nTriggerFormChange
+ } = formItem;
+ const nextChecked = renderedCheckedRef.value ? props.uncheckedValue : props.checkedValue;
+ if (_onUpdateCheck) {
+ call(_onUpdateCheck, nextChecked, e);
+ }
+ if (onUpdateChecked) {
+ call(onUpdateChecked, nextChecked, e);
+ }
+ if (onChange) call(onChange, nextChecked, e);
+ nTriggerFormInput();
+ nTriggerFormChange();
+ uncontrolledCheckedRef.value = nextChecked;
+ }
+ }
+ function handleClick2(e) {
+ if (!mergedDisabledRef.value) {
+ toggle(e);
+ }
+ }
+ function handleKeyUp(e) {
+ if (mergedDisabledRef.value) return;
+ switch (e.key) {
+ case " ":
+ case "Enter":
+ toggle(e);
+ }
+ }
+ function handleKeyDown(e) {
+ switch (e.key) {
+ case " ":
+ e.preventDefault();
+ }
+ }
+ const exposedMethods = {
+ focus: () => {
+ var _a;
+ (_a = selfRef.value) === null || _a === void 0 ? void 0 : _a.focus();
+ },
+ blur: () => {
+ var _a;
+ (_a = selfRef.value) === null || _a === void 0 ? void 0 : _a.blur();
+ }
+ };
+ const rtlEnabledRef = useRtl("Checkbox", mergedRtlRef, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ value: mergedSize
+ } = mergedSizeRef;
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ },
+ self: {
+ borderRadius,
+ color,
+ colorChecked,
+ colorDisabled,
+ colorTableHeader,
+ colorTableHeaderModal,
+ colorTableHeaderPopover,
+ checkMarkColor,
+ checkMarkColorDisabled,
+ border,
+ borderFocus,
+ borderDisabled,
+ borderChecked,
+ boxShadowFocus,
+ textColor,
+ textColorDisabled,
+ checkMarkColorDisabledChecked,
+ colorDisabledChecked,
+ borderDisabledChecked,
+ labelPadding,
+ labelLineHeight,
+ labelFontWeight,
+ [createKey("fontSize", mergedSize)]: fontSize2,
+ [createKey("size", mergedSize)]: size2
+ }
+ } = themeRef.value;
+ return {
+ "--n-label-line-height": labelLineHeight,
+ "--n-label-font-weight": labelFontWeight,
+ "--n-size": size2,
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-border-radius": borderRadius,
+ "--n-border": border,
+ "--n-border-checked": borderChecked,
+ "--n-border-focus": borderFocus,
+ "--n-border-disabled": borderDisabled,
+ "--n-border-disabled-checked": borderDisabledChecked,
+ "--n-box-shadow-focus": boxShadowFocus,
+ "--n-color": color,
+ "--n-color-checked": colorChecked,
+ "--n-color-table": colorTableHeader,
+ "--n-color-table-modal": colorTableHeaderModal,
+ "--n-color-table-popover": colorTableHeaderPopover,
+ "--n-color-disabled": colorDisabled,
+ "--n-color-disabled-checked": colorDisabledChecked,
+ "--n-text-color": textColor,
+ "--n-text-color-disabled": textColorDisabled,
+ "--n-check-mark-color": checkMarkColor,
+ "--n-check-mark-color-disabled": checkMarkColorDisabled,
+ "--n-check-mark-color-disabled-checked": checkMarkColorDisabledChecked,
+ "--n-font-size": fontSize2,
+ "--n-label-padding": labelPadding
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("checkbox", computed(() => mergedSizeRef.value[0]), cssVarsRef, props) : void 0;
+ return Object.assign(formItem, exposedMethods, {
+ rtlEnabled: rtlEnabledRef,
+ selfRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedDisabled: mergedDisabledRef,
+ renderedChecked: renderedCheckedRef,
+ mergedTheme: themeRef,
+ labelId: createId(),
+ handleClick: handleClick2,
+ handleKeyUp,
+ handleKeyDown,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ });
+ },
+ render() {
+ var _a;
+ const {
+ $slots,
+ renderedChecked,
+ mergedDisabled,
+ indeterminate,
+ privateInsideTable,
+ cssVars,
+ labelId,
+ label,
+ mergedClsPrefix,
+ focusable,
+ handleKeyUp,
+ handleKeyDown,
+ handleClick: handleClick2
+ } = this;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ const labelNode = resolveWrappedSlot($slots.default, (children) => {
+ if (label || children) {
+ return h("span", {
+ class: `${mergedClsPrefix}-checkbox__label`,
+ id: labelId
+ }, label || children);
+ }
+ return null;
+ });
+ return h("div", {
+ ref: "selfRef",
+ class: [`${mergedClsPrefix}-checkbox`, this.themeClass, this.rtlEnabled && `${mergedClsPrefix}-checkbox--rtl`, renderedChecked && `${mergedClsPrefix}-checkbox--checked`, mergedDisabled && `${mergedClsPrefix}-checkbox--disabled`, indeterminate && `${mergedClsPrefix}-checkbox--indeterminate`, privateInsideTable && `${mergedClsPrefix}-checkbox--inside-table`, labelNode && `${mergedClsPrefix}-checkbox--show-label`],
+ tabindex: mergedDisabled || !focusable ? void 0 : 0,
+ role: "checkbox",
+ "aria-checked": indeterminate ? "mixed" : renderedChecked,
+ "aria-labelledby": labelId,
+ style: cssVars,
+ onKeyup: handleKeyUp,
+ onKeydown: handleKeyDown,
+ onClick: handleClick2,
+ onMousedown: () => {
+ on("selectstart", window, (e) => {
+ e.preventDefault();
+ }, {
+ once: true
+ });
+ }
+ }, h("div", {
+ class: `${mergedClsPrefix}-checkbox-box-wrapper`
+ }, " ", h("div", {
+ class: `${mergedClsPrefix}-checkbox-box`
+ }, h(NIconSwitchTransition, null, {
+ default: () => this.indeterminate ? h("div", {
+ key: "indeterminate",
+ class: `${mergedClsPrefix}-checkbox-icon`
+ }, renderLineMark()) : h("div", {
+ key: "check",
+ class: `${mergedClsPrefix}-checkbox-icon`
+ }, renderCheckMark())
+ }), h("div", {
+ class: `${mergedClsPrefix}-checkbox-box__border`
+ }))), labelNode);
+ }
+});
+const codeDark = {
+ name: "Code",
+ common: derived$1,
+ self(vars) {
+ const {
+ textColor2,
+ fontSize: fontSize2,
+ fontWeightStrong,
+ textColor3
+ } = vars;
+ return {
+ textColor: textColor2,
+ fontSize: fontSize2,
+ fontWeightStrong,
+ // extracted from hljs atom-one-dark.scss
+ "mono-3": "#5c6370",
+ "hue-1": "#56b6c2",
+ "hue-2": "#61aeee",
+ "hue-3": "#c678dd",
+ "hue-4": "#98c379",
+ "hue-5": "#e06c75",
+ "hue-5-2": "#be5046",
+ "hue-6": "#d19a66",
+ "hue-6-2": "#e6c07b",
+ // line-number styles
+ lineNumberTextColor: textColor3
+ };
+ }
+};
+function self$_(vars) {
+ const {
+ textColor2,
+ fontSize: fontSize2,
+ fontWeightStrong,
+ textColor3
+ } = vars;
+ return {
+ textColor: textColor2,
+ fontSize: fontSize2,
+ fontWeightStrong,
+ // extracted from hljs atom-one-light.scss
+ "mono-3": "#a0a1a7",
+ "hue-1": "#0184bb",
+ "hue-2": "#4078f2",
+ "hue-3": "#a626a4",
+ "hue-4": "#50a14f",
+ "hue-5": "#e45649",
+ "hue-5-2": "#c91243",
+ "hue-6": "#986801",
+ "hue-6-2": "#c18401",
+ // line-number styles
+ lineNumberTextColor: textColor3
+ };
+}
+const codeLight = {
+ name: "Code",
+ common: derived,
+ self: self$_
+};
+function self$Z(vars) {
+ const {
+ fontWeight,
+ textColor1,
+ textColor2,
+ textColorDisabled,
+ dividerColor,
+ fontSize: fontSize2
+ } = vars;
+ return {
+ titleFontSize: fontSize2,
+ titleFontWeight: fontWeight,
+ dividerColor,
+ titleTextColor: textColor1,
+ titleTextColorDisabled: textColorDisabled,
+ fontSize: fontSize2,
+ textColor: textColor2,
+ arrowColor: textColor2,
+ arrowColorDisabled: textColorDisabled,
+ itemMargin: "16px 0 0 0",
+ titlePadding: "16px 0 0 0"
+ };
+}
+const collapseLight = {
+ name: "Collapse",
+ common: derived,
+ self: self$Z
+};
+const collapseDark = {
+ name: "Collapse",
+ common: derived$1,
+ self: self$Z
+};
+function self$Y(vars) {
+ const {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ } = vars;
+ return {
+ bezier: cubicBezierEaseInOut2
+ };
+}
+const collapseTransitionLight = {
+ name: "CollapseTransition",
+ common: derived,
+ self: self$Y
+};
+const collapseTransitionDark = {
+ name: "CollapseTransition",
+ common: derived$1,
+ self: self$Y
+};
+function self$X(vars) {
+ const {
+ fontSize: fontSize2,
+ boxShadow2,
+ popoverColor,
+ textColor2,
+ borderRadius,
+ borderColor,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ dividerColor
+ } = vars;
+ return {
+ panelFontSize: fontSize2,
+ boxShadow: boxShadow2,
+ color: popoverColor,
+ textColor: textColor2,
+ borderRadius,
+ border: `1px solid ${borderColor}`,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ dividerColor
+ };
+}
+const colorPickerLight = createTheme({
+ name: "ColorPicker",
+ common: derived,
+ peers: {
+ Input: inputLight,
+ Button: buttonLight
+ },
+ self: self$X
+});
+const colorPickerDark = {
+ name: "ColorPicker",
+ common: derived$1,
+ peers: {
+ Input: inputDark,
+ Button: buttonDark
+ },
+ self: self$X
+};
+const configProviderProps = {
+ abstract: Boolean,
+ bordered: {
+ type: Boolean,
+ default: void 0
+ },
+ clsPrefix: String,
+ locale: Object,
+ dateLocale: Object,
+ namespace: String,
+ rtl: Array,
+ tag: {
+ type: String,
+ default: "div"
+ },
+ hljs: Object,
+ katex: Object,
+ theme: Object,
+ themeOverrides: Object,
+ componentOptions: Object,
+ icons: Object,
+ breakpoints: Object,
+ preflightStyleDisabled: Boolean,
+ styleMountTarget: Object,
+ inlineThemeDisabled: {
+ type: Boolean,
+ default: void 0
+ },
+ // deprecated
+ as: {
+ type: String,
+ validator: () => {
+ warn("config-provider", "`as` is deprecated, please use `tag` instead.");
+ return true;
+ },
+ default: void 0
+ }
+};
+const __unplugin_components_2 = /* @__PURE__ */ defineComponent({
+ name: "ConfigProvider",
+ alias: ["App"],
+ props: configProviderProps,
+ setup(props) {
+ const NConfigProvider = inject(configProviderInjectionKey, null);
+ const mergedThemeRef = computed(() => {
+ const {
+ theme
+ } = props;
+ if (theme === null) return void 0;
+ const inheritedTheme = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeRef.value;
+ return theme === void 0 ? inheritedTheme : inheritedTheme === void 0 ? theme : Object.assign({}, inheritedTheme, theme);
+ });
+ const mergedThemeOverridesRef = computed(() => {
+ const {
+ themeOverrides
+ } = props;
+ if (themeOverrides === null) return void 0;
+ if (themeOverrides === void 0) {
+ return NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeOverridesRef.value;
+ } else {
+ const inheritedThemeOverrides = NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedThemeOverridesRef.value;
+ if (inheritedThemeOverrides === void 0) {
+ return themeOverrides;
+ } else {
+ return merge$1({}, inheritedThemeOverrides, themeOverrides);
+ }
+ }
+ });
+ const mergedNamespaceRef = useMemo(() => {
+ const {
+ namespace: namespace2
+ } = props;
+ return namespace2 === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedNamespaceRef.value : namespace2;
+ });
+ const mergedBorderedRef = useMemo(() => {
+ const {
+ bordered
+ } = props;
+ return bordered === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedBorderedRef.value : bordered;
+ });
+ const mergedIconsRef = computed(() => {
+ const {
+ icons
+ } = props;
+ return icons === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedIconsRef.value : icons;
+ });
+ const mergedComponentPropsRef = computed(() => {
+ const {
+ componentOptions
+ } = props;
+ if (componentOptions !== void 0) return componentOptions;
+ return NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedComponentPropsRef.value;
+ });
+ const mergedClsPrefixRef = computed(() => {
+ const {
+ clsPrefix
+ } = props;
+ if (clsPrefix !== void 0) return clsPrefix;
+ if (NConfigProvider) return NConfigProvider.mergedClsPrefixRef.value;
+ return defaultClsPrefix;
+ });
+ const mergedRtlRef = computed(() => {
+ var _a;
+ const {
+ rtl
+ } = props;
+ if (rtl === void 0) {
+ return NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedRtlRef.value;
+ }
+ const rtlEnabledState = {};
+ for (const rtlInfo of rtl) {
+ rtlEnabledState[rtlInfo.name] = markRaw(rtlInfo);
+ (_a = rtlInfo.peers) === null || _a === void 0 ? void 0 : _a.forEach((peerRtlInfo) => {
+ if (!(peerRtlInfo.name in rtlEnabledState)) {
+ rtlEnabledState[peerRtlInfo.name] = markRaw(peerRtlInfo);
+ }
+ });
+ }
+ return rtlEnabledState;
+ });
+ const mergedBreakpointsRef = computed(() => {
+ return props.breakpoints || (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedBreakpointsRef.value);
+ });
+ const inlineThemeDisabled = props.inlineThemeDisabled || (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.inlineThemeDisabled);
+ const preflightStyleDisabled = props.preflightStyleDisabled || (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.preflightStyleDisabled);
+ const styleMountTarget = props.styleMountTarget || (NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.styleMountTarget);
+ const mergedThemeHashRef = computed(() => {
+ const {
+ value: theme
+ } = mergedThemeRef;
+ const {
+ value: mergedThemeOverrides
+ } = mergedThemeOverridesRef;
+ const hasThemeOverrides = mergedThemeOverrides && Object.keys(mergedThemeOverrides).length !== 0;
+ const themeName = theme === null || theme === void 0 ? void 0 : theme.name;
+ if (themeName) {
+ if (hasThemeOverrides) {
+ return `${themeName}-${murmur2(JSON.stringify(mergedThemeOverridesRef.value))}`;
+ }
+ return themeName;
+ } else {
+ if (hasThemeOverrides) {
+ return murmur2(JSON.stringify(mergedThemeOverridesRef.value));
+ }
+ return "";
+ }
+ });
+ provide(configProviderInjectionKey, {
+ mergedThemeHashRef,
+ mergedBreakpointsRef,
+ mergedRtlRef,
+ mergedIconsRef,
+ mergedComponentPropsRef,
+ mergedBorderedRef,
+ mergedNamespaceRef,
+ mergedClsPrefixRef,
+ mergedLocaleRef: computed(() => {
+ const {
+ locale
+ } = props;
+ if (locale === null) return void 0;
+ return locale === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedLocaleRef.value : locale;
+ }),
+ mergedDateLocaleRef: computed(() => {
+ const {
+ dateLocale
+ } = props;
+ if (dateLocale === null) return void 0;
+ return dateLocale === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedDateLocaleRef.value : dateLocale;
+ }),
+ mergedHljsRef: computed(() => {
+ const {
+ hljs
+ } = props;
+ return hljs === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedHljsRef.value : hljs;
+ }),
+ mergedKatexRef: computed(() => {
+ const {
+ katex
+ } = props;
+ return katex === void 0 ? NConfigProvider === null || NConfigProvider === void 0 ? void 0 : NConfigProvider.mergedKatexRef.value : katex;
+ }),
+ mergedThemeRef,
+ mergedThemeOverridesRef,
+ inlineThemeDisabled: inlineThemeDisabled || false,
+ preflightStyleDisabled: preflightStyleDisabled || false,
+ styleMountTarget
+ });
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedBordered: mergedBorderedRef,
+ mergedNamespace: mergedNamespaceRef,
+ mergedTheme: mergedThemeRef,
+ mergedThemeOverrides: mergedThemeOverridesRef
+ };
+ },
+ render() {
+ var _a, _b, _c, _d;
+ return !this.abstract ? h(this.as || this.tag, {
+ class: `${this.mergedClsPrefix || defaultClsPrefix}-config-provider`
+ }, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a)) : (_d = (_c = this.$slots).default) === null || _d === void 0 ? void 0 : _d.call(_c);
+ }
+});
+const popselect = {
+ name: "Popselect",
+ common: derived$1,
+ peers: {
+ Popover: popoverDark,
+ InternalSelectMenu: internalSelectMenuDark
+ }
+};
+function self$W(vars) {
+ const {
+ boxShadow2
+ } = vars;
+ return {
+ menuBoxShadow: boxShadow2
+ };
+}
+const popselectLight = createTheme({
+ name: "Popselect",
+ common: derived,
+ peers: {
+ Popover: popoverLight,
+ InternalSelectMenu: internalSelectMenuLight
+ },
+ self: self$W
+});
+function self$V(vars) {
+ const {
+ boxShadow2
+ } = vars;
+ return {
+ menuBoxShadow: boxShadow2
+ };
+}
+const selectLight = createTheme({
+ name: "Select",
+ common: derived,
+ peers: {
+ InternalSelection: internalSelectionLight,
+ InternalSelectMenu: internalSelectMenuLight
+ },
+ self: self$V
+});
+const selectDark = {
+ name: "Select",
+ common: derived$1,
+ peers: {
+ InternalSelection: internalSelectionDark,
+ InternalSelectMenu: internalSelectMenuDark
+ },
+ self: self$V
+};
+const commonVariables$b = {
+ itemPaddingSmall: "0 4px",
+ itemMarginSmall: "0 0 0 8px",
+ itemMarginSmallRtl: "0 8px 0 0",
+ itemPaddingMedium: "0 4px",
+ itemMarginMedium: "0 0 0 8px",
+ itemMarginMediumRtl: "0 8px 0 0",
+ itemPaddingLarge: "0 4px",
+ itemMarginLarge: "0 0 0 8px",
+ itemMarginLargeRtl: "0 8px 0 0",
+ buttonIconSizeSmall: "14px",
+ buttonIconSizeMedium: "16px",
+ buttonIconSizeLarge: "18px",
+ inputWidthSmall: "60px",
+ selectWidthSmall: "unset",
+ inputMarginSmall: "0 0 0 8px",
+ inputMarginSmallRtl: "0 8px 0 0",
+ selectMarginSmall: "0 0 0 8px",
+ prefixMarginSmall: "0 8px 0 0",
+ suffixMarginSmall: "0 0 0 8px",
+ inputWidthMedium: "60px",
+ selectWidthMedium: "unset",
+ inputMarginMedium: "0 0 0 8px",
+ inputMarginMediumRtl: "0 8px 0 0",
+ selectMarginMedium: "0 0 0 8px",
+ prefixMarginMedium: "0 8px 0 0",
+ suffixMarginMedium: "0 0 0 8px",
+ inputWidthLarge: "60px",
+ selectWidthLarge: "unset",
+ inputMarginLarge: "0 0 0 8px",
+ inputMarginLargeRtl: "0 8px 0 0",
+ selectMarginLarge: "0 0 0 8px",
+ prefixMarginLarge: "0 8px 0 0",
+ suffixMarginLarge: "0 0 0 8px"
+};
+function self$U(vars) {
+ const {
+ textColor2,
+ primaryColor,
+ primaryColorHover,
+ primaryColorPressed,
+ inputColorDisabled,
+ textColorDisabled,
+ borderColor,
+ borderRadius,
+ // item font size
+ fontSizeTiny,
+ fontSizeSmall,
+ fontSizeMedium,
+ // item size
+ heightTiny,
+ heightSmall,
+ heightMedium
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$b), {
+ buttonColor: "#0000",
+ buttonColorHover: "#0000",
+ buttonColorPressed: "#0000",
+ buttonBorder: `1px solid ${borderColor}`,
+ buttonBorderHover: `1px solid ${borderColor}`,
+ buttonBorderPressed: `1px solid ${borderColor}`,
+ buttonIconColor: textColor2,
+ buttonIconColorHover: textColor2,
+ buttonIconColorPressed: textColor2,
+ itemTextColor: textColor2,
+ itemTextColorHover: primaryColorHover,
+ itemTextColorPressed: primaryColorPressed,
+ itemTextColorActive: primaryColor,
+ itemTextColorDisabled: textColorDisabled,
+ itemColor: "#0000",
+ itemColorHover: "#0000",
+ itemColorPressed: "#0000",
+ itemColorActive: "#0000",
+ itemColorActiveHover: "#0000",
+ itemColorDisabled: inputColorDisabled,
+ itemBorder: "1px solid #0000",
+ itemBorderHover: "1px solid #0000",
+ itemBorderPressed: "1px solid #0000",
+ itemBorderActive: `1px solid ${primaryColor}`,
+ itemBorderDisabled: `1px solid ${borderColor}`,
+ itemBorderRadius: borderRadius,
+ itemSizeSmall: heightTiny,
+ itemSizeMedium: heightSmall,
+ itemSizeLarge: heightMedium,
+ itemFontSizeSmall: fontSizeTiny,
+ itemFontSizeMedium: fontSizeSmall,
+ itemFontSizeLarge: fontSizeMedium,
+ jumperFontSizeSmall: fontSizeTiny,
+ jumperFontSizeMedium: fontSizeSmall,
+ jumperFontSizeLarge: fontSizeMedium,
+ jumperTextColor: textColor2,
+ jumperTextColorDisabled: textColorDisabled
+ });
+}
+const paginationLight = createTheme({
+ name: "Pagination",
+ common: derived,
+ peers: {
+ Select: selectLight,
+ Input: inputLight,
+ Popselect: popselectLight
+ },
+ self: self$U
+});
+const paginationDark = {
+ name: "Pagination",
+ common: derived$1,
+ peers: {
+ Select: selectDark,
+ Input: inputDark,
+ Popselect: popselect
+ },
+ self(vars) {
+ const {
+ primaryColor,
+ opacity3
+ } = vars;
+ const borderColorActive = changeColor(primaryColor, {
+ alpha: Number(opacity3)
+ });
+ const commonSelf = self$U(vars);
+ commonSelf.itemBorderActive = `1px solid ${borderColorActive}`;
+ commonSelf.itemBorderDisabled = "1px solid #0000";
+ return commonSelf;
+ }
+};
+const commonVariables$a = {
+ padding: "4px 0",
+ optionIconSizeSmall: "14px",
+ optionIconSizeMedium: "16px",
+ optionIconSizeLarge: "16px",
+ optionIconSizeHuge: "18px",
+ optionSuffixWidthSmall: "14px",
+ optionSuffixWidthMedium: "14px",
+ optionSuffixWidthLarge: "16px",
+ optionSuffixWidthHuge: "16px",
+ optionIconSuffixWidthSmall: "32px",
+ optionIconSuffixWidthMedium: "32px",
+ optionIconSuffixWidthLarge: "36px",
+ optionIconSuffixWidthHuge: "36px",
+ optionPrefixWidthSmall: "14px",
+ optionPrefixWidthMedium: "14px",
+ optionPrefixWidthLarge: "16px",
+ optionPrefixWidthHuge: "16px",
+ optionIconPrefixWidthSmall: "36px",
+ optionIconPrefixWidthMedium: "36px",
+ optionIconPrefixWidthLarge: "40px",
+ optionIconPrefixWidthHuge: "40px"
+};
+function self$T(vars) {
+ const {
+ primaryColor,
+ textColor2,
+ dividerColor,
+ hoverColor,
+ popoverColor,
+ invertedColor,
+ borderRadius,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ fontSizeHuge,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ heightHuge,
+ textColor3,
+ opacityDisabled
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$a), {
+ optionHeightSmall: heightSmall,
+ optionHeightMedium: heightMedium,
+ optionHeightLarge: heightLarge,
+ optionHeightHuge: heightHuge,
+ borderRadius,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ fontSizeHuge,
+ // non-inverted
+ optionTextColor: textColor2,
+ optionTextColorHover: textColor2,
+ optionTextColorActive: primaryColor,
+ optionTextColorChildActive: primaryColor,
+ color: popoverColor,
+ dividerColor,
+ suffixColor: textColor2,
+ prefixColor: textColor2,
+ optionColorHover: hoverColor,
+ optionColorActive: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ groupHeaderTextColor: textColor3,
+ // inverted
+ optionTextColorInverted: "#BBB",
+ optionTextColorHoverInverted: "#FFF",
+ optionTextColorActiveInverted: "#FFF",
+ optionTextColorChildActiveInverted: "#FFF",
+ colorInverted: invertedColor,
+ dividerColorInverted: "#BBB",
+ suffixColorInverted: "#BBB",
+ prefixColorInverted: "#BBB",
+ optionColorHoverInverted: primaryColor,
+ optionColorActiveInverted: primaryColor,
+ groupHeaderTextColorInverted: "#AAA",
+ optionOpacityDisabled: opacityDisabled
+ });
+}
+const dropdownLight = createTheme({
+ name: "Dropdown",
+ common: derived,
+ peers: {
+ Popover: popoverLight
+ },
+ self: self$T
+});
+const dropdownDark = {
+ name: "Dropdown",
+ common: derived$1,
+ peers: {
+ Popover: popoverDark
+ },
+ self(vars) {
+ const {
+ primaryColorSuppl,
+ primaryColor,
+ popoverColor
+ } = vars;
+ const commonSelf = self$T(vars);
+ commonSelf.colorInverted = popoverColor;
+ commonSelf.optionColorActive = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ commonSelf.optionColorActiveInverted = primaryColorSuppl;
+ commonSelf.optionColorHoverInverted = primaryColorSuppl;
+ return commonSelf;
+ }
+};
+const commonVars$9 = {
+ padding: "8px 14px"
+};
+const tooltipDark = {
+ name: "Tooltip",
+ common: derived$1,
+ peers: {
+ Popover: popoverDark
+ },
+ self(vars) {
+ const {
+ borderRadius,
+ boxShadow2,
+ popoverColor,
+ textColor2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$9), {
+ borderRadius,
+ boxShadow: boxShadow2,
+ color: popoverColor,
+ textColor: textColor2
+ });
+ }
+};
+function self$S(vars) {
+ const {
+ borderRadius,
+ boxShadow2,
+ baseColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$9), {
+ borderRadius,
+ boxShadow: boxShadow2,
+ color: composite(baseColor, "rgba(0, 0, 0, .85)"),
+ textColor: baseColor
+ });
+}
+const tooltipLight = createTheme({
+ name: "Tooltip",
+ common: derived,
+ peers: {
+ Popover: popoverLight
+ },
+ self: self$S
+});
+const ellipsisDark = {
+ name: "Ellipsis",
+ common: derived$1,
+ peers: {
+ Tooltip: tooltipDark
+ }
+};
+const ellipsisLight = createTheme({
+ name: "Ellipsis",
+ common: derived,
+ peers: {
+ Tooltip: tooltipLight
+ }
+});
+const commonVariables$9 = {
+ radioSizeSmall: "14px",
+ radioSizeMedium: "16px",
+ radioSizeLarge: "18px",
+ labelPadding: "0 8px",
+ labelFontWeight: "400"
+};
+const radioDark = {
+ name: "Radio",
+ common: derived$1,
+ self(vars) {
+ const {
+ borderColor,
+ primaryColor,
+ baseColor,
+ textColorDisabled,
+ inputColorDisabled,
+ textColor2,
+ opacityDisabled,
+ borderRadius,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ lineHeight: lineHeight2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$9), {
+ labelLineHeight: lineHeight2,
+ buttonHeightSmall: heightSmall,
+ buttonHeightMedium: heightMedium,
+ buttonHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ boxShadow: `inset 0 0 0 1px ${borderColor}`,
+ boxShadowActive: `inset 0 0 0 1px ${primaryColor}`,
+ boxShadowFocus: `inset 0 0 0 1px ${primaryColor}, 0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ boxShadowHover: `inset 0 0 0 1px ${primaryColor}`,
+ boxShadowDisabled: `inset 0 0 0 1px ${borderColor}`,
+ color: "#0000",
+ colorDisabled: inputColorDisabled,
+ colorActive: "#0000",
+ textColor: textColor2,
+ textColorDisabled,
+ dotColorActive: primaryColor,
+ dotColorDisabled: borderColor,
+ buttonBorderColor: borderColor,
+ buttonBorderColorActive: primaryColor,
+ buttonBorderColorHover: primaryColor,
+ buttonColor: "#0000",
+ buttonColorActive: primaryColor,
+ buttonTextColor: textColor2,
+ buttonTextColorActive: baseColor,
+ buttonTextColorHover: primaryColor,
+ opacityDisabled,
+ buttonBoxShadowFocus: `inset 0 0 0 1px ${primaryColor}, 0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ buttonBoxShadowHover: `inset 0 0 0 1px ${primaryColor}`,
+ buttonBoxShadow: "inset 0 0 0 1px #0000",
+ buttonBorderRadius: borderRadius
+ });
+ }
+};
+function self$R(vars) {
+ const {
+ borderColor,
+ primaryColor,
+ baseColor,
+ textColorDisabled,
+ inputColorDisabled,
+ textColor2,
+ opacityDisabled,
+ borderRadius,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ lineHeight: lineHeight2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$9), {
+ labelLineHeight: lineHeight2,
+ buttonHeightSmall: heightSmall,
+ buttonHeightMedium: heightMedium,
+ buttonHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ boxShadow: `inset 0 0 0 1px ${borderColor}`,
+ boxShadowActive: `inset 0 0 0 1px ${primaryColor}`,
+ boxShadowFocus: `inset 0 0 0 1px ${primaryColor}, 0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.2
+ })}`,
+ boxShadowHover: `inset 0 0 0 1px ${primaryColor}`,
+ boxShadowDisabled: `inset 0 0 0 1px ${borderColor}`,
+ color: baseColor,
+ colorDisabled: inputColorDisabled,
+ colorActive: "#0000",
+ textColor: textColor2,
+ textColorDisabled,
+ dotColorActive: primaryColor,
+ dotColorDisabled: borderColor,
+ buttonBorderColor: borderColor,
+ buttonBorderColorActive: primaryColor,
+ buttonBorderColorHover: borderColor,
+ buttonColor: baseColor,
+ buttonColorActive: baseColor,
+ buttonTextColor: textColor2,
+ buttonTextColorActive: primaryColor,
+ buttonTextColorHover: primaryColor,
+ opacityDisabled,
+ buttonBoxShadowFocus: `inset 0 0 0 1px ${primaryColor}, 0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`,
+ buttonBoxShadowHover: "inset 0 0 0 1px #0000",
+ buttonBoxShadow: "inset 0 0 0 1px #0000",
+ buttonBorderRadius: borderRadius
+ });
+}
+const radioLight = {
+ name: "Radio",
+ common: derived,
+ self: self$R
+};
+const commonVariables$8 = {
+ thPaddingSmall: "8px",
+ thPaddingMedium: "12px",
+ thPaddingLarge: "12px",
+ tdPaddingSmall: "8px",
+ tdPaddingMedium: "12px",
+ tdPaddingLarge: "12px",
+ sorterSize: "15px",
+ resizableContainerSize: "8px",
+ resizableSize: "2px",
+ filterSize: "15px",
+ paginationMargin: "12px 0 0 0",
+ emptyPadding: "48px 0",
+ actionPadding: "8px 12px",
+ actionButtonMargin: "0 8px 0 0"
+};
+function self$Q(vars) {
+ const {
+ cardColor,
+ modalColor,
+ popoverColor,
+ textColor2,
+ textColor1,
+ tableHeaderColor,
+ tableColorHover,
+ iconColor,
+ primaryColor,
+ fontWeightStrong,
+ borderRadius,
+ lineHeight: lineHeight2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ dividerColor,
+ heightSmall,
+ opacityDisabled,
+ tableColorStriped
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$8), {
+ actionDividerColor: dividerColor,
+ lineHeight: lineHeight2,
+ borderRadius,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderColor: composite(cardColor, dividerColor),
+ tdColorHover: composite(cardColor, tableColorHover),
+ tdColorSorting: composite(cardColor, tableColorHover),
+ tdColorStriped: composite(cardColor, tableColorStriped),
+ thColor: composite(cardColor, tableHeaderColor),
+ thColorHover: composite(composite(cardColor, tableHeaderColor), tableColorHover),
+ thColorSorting: composite(composite(cardColor, tableHeaderColor), tableColorHover),
+ tdColor: cardColor,
+ tdTextColor: textColor2,
+ thTextColor: textColor1,
+ thFontWeight: fontWeightStrong,
+ thButtonColorHover: tableColorHover,
+ thIconColor: iconColor,
+ thIconColorActive: primaryColor,
+ // modal
+ borderColorModal: composite(modalColor, dividerColor),
+ tdColorHoverModal: composite(modalColor, tableColorHover),
+ tdColorSortingModal: composite(modalColor, tableColorHover),
+ tdColorStripedModal: composite(modalColor, tableColorStriped),
+ thColorModal: composite(modalColor, tableHeaderColor),
+ thColorHoverModal: composite(composite(modalColor, tableHeaderColor), tableColorHover),
+ thColorSortingModal: composite(composite(modalColor, tableHeaderColor), tableColorHover),
+ tdColorModal: modalColor,
+ // popover
+ borderColorPopover: composite(popoverColor, dividerColor),
+ tdColorHoverPopover: composite(popoverColor, tableColorHover),
+ tdColorSortingPopover: composite(popoverColor, tableColorHover),
+ tdColorStripedPopover: composite(popoverColor, tableColorStriped),
+ thColorPopover: composite(popoverColor, tableHeaderColor),
+ thColorHoverPopover: composite(composite(popoverColor, tableHeaderColor), tableColorHover),
+ thColorSortingPopover: composite(composite(popoverColor, tableHeaderColor), tableColorHover),
+ tdColorPopover: popoverColor,
+ boxShadowBefore: "inset -12px 0 8px -12px rgba(0, 0, 0, .18)",
+ boxShadowAfter: "inset 12px 0 8px -12px rgba(0, 0, 0, .18)",
+ // loading
+ loadingColor: primaryColor,
+ loadingSize: heightSmall,
+ opacityLoading: opacityDisabled
+ });
+}
+const dataTableLight = createTheme({
+ name: "DataTable",
+ common: derived,
+ peers: {
+ Button: buttonLight,
+ Checkbox: checkboxLight,
+ Radio: radioLight,
+ Pagination: paginationLight,
+ Scrollbar: scrollbarLight,
+ Empty: emptyLight,
+ Popover: popoverLight,
+ Ellipsis: ellipsisLight,
+ Dropdown: dropdownLight
+ },
+ self: self$Q
+});
+const dataTableDark = {
+ name: "DataTable",
+ common: derived$1,
+ peers: {
+ Button: buttonDark,
+ Checkbox: checkboxDark,
+ Radio: radioDark,
+ Pagination: paginationDark,
+ Scrollbar: scrollbarDark,
+ Empty: emptyDark,
+ Popover: popoverDark,
+ Ellipsis: ellipsisDark,
+ Dropdown: dropdownDark
+ },
+ self(vars) {
+ const commonSelf = self$Q(vars);
+ commonSelf.boxShadowAfter = "inset 12px 0 8px -12px rgba(0, 0, 0, .36)";
+ commonSelf.boxShadowBefore = "inset -12px 0 8px -12px rgba(0, 0, 0, .36)";
+ return commonSelf;
+ }
+};
+function self$P(vars) {
+ const {
+ textColorBase,
+ opacity1,
+ opacity2,
+ opacity3,
+ opacity4,
+ opacity5
+ } = vars;
+ return {
+ color: textColorBase,
+ opacity1Depth: opacity1,
+ opacity2Depth: opacity2,
+ opacity3Depth: opacity3,
+ opacity4Depth: opacity4,
+ opacity5Depth: opacity5
+ };
+}
+const iconLight = {
+ name: "Icon",
+ common: derived,
+ self: self$P
+};
+const iconDark$1 = {
+ name: "Icon",
+ common: derived$1,
+ self: self$P
+};
+const commonVars$8 = {
+ itemFontSize: "12px",
+ itemHeight: "36px",
+ itemWidth: "52px",
+ panelActionPadding: "8px 0"
+};
+function self$O(vars) {
+ const {
+ popoverColor,
+ textColor2,
+ primaryColor,
+ hoverColor,
+ dividerColor,
+ opacityDisabled,
+ boxShadow2,
+ borderRadius,
+ iconColor,
+ iconColorDisabled
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$8), {
+ panelColor: popoverColor,
+ panelBoxShadow: boxShadow2,
+ panelDividerColor: dividerColor,
+ itemTextColor: textColor2,
+ itemTextColorActive: primaryColor,
+ itemColorHover: hoverColor,
+ itemOpacityDisabled: opacityDisabled,
+ itemBorderRadius: borderRadius,
+ borderRadius,
+ iconColor,
+ iconColorDisabled
+ });
+}
+const timePickerLight = createTheme({
+ name: "TimePicker",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight,
+ Button: buttonLight,
+ Input: inputLight
+ },
+ self: self$O
+});
+const timePickerDark = {
+ name: "TimePicker",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark,
+ Button: buttonDark,
+ Input: inputDark
+ },
+ self: self$O
+};
+const commonVars$7 = {
+ itemSize: "24px",
+ itemCellWidth: "38px",
+ itemCellHeight: "32px",
+ scrollItemWidth: "80px",
+ scrollItemHeight: "40px",
+ panelExtraFooterPadding: "8px 12px",
+ panelActionPadding: "8px 12px",
+ calendarTitlePadding: "0",
+ calendarTitleHeight: "28px",
+ arrowSize: "14px",
+ panelHeaderPadding: "8px 12px",
+ calendarDaysHeight: "32px",
+ calendarTitleGridTempateColumns: "28px 28px 1fr 28px 28px",
+ // type
+ calendarLeftPaddingDate: "6px 12px 4px 12px",
+ calendarLeftPaddingDatetime: "4px 12px",
+ calendarLeftPaddingDaterange: "6px 12px 4px 12px",
+ calendarLeftPaddingDatetimerange: "4px 12px",
+ calendarLeftPaddingMonth: "0",
+ // TODO: make it actually effective
+ calendarLeftPaddingYear: "0",
+ calendarLeftPaddingQuarter: "0",
+ calendarLeftPaddingMonthrange: "0",
+ calendarLeftPaddingQuarterrange: "0",
+ calendarLeftPaddingYearrange: "0",
+ calendarLeftPaddingWeek: "6px 12px 4px 12px",
+ calendarRightPaddingDate: "6px 12px 4px 12px",
+ calendarRightPaddingDatetime: "4px 12px",
+ calendarRightPaddingDaterange: "6px 12px 4px 12px",
+ calendarRightPaddingDatetimerange: "4px 12px",
+ calendarRightPaddingMonth: "0",
+ calendarRightPaddingYear: "0",
+ calendarRightPaddingQuarter: "0",
+ calendarRightPaddingMonthrange: "0",
+ calendarRightPaddingQuarterrange: "0",
+ calendarRightPaddingYearrange: "0",
+ calendarRightPaddingWeek: "0"
+};
+function self$N(vars) {
+ const {
+ hoverColor,
+ fontSize: fontSize2,
+ textColor2,
+ textColorDisabled,
+ popoverColor,
+ primaryColor,
+ borderRadiusSmall,
+ iconColor,
+ iconColorDisabled,
+ textColor1,
+ dividerColor,
+ boxShadow2,
+ borderRadius,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$7), {
+ itemFontSize: fontSize2,
+ calendarDaysFontSize: fontSize2,
+ calendarTitleFontSize: fontSize2,
+ itemTextColor: textColor2,
+ itemTextColorDisabled: textColorDisabled,
+ itemTextColorActive: popoverColor,
+ itemTextColorCurrent: primaryColor,
+ itemColorIncluded: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ itemColorHover: hoverColor,
+ itemColorDisabled: hoverColor,
+ itemColorActive: primaryColor,
+ itemBorderRadius: borderRadiusSmall,
+ panelColor: popoverColor,
+ panelTextColor: textColor2,
+ arrowColor: iconColor,
+ calendarTitleTextColor: textColor1,
+ calendarTitleColorHover: hoverColor,
+ calendarDaysTextColor: textColor2,
+ panelHeaderDividerColor: dividerColor,
+ calendarDaysDividerColor: dividerColor,
+ calendarDividerColor: dividerColor,
+ panelActionDividerColor: dividerColor,
+ panelBoxShadow: boxShadow2,
+ panelBorderRadius: borderRadius,
+ calendarTitleFontWeight: fontWeightStrong,
+ scrollItemBorderRadius: borderRadius,
+ iconColor,
+ iconColorDisabled
+ });
+}
+const datePickerLight = createTheme({
+ name: "DatePicker",
+ common: derived,
+ peers: {
+ Input: inputLight,
+ Button: buttonLight,
+ TimePicker: timePickerLight,
+ Scrollbar: scrollbarLight
+ },
+ self: self$N
+});
+const datePickerDark = {
+ name: "DatePicker",
+ common: derived$1,
+ peers: {
+ Input: inputDark,
+ Button: buttonDark,
+ TimePicker: timePickerDark,
+ Scrollbar: scrollbarDark
+ },
+ self(vars) {
+ const {
+ popoverColor,
+ hoverColor,
+ primaryColor
+ } = vars;
+ const commonSelf = self$N(vars);
+ commonSelf.itemColorDisabled = composite(popoverColor, hoverColor);
+ commonSelf.itemColorIncluded = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ commonSelf.itemColorHover = composite(popoverColor, hoverColor);
+ return commonSelf;
+ }
+};
+const commonVariables$7 = {
+ thPaddingBorderedSmall: "8px 12px",
+ thPaddingBorderedMedium: "12px 16px",
+ thPaddingBorderedLarge: "16px 24px",
+ thPaddingSmall: "0",
+ thPaddingMedium: "0",
+ thPaddingLarge: "0",
+ tdPaddingBorderedSmall: "8px 12px",
+ tdPaddingBorderedMedium: "12px 16px",
+ tdPaddingBorderedLarge: "16px 24px",
+ tdPaddingSmall: "0 0 8px 0",
+ tdPaddingMedium: "0 0 12px 0",
+ tdPaddingLarge: "0 0 16px 0"
+};
+function self$M(vars) {
+ const {
+ tableHeaderColor,
+ textColor2,
+ textColor1,
+ cardColor,
+ modalColor,
+ popoverColor,
+ dividerColor,
+ borderRadius,
+ fontWeightStrong,
+ lineHeight: lineHeight2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$7), {
+ lineHeight: lineHeight2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ titleTextColor: textColor1,
+ thColor: composite(cardColor, tableHeaderColor),
+ thColorModal: composite(modalColor, tableHeaderColor),
+ thColorPopover: composite(popoverColor, tableHeaderColor),
+ thTextColor: textColor1,
+ thFontWeight: fontWeightStrong,
+ tdTextColor: textColor2,
+ tdColor: cardColor,
+ tdColorModal: modalColor,
+ tdColorPopover: popoverColor,
+ borderColor: composite(cardColor, dividerColor),
+ borderColorModal: composite(modalColor, dividerColor),
+ borderColorPopover: composite(popoverColor, dividerColor),
+ borderRadius
+ });
+}
+const descriptionsLight = {
+ name: "Descriptions",
+ common: derived,
+ self: self$M
+};
+const descriptionsDark = {
+ name: "Descriptions",
+ common: derived$1,
+ self: self$M
+};
+const dialogProviderInjectionKey = createInjectionKey("n-dialog-provider");
+const dialogApiInjectionKey = createInjectionKey("n-dialog-api");
+const dialogReactiveListInjectionKey = createInjectionKey("n-dialog-reactive-list");
+const commonVars$6 = {
+ titleFontSize: "18px",
+ padding: "16px 28px 20px 28px",
+ iconSize: "28px",
+ actionSpace: "12px",
+ contentMargin: "8px 0 16px 0",
+ iconMargin: "0 4px 0 0",
+ iconMarginIconTop: "4px 0 8px 0",
+ closeSize: "22px",
+ closeIconSize: "18px",
+ closeMargin: "20px 26px 0 0",
+ closeMarginIconTop: "10px 16px 0 0"
+};
+function self$L(vars) {
+ const {
+ textColor1,
+ textColor2,
+ modalColor,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ infoColor,
+ successColor,
+ warningColor,
+ errorColor,
+ primaryColor,
+ dividerColor,
+ borderRadius,
+ fontWeightStrong,
+ lineHeight: lineHeight2,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$6), {
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ border: `1px solid ${dividerColor}`,
+ titleTextColor: textColor1,
+ textColor: textColor2,
+ color: modalColor,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeBorderRadius: borderRadius,
+ iconColor: primaryColor,
+ iconColorInfo: infoColor,
+ iconColorSuccess: successColor,
+ iconColorWarning: warningColor,
+ iconColorError: errorColor,
+ borderRadius,
+ titleFontWeight: fontWeightStrong
+ });
+}
+const dialogLight = createTheme({
+ name: "Dialog",
+ common: derived,
+ peers: {
+ Button: buttonLight
+ },
+ self: self$L
+});
+const dialogDark = {
+ name: "Dialog",
+ common: derived$1,
+ peers: {
+ Button: buttonDark
+ },
+ self: self$L
+};
+const dialogProps = {
+ icon: Function,
+ type: {
+ type: String,
+ default: "default"
+ },
+ title: [String, Function],
+ closable: {
+ type: Boolean,
+ default: true
+ },
+ negativeText: String,
+ positiveText: String,
+ positiveButtonProps: Object,
+ negativeButtonProps: Object,
+ content: [String, Function],
+ action: Function,
+ showIcon: {
+ type: Boolean,
+ default: true
+ },
+ loading: Boolean,
+ bordered: Boolean,
+ iconPlacement: String,
+ titleClass: [String, Array],
+ titleStyle: [String, Object],
+ contentClass: [String, Array],
+ contentStyle: [String, Object],
+ actionClass: [String, Array],
+ actionStyle: [String, Object],
+ onPositiveClick: Function,
+ onNegativeClick: Function,
+ onClose: Function
+};
+const dialogPropKeys = keysOf(dialogProps);
+const style$3 = c([cB("dialog", `
+ --n-icon-margin: var(--n-icon-margin-top) var(--n-icon-margin-right) var(--n-icon-margin-bottom) var(--n-icon-margin-left);
+ word-break: break-word;
+ line-height: var(--n-line-height);
+ position: relative;
+ background: var(--n-color);
+ color: var(--n-text-color);
+ box-sizing: border-box;
+ margin: auto;
+ border-radius: var(--n-border-radius);
+ padding: var(--n-padding);
+ transition:
+ border-color .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ `, [cE("icon", {
+ color: "var(--n-icon-color)"
+}), cM("bordered", {
+ border: "var(--n-border)"
+}), cM("icon-top", [cE("close", {
+ margin: "var(--n-close-margin)"
+}), cE("icon", {
+ margin: "var(--n-icon-margin)"
+}), cE("content", {
+ textAlign: "center"
+}), cE("title", {
+ justifyContent: "center"
+}), cE("action", {
+ justifyContent: "center"
+})]), cM("icon-left", [cE("icon", {
+ margin: "var(--n-icon-margin)"
+}), cM("closable", [cE("title", `
+ padding-right: calc(var(--n-close-size) + 6px);
+ `)])]), cE("close", `
+ position: absolute;
+ right: 0;
+ top: 0;
+ margin: var(--n-close-margin);
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ z-index: 1;
+ `), cE("content", `
+ font-size: var(--n-font-size);
+ margin: var(--n-content-margin);
+ position: relative;
+ word-break: break-word;
+ `, [cM("last", "margin-bottom: 0;")]), cE("action", `
+ display: flex;
+ justify-content: flex-end;
+ `, [c("> *:not(:last-child)", `
+ margin-right: var(--n-action-space);
+ `)]), cE("icon", `
+ font-size: var(--n-icon-size);
+ transition: color .3s var(--n-bezier);
+ `), cE("title", `
+ transition: color .3s var(--n-bezier);
+ display: flex;
+ align-items: center;
+ font-size: var(--n-title-font-size);
+ font-weight: var(--n-title-font-weight);
+ color: var(--n-title-text-color);
+ `), cB("dialog-icon-container", `
+ display: flex;
+ justify-content: center;
+ `)]), insideModal(cB("dialog", `
+ width: 446px;
+ max-width: calc(100vw - 32px);
+ `)), cB("dialog", [asModal(`
+ width: 446px;
+ max-width: calc(100vw - 32px);
+ `)])]);
+const iconRenderMap$1 = {
+ default: () => h(InfoIcon, null),
+ info: () => h(InfoIcon, null),
+ success: () => h(SuccessIcon, null),
+ warning: () => h(WarningIcon, null),
+ error: () => h(ErrorIcon, null)
+};
+const NDialog = /* @__PURE__ */ defineComponent({
+ name: "Dialog",
+ alias: [
+ "NimbusConfirmCard",
+ // deprecated
+ "Confirm"
+ // deprecated
+ ],
+ props: Object.assign(Object.assign({}, useTheme.props), dialogProps),
+ setup(props) {
+ const {
+ mergedComponentPropsRef,
+ mergedClsPrefixRef,
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const rtlEnabledRef = useRtl("Dialog", mergedRtlRef, mergedClsPrefixRef);
+ const mergedIconPlacementRef = computed(() => {
+ var _a, _b;
+ const {
+ iconPlacement
+ } = props;
+ return iconPlacement || ((_b = (_a = mergedComponentPropsRef === null || mergedComponentPropsRef === void 0 ? void 0 : mergedComponentPropsRef.value) === null || _a === void 0 ? void 0 : _a.Dialog) === null || _b === void 0 ? void 0 : _b.iconPlacement) || "left";
+ });
+ function handlePositiveClick(e) {
+ const {
+ onPositiveClick
+ } = props;
+ if (onPositiveClick) onPositiveClick(e);
+ }
+ function handleNegativeClick(e) {
+ const {
+ onNegativeClick
+ } = props;
+ if (onNegativeClick) onNegativeClick(e);
+ }
+ function handleCloseClick() {
+ const {
+ onClose
+ } = props;
+ if (onClose) onClose();
+ }
+ const themeRef = useTheme("Dialog", "-dialog", style$3, dialogLight, props, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ type
+ } = props;
+ const iconPlacement = mergedIconPlacementRef.value;
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ },
+ self: {
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ border,
+ titleTextColor,
+ textColor,
+ color,
+ closeBorderRadius,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeIconSize,
+ borderRadius,
+ titleFontWeight,
+ titleFontSize,
+ padding,
+ iconSize,
+ actionSpace,
+ contentMargin,
+ closeSize,
+ [iconPlacement === "top" ? "iconMarginIconTop" : "iconMargin"]: iconMargin,
+ [iconPlacement === "top" ? "closeMarginIconTop" : "closeMargin"]: closeMargin,
+ [createKey("iconColor", type)]: iconColor
+ }
+ } = themeRef.value;
+ const iconMarginDiscrete = getMargin(iconMargin);
+ return {
+ "--n-font-size": fontSize2,
+ "--n-icon-color": iconColor,
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-close-margin": closeMargin,
+ "--n-icon-margin-top": iconMarginDiscrete.top,
+ "--n-icon-margin-right": iconMarginDiscrete.right,
+ "--n-icon-margin-bottom": iconMarginDiscrete.bottom,
+ "--n-icon-margin-left": iconMarginDiscrete.left,
+ "--n-icon-size": iconSize,
+ "--n-close-size": closeSize,
+ "--n-close-icon-size": closeIconSize,
+ "--n-close-border-radius": closeBorderRadius,
+ "--n-close-color-hover": closeColorHover,
+ "--n-close-color-pressed": closeColorPressed,
+ "--n-close-icon-color": closeIconColor,
+ "--n-close-icon-color-hover": closeIconColorHover,
+ "--n-close-icon-color-pressed": closeIconColorPressed,
+ "--n-color": color,
+ "--n-text-color": textColor,
+ "--n-border-radius": borderRadius,
+ "--n-padding": padding,
+ "--n-line-height": lineHeight2,
+ "--n-border": border,
+ "--n-content-margin": contentMargin,
+ "--n-title-font-size": titleFontSize,
+ "--n-title-font-weight": titleFontWeight,
+ "--n-title-text-color": titleTextColor,
+ "--n-action-space": actionSpace
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("dialog", computed(() => `${props.type[0]}${mergedIconPlacementRef.value[0]}`), cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ rtlEnabled: rtlEnabledRef,
+ mergedIconPlacement: mergedIconPlacementRef,
+ mergedTheme: themeRef,
+ handlePositiveClick,
+ handleNegativeClick,
+ handleCloseClick,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ var _a;
+ const {
+ bordered,
+ mergedIconPlacement,
+ cssVars,
+ closable,
+ showIcon,
+ title,
+ content,
+ action,
+ negativeText,
+ positiveText,
+ positiveButtonProps,
+ negativeButtonProps,
+ handlePositiveClick,
+ handleNegativeClick,
+ mergedTheme,
+ loading,
+ type,
+ mergedClsPrefix
+ } = this;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ const icon = showIcon ? h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix,
+ class: `${mergedClsPrefix}-dialog__icon`
+ }, {
+ default: () => resolveWrappedSlot(this.$slots.icon, (children) => children || (this.icon ? render(this.icon) : iconRenderMap$1[this.type]()))
+ }) : null;
+ const actionNode = resolveWrappedSlot(this.$slots.action, (children) => children || positiveText || negativeText || action ? h("div", {
+ class: [`${mergedClsPrefix}-dialog__action`, this.actionClass],
+ style: this.actionStyle
+ }, children || (action ? [render(action)] : [this.negativeText && h(Button, Object.assign({
+ theme: mergedTheme.peers.Button,
+ themeOverrides: mergedTheme.peerOverrides.Button,
+ ghost: true,
+ size: "small",
+ onClick: handleNegativeClick
+ }, negativeButtonProps), {
+ default: () => render(this.negativeText)
+ }), this.positiveText && h(Button, Object.assign({
+ theme: mergedTheme.peers.Button,
+ themeOverrides: mergedTheme.peerOverrides.Button,
+ size: "small",
+ type: type === "default" ? "primary" : type,
+ disabled: loading,
+ loading,
+ onClick: handlePositiveClick
+ }, positiveButtonProps), {
+ default: () => render(this.positiveText)
+ })])) : null);
+ return h("div", {
+ class: [`${mergedClsPrefix}-dialog`, this.themeClass, this.closable && `${mergedClsPrefix}-dialog--closable`, `${mergedClsPrefix}-dialog--icon-${mergedIconPlacement}`, bordered && `${mergedClsPrefix}-dialog--bordered`, this.rtlEnabled && `${mergedClsPrefix}-dialog--rtl`],
+ style: cssVars,
+ role: "dialog"
+ }, closable ? resolveWrappedSlot(this.$slots.close, (node) => {
+ const classNames = [`${mergedClsPrefix}-dialog__close`, this.rtlEnabled && `${mergedClsPrefix}-dialog--rtl`];
+ return node ? h("div", {
+ class: classNames
+ }, node) : h(NBaseClose, {
+ clsPrefix: mergedClsPrefix,
+ class: classNames,
+ onClick: this.handleCloseClick
+ });
+ }) : null, showIcon && mergedIconPlacement === "top" ? h("div", {
+ class: `${mergedClsPrefix}-dialog-icon-container`
+ }, icon) : null, h("div", {
+ class: [`${mergedClsPrefix}-dialog__title`, this.titleClass],
+ style: this.titleStyle
+ }, showIcon && mergedIconPlacement === "left" ? icon : null, resolveSlot(this.$slots.header, () => [render(title)])), h("div", {
+ class: [`${mergedClsPrefix}-dialog__content`, actionNode ? "" : `${mergedClsPrefix}-dialog__content--last`, this.contentClass],
+ style: this.contentStyle
+ }, resolveSlot(this.$slots.default, () => [render(content)])), actionNode);
+ }
+});
+function self$K(vars) {
+ const {
+ modalColor,
+ textColor2,
+ boxShadow3
+ } = vars;
+ return {
+ color: modalColor,
+ textColor: textColor2,
+ boxShadow: boxShadow3
+ };
+}
+const modalLight = createTheme({
+ name: "Modal",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight,
+ Dialog: dialogLight,
+ Card: cardLight
+ },
+ self: self$K
+});
+const modalDark = {
+ name: "Modal",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark,
+ Dialog: dialogDark,
+ Card: cardDark
+ },
+ self: self$K
+};
+const presetProps = Object.assign(Object.assign({}, cardBaseProps), dialogProps);
+const presetPropsKeys = keysOf(presetProps);
+const NModalBodyWrapper = /* @__PURE__ */ defineComponent({
+ name: "ModalBody",
+ inheritAttrs: false,
+ props: Object.assign(Object.assign({
+ show: {
+ type: Boolean,
+ required: true
+ },
+ preset: String,
+ displayDirective: {
+ type: String,
+ required: true
+ },
+ trapFocus: {
+ type: Boolean,
+ default: true
+ },
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ blockScroll: Boolean
+ }, presetProps), {
+ renderMask: Function,
+ // events
+ onClickoutside: Function,
+ onBeforeLeave: {
+ type: Function,
+ required: true
+ },
+ onAfterLeave: {
+ type: Function,
+ required: true
+ },
+ onPositiveClick: {
+ type: Function,
+ required: true
+ },
+ onNegativeClick: {
+ type: Function,
+ required: true
+ },
+ onClose: {
+ type: Function,
+ required: true
+ },
+ onAfterEnter: Function,
+ onEsc: Function
+ }),
+ setup(props) {
+ const bodyRef = ref(null);
+ const scrollbarRef = ref(null);
+ const displayedRef = ref(props.show);
+ const transformOriginXRef = ref(null);
+ const transformOriginYRef = ref(null);
+ watch(toRef(props, "show"), (value) => {
+ if (value) displayedRef.value = true;
+ });
+ useLockHtmlScroll(computed(() => props.blockScroll && displayedRef.value));
+ const NModal = inject(modalInjectionKey);
+ function styleTransformOrigin() {
+ if (NModal.transformOriginRef.value === "center") {
+ return "";
+ }
+ const {
+ value: transformOriginX
+ } = transformOriginXRef;
+ const {
+ value: transformOriginY
+ } = transformOriginYRef;
+ if (transformOriginX === null || transformOriginY === null) {
+ return "";
+ } else if (scrollbarRef.value) {
+ const scrollTop = scrollbarRef.value.containerScrollTop;
+ return `${transformOriginX}px ${transformOriginY + scrollTop}px`;
+ }
+ return "";
+ }
+ function syncTransformOrigin(el) {
+ if (NModal.transformOriginRef.value === "center") {
+ return;
+ }
+ const mousePosition = NModal.getMousePosition();
+ if (!mousePosition) {
+ return;
+ }
+ if (!scrollbarRef.value) return;
+ const scrollTop = scrollbarRef.value.containerScrollTop;
+ const {
+ offsetLeft,
+ offsetTop
+ } = el;
+ if (mousePosition) {
+ const top = mousePosition.y;
+ const left = mousePosition.x;
+ transformOriginXRef.value = -(offsetLeft - left);
+ transformOriginYRef.value = -(offsetTop - top - scrollTop);
+ }
+ el.style.transformOrigin = styleTransformOrigin();
+ }
+ function handleEnter(el) {
+ void nextTick(() => {
+ syncTransformOrigin(el);
+ });
+ }
+ function handleBeforeLeave(el) {
+ el.style.transformOrigin = styleTransformOrigin();
+ props.onBeforeLeave();
+ }
+ function handleAfterLeave() {
+ displayedRef.value = false;
+ transformOriginXRef.value = null;
+ transformOriginYRef.value = null;
+ props.onAfterLeave();
+ }
+ function handleCloseClick() {
+ const {
+ onClose
+ } = props;
+ if (onClose) {
+ onClose();
+ }
+ }
+ function handleNegativeClick() {
+ props.onNegativeClick();
+ }
+ function handlePositiveClick() {
+ props.onPositiveClick();
+ }
+ const childNodeRef = ref(null);
+ watch(childNodeRef, (node) => {
+ if (node) {
+ void nextTick(() => {
+ const el = node.el;
+ if (el && bodyRef.value !== el) {
+ bodyRef.value = el;
+ }
+ });
+ }
+ });
+ provide(modalBodyInjectionKey, bodyRef);
+ provide(drawerBodyInjectionKey, null);
+ provide(popoverBodyInjectionKey, null);
+ return {
+ mergedTheme: NModal.mergedThemeRef,
+ appear: NModal.appearRef,
+ isMounted: NModal.isMountedRef,
+ mergedClsPrefix: NModal.mergedClsPrefixRef,
+ bodyRef,
+ scrollbarRef,
+ displayed: displayedRef,
+ childNodeRef,
+ handlePositiveClick,
+ handleNegativeClick,
+ handleCloseClick,
+ handleAfterLeave,
+ handleBeforeLeave,
+ handleEnter
+ };
+ },
+ render() {
+ const {
+ $slots,
+ $attrs,
+ handleEnter,
+ handleAfterLeave,
+ handleBeforeLeave,
+ preset,
+ mergedClsPrefix
+ } = this;
+ let childNode = null;
+ if (!preset) {
+ childNode = getFirstSlotVNode($slots);
+ if (!childNode) {
+ warn("modal", "default slot is empty");
+ return;
+ }
+ childNode = cloneVNode(childNode);
+ childNode.props = mergeProps({
+ class: `${mergedClsPrefix}-modal`
+ }, $attrs, childNode.props || {});
+ }
+ return this.displayDirective === "show" || this.displayed || this.show ? withDirectives(h("div", {
+ role: "none",
+ class: `${mergedClsPrefix}-modal-body-wrapper`
+ }, h(Scrollbar$1, {
+ ref: "scrollbarRef",
+ theme: this.mergedTheme.peers.Scrollbar,
+ themeOverrides: this.mergedTheme.peerOverrides.Scrollbar,
+ contentClass: `${mergedClsPrefix}-modal-scroll-content`
+ }, {
+ default: () => {
+ var _a;
+ return [(_a = this.renderMask) === null || _a === void 0 ? void 0 : _a.call(this), h(FocusTrap, {
+ disabled: !this.trapFocus,
+ active: this.show,
+ onEsc: this.onEsc,
+ autoFocus: this.autoFocus
+ }, {
+ default: () => {
+ var _a2;
+ return h(Transition, {
+ name: "fade-in-scale-up-transition",
+ appear: (_a2 = this.appear) !== null && _a2 !== void 0 ? _a2 : this.isMounted,
+ onEnter: handleEnter,
+ onAfterEnter: this.onAfterEnter,
+ onAfterLeave: handleAfterLeave,
+ onBeforeLeave: handleBeforeLeave
+ }, {
+ default: () => {
+ const dirs = [[vShow, this.show]];
+ const {
+ onClickoutside
+ } = this;
+ if (onClickoutside) {
+ dirs.push([clickoutside, this.onClickoutside, void 0, {
+ capture: true
+ }]);
+ }
+ return withDirectives(this.preset === "confirm" || this.preset === "dialog" ? h(NDialog, Object.assign({}, this.$attrs, {
+ class: [`${mergedClsPrefix}-modal`, this.$attrs.class],
+ ref: "bodyRef",
+ theme: this.mergedTheme.peers.Dialog,
+ themeOverrides: this.mergedTheme.peerOverrides.Dialog
+ }, keep(this.$props, dialogPropKeys), {
+ "aria-modal": "true"
+ }), $slots) : this.preset === "card" ? h(NCard, Object.assign({}, this.$attrs, {
+ ref: "bodyRef",
+ class: [`${mergedClsPrefix}-modal`, this.$attrs.class],
+ theme: this.mergedTheme.peers.Card,
+ themeOverrides: this.mergedTheme.peerOverrides.Card
+ }, keep(this.$props, cardBasePropKeys), {
+ "aria-modal": "true",
+ role: "dialog"
+ }), $slots) : this.childNodeRef = childNode, dirs);
+ }
+ });
+ }
+ })];
+ }
+ })), [[vShow, this.displayDirective === "if" || this.displayed || this.show]]) : null;
+ }
+});
+const style$2 = c([cB("modal-container", `
+ position: fixed;
+ left: 0;
+ top: 0;
+ height: 0;
+ width: 0;
+ display: flex;
+ `), cB("modal-mask", `
+ position: fixed;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ background-color: rgba(0, 0, 0, .4);
+ `, [fadeInTransition({
+ enterDuration: ".25s",
+ leaveDuration: ".25s",
+ enterCubicBezier: "var(--n-bezier-ease-out)",
+ leaveCubicBezier: "var(--n-bezier-ease-out)"
+})]), cB("modal-body-wrapper", `
+ position: fixed;
+ left: 0;
+ right: 0;
+ top: 0;
+ bottom: 0;
+ overflow: visible;
+ `, [cB("modal-scroll-content", `
+ min-height: 100%;
+ display: flex;
+ position: relative;
+ `)]), cB("modal", `
+ position: relative;
+ align-self: center;
+ color: var(--n-text-color);
+ margin: auto;
+ box-shadow: var(--n-box-shadow);
+ `, [fadeInScaleUpTransition({
+ duration: ".25s",
+ enterScale: ".5"
+})])]);
+const modalProps = Object.assign(Object.assign(Object.assign(Object.assign({}, useTheme.props), {
+ show: Boolean,
+ unstableShowMask: {
+ type: Boolean,
+ default: true
+ },
+ maskClosable: {
+ type: Boolean,
+ default: true
+ },
+ preset: String,
+ to: [String, Object],
+ displayDirective: {
+ type: String,
+ default: "if"
+ },
+ transformOrigin: {
+ type: String,
+ default: "mouse"
+ },
+ zIndex: Number,
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ trapFocus: {
+ type: Boolean,
+ default: true
+ },
+ closeOnEsc: {
+ type: Boolean,
+ default: true
+ },
+ blockScroll: {
+ type: Boolean,
+ default: true
+ }
+}), presetProps), {
+ // events
+ onEsc: Function,
+ "onUpdate:show": [Function, Array],
+ onUpdateShow: [Function, Array],
+ onAfterEnter: Function,
+ onBeforeLeave: Function,
+ onAfterLeave: Function,
+ onClose: Function,
+ onPositiveClick: Function,
+ onNegativeClick: Function,
+ onMaskClick: Function,
+ // private
+ internalDialog: Boolean,
+ internalModal: Boolean,
+ internalAppear: {
+ type: Boolean,
+ default: void 0
+ },
+ // deprecated
+ overlayStyle: [String, Object],
+ onBeforeHide: Function,
+ onAfterHide: Function,
+ onHide: Function
+});
+const __unplugin_components_3 = /* @__PURE__ */ defineComponent({
+ name: "Modal",
+ inheritAttrs: false,
+ props: modalProps,
+ setup(props) {
+ const containerRef = ref(null);
+ const {
+ mergedClsPrefixRef,
+ namespaceRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Modal", "-modal", style$2, modalLight, props, mergedClsPrefixRef);
+ const clickedRef = useClicked(64);
+ const clickedPositionRef = useClickPosition();
+ const isMountedRef = isMounted();
+ const NDialogProvider2 = props.internalDialog ? inject(dialogProviderInjectionKey, null) : null;
+ const NModalProvider = props.internalModal ? inject(modalProviderInjectionKey, null) : null;
+ const isComposingRef2 = useIsComposing();
+ function doUpdateShow(show) {
+ const {
+ onUpdateShow,
+ "onUpdate:show": _onUpdateShow,
+ onHide
+ } = props;
+ if (onUpdateShow) call(onUpdateShow, show);
+ if (_onUpdateShow) call(_onUpdateShow, show);
+ if (onHide && !show) onHide(show);
+ }
+ function handleCloseClick() {
+ const {
+ onClose
+ } = props;
+ if (onClose) {
+ void Promise.resolve(onClose()).then((value) => {
+ if (value === false) return;
+ doUpdateShow(false);
+ });
+ } else {
+ doUpdateShow(false);
+ }
+ }
+ function handlePositiveClick() {
+ const {
+ onPositiveClick
+ } = props;
+ if (onPositiveClick) {
+ void Promise.resolve(onPositiveClick()).then((value) => {
+ if (value === false) return;
+ doUpdateShow(false);
+ });
+ } else {
+ doUpdateShow(false);
+ }
+ }
+ function handleNegativeClick() {
+ const {
+ onNegativeClick
+ } = props;
+ if (onNegativeClick) {
+ void Promise.resolve(onNegativeClick()).then((value) => {
+ if (value === false) return;
+ doUpdateShow(false);
+ });
+ } else {
+ doUpdateShow(false);
+ }
+ }
+ function handleBeforeLeave() {
+ const {
+ onBeforeLeave,
+ onBeforeHide
+ } = props;
+ if (onBeforeLeave) call(onBeforeLeave);
+ if (onBeforeHide) onBeforeHide();
+ }
+ function handleAfterLeave() {
+ const {
+ onAfterLeave,
+ onAfterHide
+ } = props;
+ if (onAfterLeave) call(onAfterLeave);
+ if (onAfterHide) onAfterHide();
+ }
+ function handleClickoutside(e) {
+ var _a;
+ const {
+ onMaskClick
+ } = props;
+ if (onMaskClick) {
+ onMaskClick(e);
+ }
+ if (props.maskClosable) {
+ if ((_a = containerRef.value) === null || _a === void 0 ? void 0 : _a.contains(getPreciseEventTarget(e))) {
+ doUpdateShow(false);
+ }
+ }
+ }
+ function handleEsc(e) {
+ var _a;
+ (_a = props.onEsc) === null || _a === void 0 ? void 0 : _a.call(props);
+ if (props.show && props.closeOnEsc && eventEffectNotPerformed(e)) {
+ if (!isComposingRef2.value) {
+ doUpdateShow(false);
+ }
+ }
+ }
+ provide(modalInjectionKey, {
+ getMousePosition: () => {
+ const mergedProvider = NDialogProvider2 || NModalProvider;
+ if (mergedProvider) {
+ const {
+ clickedRef: clickedRef2,
+ clickedPositionRef: clickedPositionRef2
+ } = mergedProvider;
+ if (clickedRef2.value && clickedPositionRef2.value) {
+ return clickedPositionRef2.value;
+ }
+ }
+ if (clickedRef.value) {
+ return clickedPositionRef.value;
+ }
+ return null;
+ },
+ mergedClsPrefixRef,
+ mergedThemeRef: themeRef,
+ isMountedRef,
+ appearRef: toRef(props, "internalAppear"),
+ transformOriginRef: toRef(props, "transformOrigin")
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ common: {
+ cubicBezierEaseOut: cubicBezierEaseOut2
+ },
+ self: {
+ boxShadow,
+ color,
+ textColor
+ }
+ } = themeRef.value;
+ return {
+ "--n-bezier-ease-out": cubicBezierEaseOut2,
+ "--n-box-shadow": boxShadow,
+ "--n-color": color,
+ "--n-text-color": textColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("theme-class", void 0, cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ namespace: namespaceRef,
+ isMounted: isMountedRef,
+ containerRef,
+ presetProps: computed(() => {
+ const pickedProps = keep(props, presetPropsKeys);
+ return pickedProps;
+ }),
+ handleEsc,
+ handleAfterLeave,
+ handleClickoutside,
+ handleBeforeLeave,
+ doUpdateShow,
+ handleNegativeClick,
+ handlePositiveClick,
+ handleCloseClick,
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const {
+ mergedClsPrefix
+ } = this;
+ return h(LazyTeleport, {
+ to: this.to,
+ show: this.show
+ }, {
+ default: () => {
+ var _a;
+ (_a = this.onRender) === null || _a === void 0 ? void 0 : _a.call(this);
+ const {
+ unstableShowMask
+ } = this;
+ return withDirectives(h("div", {
+ role: "none",
+ ref: "containerRef",
+ class: [`${mergedClsPrefix}-modal-container`, this.themeClass, this.namespace],
+ style: this.cssVars
+ }, h(NModalBodyWrapper, Object.assign({
+ style: this.overlayStyle
+ }, this.$attrs, {
+ ref: "bodyWrapper",
+ displayDirective: this.displayDirective,
+ show: this.show,
+ preset: this.preset,
+ autoFocus: this.autoFocus,
+ trapFocus: this.trapFocus,
+ blockScroll: this.blockScroll
+ }, this.presetProps, {
+ onEsc: this.handleEsc,
+ onClose: this.handleCloseClick,
+ onNegativeClick: this.handleNegativeClick,
+ onPositiveClick: this.handlePositiveClick,
+ onBeforeLeave: this.handleBeforeLeave,
+ onAfterEnter: this.onAfterEnter,
+ onAfterLeave: this.handleAfterLeave,
+ onClickoutside: unstableShowMask ? void 0 : this.handleClickoutside,
+ renderMask: unstableShowMask ? () => {
+ var _a2;
+ return h(Transition, {
+ name: "fade-in-transition",
+ key: "mask",
+ appear: (_a2 = this.internalAppear) !== null && _a2 !== void 0 ? _a2 : this.isMounted
+ }, {
+ default: () => {
+ return this.show ? h("div", {
+ "aria-hidden": true,
+ ref: "containerRef",
+ class: `${mergedClsPrefix}-modal-mask`,
+ onClick: this.handleClickoutside
+ }) : null;
+ }
+ });
+ } : void 0
+ }), this.$slots)), [[zindexable, {
+ zIndex: this.zIndex,
+ enabled: this.show
+ }]]);
+ }
+ });
+ }
+});
+const exposedDialogEnvProps = Object.assign(Object.assign({}, dialogProps), {
+ onAfterEnter: Function,
+ onAfterLeave: Function,
+ transformOrigin: String,
+ blockScroll: {
+ type: Boolean,
+ default: true
+ },
+ closeOnEsc: {
+ type: Boolean,
+ default: true
+ },
+ onEsc: Function,
+ autoFocus: {
+ type: Boolean,
+ default: true
+ },
+ internalStyle: [String, Object],
+ maskClosable: {
+ type: Boolean,
+ default: true
+ },
+ onPositiveClick: Function,
+ onNegativeClick: Function,
+ onClose: Function,
+ onMaskClick: Function
+});
+const NDialogEnvironment = /* @__PURE__ */ defineComponent({
+ name: "DialogEnvironment",
+ props: Object.assign(Object.assign({}, exposedDialogEnvProps), {
+ internalKey: {
+ type: String,
+ required: true
+ },
+ to: [String, Object],
+ // private
+ onInternalAfterLeave: {
+ type: Function,
+ required: true
+ }
+ }),
+ setup(props) {
+ const showRef = ref(true);
+ function handleAfterLeave() {
+ const {
+ onInternalAfterLeave,
+ internalKey,
+ onAfterLeave
+ } = props;
+ if (onInternalAfterLeave) onInternalAfterLeave(internalKey);
+ if (onAfterLeave) onAfterLeave();
+ }
+ function handlePositiveClick(e) {
+ const {
+ onPositiveClick
+ } = props;
+ if (onPositiveClick) {
+ void Promise.resolve(onPositiveClick(e)).then((result) => {
+ if (result === false) return;
+ hide();
+ });
+ } else {
+ hide();
+ }
+ }
+ function handleNegativeClick(e) {
+ const {
+ onNegativeClick
+ } = props;
+ if (onNegativeClick) {
+ void Promise.resolve(onNegativeClick(e)).then((result) => {
+ if (result === false) return;
+ hide();
+ });
+ } else {
+ hide();
+ }
+ }
+ function handleCloseClick() {
+ const {
+ onClose
+ } = props;
+ if (onClose) {
+ void Promise.resolve(onClose()).then((result) => {
+ if (result === false) return;
+ hide();
+ });
+ } else {
+ hide();
+ }
+ }
+ function handleMaskClick(e) {
+ const {
+ onMaskClick,
+ maskClosable
+ } = props;
+ if (onMaskClick) {
+ onMaskClick(e);
+ if (maskClosable) {
+ hide();
+ }
+ }
+ }
+ function handleEsc() {
+ const {
+ onEsc
+ } = props;
+ if (onEsc) {
+ onEsc();
+ }
+ }
+ function hide() {
+ showRef.value = false;
+ }
+ function handleUpdateShow(value) {
+ showRef.value = value;
+ }
+ return {
+ show: showRef,
+ hide,
+ handleUpdateShow,
+ handleAfterLeave,
+ handleCloseClick,
+ handleNegativeClick,
+ handlePositiveClick,
+ handleMaskClick,
+ handleEsc
+ };
+ },
+ render() {
+ const {
+ handlePositiveClick,
+ handleUpdateShow,
+ handleNegativeClick,
+ handleCloseClick,
+ handleAfterLeave,
+ handleMaskClick,
+ handleEsc,
+ to,
+ maskClosable,
+ show
+ } = this;
+ return h(__unplugin_components_3, {
+ show,
+ onUpdateShow: handleUpdateShow,
+ onMaskClick: handleMaskClick,
+ onEsc: handleEsc,
+ to,
+ maskClosable,
+ onAfterEnter: this.onAfterEnter,
+ onAfterLeave: handleAfterLeave,
+ closeOnEsc: this.closeOnEsc,
+ blockScroll: this.blockScroll,
+ autoFocus: this.autoFocus,
+ transformOrigin: this.transformOrigin,
+ internalAppear: true,
+ internalDialog: true
+ }, {
+ default: () => h(NDialog, Object.assign({}, keep(this.$props, dialogPropKeys), {
+ style: this.internalStyle,
+ onClose: handleCloseClick,
+ onNegativeClick: handleNegativeClick,
+ onPositiveClick: handlePositiveClick
+ }))
+ });
+ }
+});
+const dialogProviderProps = {
+ injectionKey: String,
+ to: [String, Object]
+};
+const NDialogProvider = /* @__PURE__ */ defineComponent({
+ name: "DialogProvider",
+ props: dialogProviderProps,
+ setup() {
+ const dialogListRef = ref([]);
+ const dialogInstRefs = {};
+ function create(options = {}) {
+ const key = createId();
+ const dialogReactive = reactive(Object.assign(Object.assign({}, options), {
+ key,
+ destroy: () => {
+ var _a;
+ (_a = dialogInstRefs[`n-dialog-${key}`]) === null || _a === void 0 ? void 0 : _a.hide();
+ }
+ }));
+ dialogListRef.value.push(dialogReactive);
+ return dialogReactive;
+ }
+ const typedApi = ["info", "success", "warning", "error"].map((type) => (options) => {
+ return create(Object.assign(Object.assign({}, options), {
+ type
+ }));
+ });
+ function handleAfterLeave(key) {
+ const {
+ value: dialogList
+ } = dialogListRef;
+ dialogList.splice(dialogList.findIndex((dialog) => dialog.key === key), 1);
+ }
+ function destroyAll() {
+ Object.values(dialogInstRefs).forEach((dialogInstRef) => {
+ dialogInstRef === null || dialogInstRef === void 0 ? void 0 : dialogInstRef.hide();
+ });
+ }
+ const api = {
+ create,
+ destroyAll,
+ info: typedApi[0],
+ success: typedApi[1],
+ warning: typedApi[2],
+ error: typedApi[3]
+ };
+ provide(dialogApiInjectionKey, api);
+ provide(dialogProviderInjectionKey, {
+ clickedRef: useClicked(64),
+ clickedPositionRef: useClickPosition()
+ });
+ provide(dialogReactiveListInjectionKey, dialogListRef);
+ return Object.assign(Object.assign({}, api), {
+ dialogList: dialogListRef,
+ dialogInstRefs,
+ handleAfterLeave
+ });
+ },
+ render() {
+ var _a, _b;
+ return h(Fragment, null, [this.dialogList.map((dialog) => h(NDialogEnvironment, omit(dialog, ["destroy", "style"], {
+ internalStyle: dialog.style,
+ to: this.to,
+ ref: (inst) => {
+ if (inst === null) {
+ delete this.dialogInstRefs[`n-dialog-${dialog.key}`];
+ } else {
+ this.dialogInstRefs[`n-dialog-${dialog.key}`] = inst;
+ }
+ },
+ internalKey: dialog.key,
+ onInternalAfterLeave: this.handleAfterLeave
+ }))), (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a)]);
+ }
+});
+const loadingBarDark = {
+ name: "LoadingBar",
+ common: derived$1,
+ self(vars) {
+ const {
+ primaryColor
+ } = vars;
+ return {
+ colorError: "red",
+ colorLoading: primaryColor,
+ height: "2px"
+ };
+ }
+};
+function self$J(vars) {
+ const {
+ primaryColor,
+ errorColor
+ } = vars;
+ return {
+ colorError: errorColor,
+ colorLoading: primaryColor,
+ height: "2px"
+ };
+}
+const loadingBarLight = {
+ name: "LoadingBar",
+ common: derived,
+ self: self$J
+};
+const messageApiInjectionKey = createInjectionKey("n-message-api");
+const messageProviderInjectionKey = createInjectionKey("n-message-provider");
+const commonVariables$6 = {
+ margin: "0 0 8px 0",
+ padding: "10px 20px",
+ maxWidth: "720px",
+ minWidth: "420px",
+ iconMargin: "0 10px 0 0",
+ closeMargin: "0 0 0 10px",
+ closeSize: "20px",
+ closeIconSize: "16px",
+ iconSize: "20px",
+ fontSize: "14px"
+};
+function self$I(vars) {
+ const {
+ textColor2,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ infoColor,
+ successColor,
+ errorColor,
+ warningColor,
+ popoverColor,
+ boxShadow2,
+ primaryColor,
+ lineHeight: lineHeight2,
+ borderRadius,
+ closeColorHover,
+ closeColorPressed
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$6), {
+ closeBorderRadius: borderRadius,
+ textColor: textColor2,
+ textColorInfo: textColor2,
+ textColorSuccess: textColor2,
+ textColorError: textColor2,
+ textColorWarning: textColor2,
+ textColorLoading: textColor2,
+ color: popoverColor,
+ colorInfo: popoverColor,
+ colorSuccess: popoverColor,
+ colorError: popoverColor,
+ colorWarning: popoverColor,
+ colorLoading: popoverColor,
+ boxShadow: boxShadow2,
+ boxShadowInfo: boxShadow2,
+ boxShadowSuccess: boxShadow2,
+ boxShadowError: boxShadow2,
+ boxShadowWarning: boxShadow2,
+ boxShadowLoading: boxShadow2,
+ iconColor: textColor2,
+ iconColorInfo: infoColor,
+ iconColorSuccess: successColor,
+ iconColorWarning: warningColor,
+ iconColorError: errorColor,
+ iconColorLoading: primaryColor,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHoverInfo: closeColorHover,
+ closeColorPressedInfo: closeColorPressed,
+ closeIconColorInfo: closeIconColor,
+ closeIconColorHoverInfo: closeIconColorHover,
+ closeIconColorPressedInfo: closeIconColorPressed,
+ closeColorHoverSuccess: closeColorHover,
+ closeColorPressedSuccess: closeColorPressed,
+ closeIconColorSuccess: closeIconColor,
+ closeIconColorHoverSuccess: closeIconColorHover,
+ closeIconColorPressedSuccess: closeIconColorPressed,
+ closeColorHoverError: closeColorHover,
+ closeColorPressedError: closeColorPressed,
+ closeIconColorError: closeIconColor,
+ closeIconColorHoverError: closeIconColorHover,
+ closeIconColorPressedError: closeIconColorPressed,
+ closeColorHoverWarning: closeColorHover,
+ closeColorPressedWarning: closeColorPressed,
+ closeIconColorWarning: closeIconColor,
+ closeIconColorHoverWarning: closeIconColorHover,
+ closeIconColorPressedWarning: closeIconColorPressed,
+ closeColorHoverLoading: closeColorHover,
+ closeColorPressedLoading: closeColorPressed,
+ closeIconColorLoading: closeIconColor,
+ closeIconColorHoverLoading: closeIconColorHover,
+ closeIconColorPressedLoading: closeIconColorPressed,
+ loadingColor: primaryColor,
+ lineHeight: lineHeight2,
+ borderRadius
+ });
+}
+const messageLight = {
+ name: "Message",
+ common: derived,
+ self: self$I
+};
+const messageDark = {
+ name: "Message",
+ common: derived$1,
+ self: self$I
+};
+const messageProps = {
+ icon: Function,
+ type: {
+ type: String,
+ default: "info"
+ },
+ content: [String, Number, Function],
+ showIcon: {
+ type: Boolean,
+ default: true
+ },
+ closable: Boolean,
+ keepAliveOnHover: Boolean,
+ onClose: Function,
+ onMouseenter: Function,
+ onMouseleave: Function
+};
+const style$1 = c([cB("message-wrapper", `
+ margin: var(--n-margin);
+ z-index: 0;
+ transform-origin: top center;
+ display: flex;
+ `, [fadeInHeightExpandTransition({
+ overflow: "visible",
+ originalTransition: "transform .3s var(--n-bezier)",
+ enterToProps: {
+ transform: "scale(1)"
+ },
+ leaveToProps: {
+ transform: "scale(0.85)"
+ }
+})]), cB("message", `
+ box-sizing: border-box;
+ display: flex;
+ align-items: center;
+ transition:
+ color .3s var(--n-bezier),
+ box-shadow .3s var(--n-bezier),
+ background-color .3s var(--n-bezier),
+ opacity .3s var(--n-bezier),
+ transform .3s var(--n-bezier),
+ margin-bottom .3s var(--n-bezier);
+ padding: var(--n-padding);
+ border-radius: var(--n-border-radius);
+ flex-wrap: nowrap;
+ overflow: hidden;
+ max-width: var(--n-max-width);
+ color: var(--n-text-color);
+ background-color: var(--n-color);
+ box-shadow: var(--n-box-shadow);
+ `, [cE("content", `
+ display: inline-block;
+ line-height: var(--n-line-height);
+ font-size: var(--n-font-size);
+ `), cE("icon", `
+ position: relative;
+ margin: var(--n-icon-margin);
+ height: var(--n-icon-size);
+ width: var(--n-icon-size);
+ font-size: var(--n-icon-size);
+ flex-shrink: 0;
+ `, [["default", "info", "success", "warning", "error", "loading"].map((type) => cM(`${type}-type`, [c("> *", `
+ color: var(--n-icon-color-${type});
+ transition: color .3s var(--n-bezier);
+ `)])), c("> *", `
+ position: absolute;
+ left: 0;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ `, [iconSwitchTransition()])]), cE("close", `
+ margin: var(--n-close-margin);
+ transition:
+ background-color .3s var(--n-bezier),
+ color .3s var(--n-bezier);
+ flex-shrink: 0;
+ `, [c("&:hover", `
+ color: var(--n-close-icon-color-hover);
+ `), c("&:active", `
+ color: var(--n-close-icon-color-pressed);
+ `)])]), cB("message-container", `
+ z-index: 6000;
+ position: fixed;
+ height: 0;
+ overflow: visible;
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ `, [cM("top", `
+ top: 12px;
+ left: 0;
+ right: 0;
+ `), cM("top-left", `
+ top: 12px;
+ left: 12px;
+ right: 0;
+ align-items: flex-start;
+ `), cM("top-right", `
+ top: 12px;
+ left: 0;
+ right: 12px;
+ align-items: flex-end;
+ `), cM("bottom", `
+ bottom: 4px;
+ left: 0;
+ right: 0;
+ justify-content: flex-end;
+ `), cM("bottom-left", `
+ bottom: 4px;
+ left: 12px;
+ right: 0;
+ justify-content: flex-end;
+ align-items: flex-start;
+ `), cM("bottom-right", `
+ bottom: 4px;
+ left: 0;
+ right: 12px;
+ justify-content: flex-end;
+ align-items: flex-end;
+ `)])]);
+const iconRenderMap = {
+ info: () => h(InfoIcon, null),
+ success: () => h(SuccessIcon, null),
+ warning: () => h(WarningIcon, null),
+ error: () => h(ErrorIcon, null),
+ default: () => null
+};
+const NMessage = /* @__PURE__ */ defineComponent({
+ name: "Message",
+ props: Object.assign(Object.assign({}, messageProps), {
+ render: Function
+ }),
+ setup(props) {
+ const {
+ inlineThemeDisabled,
+ mergedRtlRef
+ } = useConfig(props);
+ const {
+ props: messageProviderProps2,
+ mergedClsPrefixRef
+ } = inject(messageProviderInjectionKey);
+ const rtlEnabledRef = useRtl("Message", mergedRtlRef, mergedClsPrefixRef);
+ const themeRef = useTheme("Message", "-message", style$1, messageLight, messageProviderProps2, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ type
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ },
+ self: {
+ padding,
+ margin,
+ maxWidth,
+ iconMargin,
+ closeMargin,
+ closeSize,
+ iconSize,
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ borderRadius,
+ iconColorInfo,
+ iconColorSuccess,
+ iconColorWarning,
+ iconColorError,
+ iconColorLoading,
+ closeIconSize,
+ closeBorderRadius,
+ [createKey("textColor", type)]: textColor,
+ [createKey("boxShadow", type)]: boxShadow,
+ [createKey("color", type)]: color,
+ [createKey("closeColorHover", type)]: closeColorHover,
+ [createKey("closeColorPressed", type)]: closeColorPressed,
+ [createKey("closeIconColor", type)]: closeIconColor,
+ [createKey("closeIconColorPressed", type)]: closeIconColorPressed,
+ [createKey("closeIconColorHover", type)]: closeIconColorHover
+ }
+ } = themeRef.value;
+ return {
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-margin": margin,
+ "--n-padding": padding,
+ "--n-max-width": maxWidth,
+ "--n-font-size": fontSize2,
+ "--n-icon-margin": iconMargin,
+ "--n-icon-size": iconSize,
+ "--n-close-icon-size": closeIconSize,
+ "--n-close-border-radius": closeBorderRadius,
+ "--n-close-size": closeSize,
+ "--n-close-margin": closeMargin,
+ "--n-text-color": textColor,
+ "--n-color": color,
+ "--n-box-shadow": boxShadow,
+ "--n-icon-color-info": iconColorInfo,
+ "--n-icon-color-success": iconColorSuccess,
+ "--n-icon-color-warning": iconColorWarning,
+ "--n-icon-color-error": iconColorError,
+ "--n-icon-color-loading": iconColorLoading,
+ "--n-close-color-hover": closeColorHover,
+ "--n-close-color-pressed": closeColorPressed,
+ "--n-close-icon-color": closeIconColor,
+ "--n-close-icon-color-pressed": closeIconColorPressed,
+ "--n-close-icon-color-hover": closeIconColorHover,
+ "--n-line-height": lineHeight2,
+ "--n-border-radius": borderRadius
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("message", computed(() => props.type[0]), cssVarsRef, {}) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ rtlEnabled: rtlEnabledRef,
+ messageProviderProps: messageProviderProps2,
+ handleClose() {
+ var _a;
+ (_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props);
+ },
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender,
+ placement: messageProviderProps2.placement
+ };
+ },
+ render() {
+ const {
+ render: renderMessage,
+ type,
+ closable,
+ content,
+ mergedClsPrefix,
+ cssVars,
+ themeClass,
+ onRender,
+ icon,
+ handleClose,
+ showIcon
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ let iconNode;
+ return h("div", {
+ class: [`${mergedClsPrefix}-message-wrapper`, themeClass],
+ onMouseenter: this.onMouseenter,
+ onMouseleave: this.onMouseleave,
+ style: [{
+ alignItems: this.placement.startsWith("top") ? "flex-start" : "flex-end"
+ }, cssVars]
+ }, renderMessage ? renderMessage(this.$props) : h("div", {
+ class: [`${mergedClsPrefix}-message ${mergedClsPrefix}-message--${type}-type`, this.rtlEnabled && `${mergedClsPrefix}-message--rtl`]
+ }, (iconNode = createIconVNode(icon, type, mergedClsPrefix)) && showIcon ? h("div", {
+ class: `${mergedClsPrefix}-message__icon ${mergedClsPrefix}-message__icon--${type}-type`
+ }, h(NIconSwitchTransition, null, {
+ default: () => iconNode
+ })) : null, h("div", {
+ class: `${mergedClsPrefix}-message__content`
+ }, render(content)), closable ? h(NBaseClose, {
+ clsPrefix: mergedClsPrefix,
+ class: `${mergedClsPrefix}-message__close`,
+ onClick: handleClose,
+ absolute: true
+ }) : null));
+ }
+});
+function createIconVNode(icon, type, clsPrefix) {
+ if (typeof icon === "function") {
+ return icon();
+ } else {
+ const innerIcon = type === "loading" ? h(NBaseLoading, {
+ clsPrefix,
+ strokeWidth: 24,
+ scale: 0.85
+ }) : iconRenderMap[type]();
+ if (!innerIcon) return null;
+ return h(NBaseIcon, {
+ clsPrefix,
+ key: type
+ }, {
+ default: () => innerIcon
+ });
+ }
+}
+const MessageEnvironment = /* @__PURE__ */ defineComponent({
+ name: "MessageEnvironment",
+ props: Object.assign(Object.assign({}, messageProps), {
+ duration: {
+ type: Number,
+ default: 3e3
+ },
+ onAfterLeave: Function,
+ onLeave: Function,
+ internalKey: {
+ type: String,
+ required: true
+ },
+ // private
+ onInternalAfterLeave: Function,
+ // deprecated
+ onHide: Function,
+ onAfterHide: Function
+ }),
+ setup(props) {
+ let timerId = null;
+ const showRef = ref(true);
+ onMounted(() => {
+ setHideTimeout();
+ });
+ function setHideTimeout() {
+ const {
+ duration: duration2
+ } = props;
+ if (duration2) {
+ timerId = window.setTimeout(hide, duration2);
+ }
+ }
+ function handleMouseenter(e) {
+ if (e.currentTarget !== e.target) return;
+ if (timerId !== null) {
+ window.clearTimeout(timerId);
+ timerId = null;
+ }
+ }
+ function handleMouseleave(e) {
+ if (e.currentTarget !== e.target) return;
+ setHideTimeout();
+ }
+ function hide() {
+ const {
+ onHide
+ } = props;
+ showRef.value = false;
+ if (timerId) {
+ window.clearTimeout(timerId);
+ timerId = null;
+ }
+ if (onHide) onHide();
+ }
+ function handleClose() {
+ const {
+ onClose
+ } = props;
+ if (onClose) onClose();
+ hide();
+ }
+ function handleAfterLeave() {
+ const {
+ onAfterLeave,
+ onInternalAfterLeave,
+ onAfterHide,
+ internalKey
+ } = props;
+ if (onAfterLeave) onAfterLeave();
+ if (onInternalAfterLeave) onInternalAfterLeave(internalKey);
+ if (onAfterHide) onAfterHide();
+ }
+ function deactivate() {
+ hide();
+ }
+ return {
+ show: showRef,
+ hide,
+ handleClose,
+ handleAfterLeave,
+ handleMouseleave,
+ handleMouseenter,
+ deactivate
+ };
+ },
+ render() {
+ return h(NFadeInExpandTransition, {
+ appear: true,
+ onAfterLeave: this.handleAfterLeave,
+ onLeave: this.onLeave
+ }, {
+ default: () => [this.show ? h(NMessage, {
+ content: this.content,
+ type: this.type,
+ icon: this.icon,
+ showIcon: this.showIcon,
+ closable: this.closable,
+ onClose: this.handleClose,
+ onMouseenter: this.keepAliveOnHover ? this.handleMouseenter : void 0,
+ onMouseleave: this.keepAliveOnHover ? this.handleMouseleave : void 0
+ }) : null]
+ });
+ }
+});
+const messageProviderProps = Object.assign(Object.assign({}, useTheme.props), {
+ to: [String, Object],
+ duration: {
+ type: Number,
+ default: 3e3
+ },
+ keepAliveOnHover: Boolean,
+ max: Number,
+ placement: {
+ type: String,
+ default: "top"
+ },
+ closable: Boolean,
+ containerClass: String,
+ containerStyle: [String, Object]
+});
+const __unplugin_components_0$1 = /* @__PURE__ */ defineComponent({
+ name: "MessageProvider",
+ props: messageProviderProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef
+ } = useConfig(props);
+ const messageListRef = ref([]);
+ const messageRefs = ref({});
+ const api = {
+ create(content, options) {
+ return create(content, Object.assign({
+ type: "default"
+ }, options));
+ },
+ info(content, options) {
+ return create(content, Object.assign(Object.assign({}, options), {
+ type: "info"
+ }));
+ },
+ success(content, options) {
+ return create(content, Object.assign(Object.assign({}, options), {
+ type: "success"
+ }));
+ },
+ warning(content, options) {
+ return create(content, Object.assign(Object.assign({}, options), {
+ type: "warning"
+ }));
+ },
+ error(content, options) {
+ return create(content, Object.assign(Object.assign({}, options), {
+ type: "error"
+ }));
+ },
+ loading(content, options) {
+ return create(content, Object.assign(Object.assign({}, options), {
+ type: "loading"
+ }));
+ },
+ destroyAll
+ };
+ provide(messageProviderInjectionKey, {
+ props,
+ mergedClsPrefixRef
+ });
+ provide(messageApiInjectionKey, api);
+ function create(content, options) {
+ const key = createId();
+ const messageReactive = reactive(Object.assign(Object.assign({}, options), {
+ content,
+ key,
+ destroy: () => {
+ var _a;
+ (_a = messageRefs.value[key]) === null || _a === void 0 ? void 0 : _a.hide();
+ }
+ }));
+ const {
+ max
+ } = props;
+ if (max && messageListRef.value.length >= max) {
+ messageListRef.value.shift();
+ }
+ messageListRef.value.push(messageReactive);
+ return messageReactive;
+ }
+ function handleAfterLeave(key) {
+ messageListRef.value.splice(messageListRef.value.findIndex((message) => message.key === key), 1);
+ delete messageRefs.value[key];
+ }
+ function destroyAll() {
+ Object.values(messageRefs.value).forEach((messageInstRef) => {
+ messageInstRef.hide();
+ });
+ }
+ return Object.assign({
+ mergedClsPrefix: mergedClsPrefixRef,
+ messageRefs,
+ messageList: messageListRef,
+ handleAfterLeave
+ }, api);
+ },
+ render() {
+ var _a, _b, _c;
+ return h(Fragment, null, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a), this.messageList.length ? h(Teleport, {
+ to: (_c = this.to) !== null && _c !== void 0 ? _c : "body"
+ }, h("div", {
+ class: [`${this.mergedClsPrefix}-message-container`, `${this.mergedClsPrefix}-message-container--${this.placement}`, this.containerClass],
+ key: "message-container",
+ style: this.containerStyle
+ }, this.messageList.map((message) => {
+ return h(MessageEnvironment, Object.assign({
+ ref: (inst) => {
+ if (inst) {
+ this.messageRefs[message.key] = inst;
+ }
+ },
+ internalKey: message.key,
+ onInternalAfterLeave: this.handleAfterLeave
+ }, omit(message, ["destroy"], void 0), {
+ duration: message.duration === void 0 ? this.duration : message.duration,
+ keepAliveOnHover: message.keepAliveOnHover === void 0 ? this.keepAliveOnHover : message.keepAliveOnHover,
+ closable: message.closable === void 0 ? this.closable : message.closable
+ }));
+ }))) : null);
+ }
+});
+const commonVars$5 = {
+ closeMargin: "16px 12px",
+ closeSize: "20px",
+ closeIconSize: "16px",
+ width: "365px",
+ padding: "16px",
+ titleFontSize: "16px",
+ metaFontSize: "12px",
+ descriptionFontSize: "12px"
+};
+function self$H(vars) {
+ const {
+ textColor2,
+ successColor,
+ infoColor,
+ warningColor,
+ errorColor,
+ popoverColor,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ textColor1,
+ textColor3,
+ borderRadius,
+ fontWeightStrong,
+ boxShadow2,
+ lineHeight: lineHeight2,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$5), {
+ borderRadius,
+ lineHeight: lineHeight2,
+ fontSize: fontSize2,
+ headerFontWeight: fontWeightStrong,
+ iconColor: textColor2,
+ iconColorSuccess: successColor,
+ iconColorInfo: infoColor,
+ iconColorWarning: warningColor,
+ iconColorError: errorColor,
+ color: popoverColor,
+ textColor: textColor2,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeBorderRadius: borderRadius,
+ closeColorHover,
+ closeColorPressed,
+ headerTextColor: textColor1,
+ descriptionTextColor: textColor3,
+ actionTextColor: textColor2,
+ boxShadow: boxShadow2
+ });
+}
+const notificationLight = createTheme({
+ name: "Notification",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight
+ },
+ self: self$H
+});
+const notificationDark = {
+ name: "Notification",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark
+ },
+ self: self$H
+};
+function self$G(vars) {
+ const {
+ textColor1,
+ dividerColor,
+ fontWeightStrong
+ } = vars;
+ return {
+ textColor: textColor1,
+ color: dividerColor,
+ fontWeight: fontWeightStrong
+ };
+}
+const dividerLight = {
+ name: "Divider",
+ common: derived,
+ self: self$G
+};
+const dividerDark = {
+ name: "Divider",
+ common: derived$1,
+ self: self$G
+};
+function self$F(vars) {
+ const {
+ modalColor,
+ textColor1,
+ textColor2,
+ boxShadow3,
+ lineHeight: lineHeight2,
+ fontWeightStrong,
+ dividerColor,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ borderRadius,
+ primaryColorHover
+ } = vars;
+ return {
+ bodyPadding: "16px 24px",
+ borderRadius,
+ headerPadding: "16px 24px",
+ footerPadding: "16px 24px",
+ color: modalColor,
+ textColor: textColor2,
+ titleTextColor: textColor1,
+ titleFontSize: "18px",
+ titleFontWeight: fontWeightStrong,
+ boxShadow: boxShadow3,
+ lineHeight: lineHeight2,
+ headerBorderBottom: `1px solid ${dividerColor}`,
+ footerBorderTop: `1px solid ${dividerColor}`,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeSize: "22px",
+ closeIconSize: "18px",
+ closeColorHover,
+ closeColorPressed,
+ closeBorderRadius: borderRadius,
+ resizableTriggerColorHover: primaryColorHover
+ };
+}
+const drawerLight = createTheme({
+ name: "Drawer",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight
+ },
+ self: self$F
+});
+const drawerDark = {
+ name: "Drawer",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark
+ },
+ self: self$F
+};
+const commonVariables$5 = {
+ actionMargin: "0 0 0 20px",
+ actionMarginRtl: "0 20px 0 0"
+};
+const dynamicInputDark = {
+ name: "DynamicInput",
+ common: derived$1,
+ peers: {
+ Input: inputDark,
+ Button: buttonDark
+ },
+ self() {
+ return commonVariables$5;
+ }
+};
+function self$E() {
+ return commonVariables$5;
+}
+const dynamicInputLight = createTheme({
+ name: "DynamicInput",
+ common: derived,
+ peers: {
+ Input: inputLight,
+ Button: buttonLight
+ },
+ self: self$E
+});
+const commonVars$4 = {
+ gapSmall: "4px 8px",
+ gapMedium: "8px 12px",
+ gapLarge: "12px 16px"
+};
+const spaceDark = {
+ name: "Space",
+ self() {
+ return commonVars$4;
+ }
+};
+function self$D() {
+ return commonVars$4;
+}
+const spaceLight = {
+ name: "Space",
+ self: self$D
+};
+const dynamicTagsDark = {
+ name: "DynamicTags",
+ common: derived$1,
+ peers: {
+ Input: inputDark,
+ Button: buttonDark,
+ Tag: tagDark,
+ Space: spaceDark
+ },
+ self() {
+ return {
+ inputWidth: "64px"
+ };
+ }
+};
+const dynamicTagsLight = createTheme({
+ name: "DynamicTags",
+ common: derived,
+ peers: {
+ Input: inputLight,
+ Button: buttonLight,
+ Tag: tagLight,
+ Space: spaceLight
+ },
+ self() {
+ return {
+ inputWidth: "64px"
+ };
+ }
+});
+const elementDark = {
+ name: "Element",
+ common: derived$1
+};
+const elementLight = {
+ name: "Element",
+ common: derived
+};
+const commonVars$3 = {
+ gapSmall: "4px 8px",
+ gapMedium: "8px 12px",
+ gapLarge: "12px 16px"
+};
+const flexDark = {
+ name: "Flex",
+ self() {
+ return commonVars$3;
+ }
+};
+function self$C() {
+ return commonVars$3;
+}
+const flexLight = {
+ name: "Flex",
+ self: self$C
+};
+const buttonGroupDark = {
+ name: "ButtonGroup",
+ common: derived$1
+};
+const buttonGroupLight = {
+ name: "ButtonGroup",
+ common: derived
+};
+const commonVariables$4 = {
+ feedbackPadding: "4px 0 0 2px",
+ feedbackHeightSmall: "24px",
+ feedbackHeightMedium: "24px",
+ feedbackHeightLarge: "26px",
+ feedbackFontSizeSmall: "13px",
+ feedbackFontSizeMedium: "14px",
+ feedbackFontSizeLarge: "14px",
+ labelFontSizeLeftSmall: "14px",
+ labelFontSizeLeftMedium: "14px",
+ labelFontSizeLeftLarge: "15px",
+ labelFontSizeTopSmall: "13px",
+ labelFontSizeTopMedium: "14px",
+ labelFontSizeTopLarge: "14px",
+ labelHeightSmall: "24px",
+ labelHeightMedium: "26px",
+ labelHeightLarge: "28px",
+ labelPaddingVertical: "0 0 6px 2px",
+ labelPaddingHorizontal: "0 12px 0 0",
+ labelTextAlignVertical: "left",
+ labelTextAlignHorizontal: "right",
+ labelFontWeight: "400"
+};
+function self$B(vars) {
+ const {
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ textColor1,
+ errorColor,
+ warningColor,
+ lineHeight: lineHeight2,
+ textColor3
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$4), {
+ blankHeightSmall: heightSmall,
+ blankHeightMedium: heightMedium,
+ blankHeightLarge: heightLarge,
+ lineHeight: lineHeight2,
+ labelTextColor: textColor1,
+ asteriskColor: errorColor,
+ feedbackTextColorError: errorColor,
+ feedbackTextColorWarning: warningColor,
+ feedbackTextColor: textColor3
+ });
+}
+const formLight = {
+ name: "Form",
+ common: derived,
+ self: self$B
+};
+const formItemDark = {
+ name: "Form",
+ common: derived$1,
+ self: self$B
+};
+const gradientTextDark = {
+ name: "GradientText",
+ common: derived$1,
+ self(vars) {
+ const {
+ primaryColor,
+ successColor,
+ warningColor,
+ errorColor,
+ infoColor,
+ primaryColorSuppl,
+ successColorSuppl,
+ warningColorSuppl,
+ errorColorSuppl,
+ infoColorSuppl,
+ fontWeightStrong
+ } = vars;
+ return {
+ fontWeight: fontWeightStrong,
+ rotate: "252deg",
+ colorStartPrimary: primaryColor,
+ colorEndPrimary: primaryColorSuppl,
+ colorStartInfo: infoColor,
+ colorEndInfo: infoColorSuppl,
+ colorStartWarning: warningColor,
+ colorEndWarning: warningColorSuppl,
+ colorStartError: errorColor,
+ colorEndError: errorColorSuppl,
+ colorStartSuccess: successColor,
+ colorEndSuccess: successColorSuppl
+ };
+ }
+};
+function self$A(vars) {
+ const {
+ primaryColor,
+ successColor,
+ warningColor,
+ errorColor,
+ infoColor,
+ fontWeightStrong
+ } = vars;
+ return {
+ fontWeight: fontWeightStrong,
+ rotate: "252deg",
+ colorStartPrimary: changeColor(primaryColor, {
+ alpha: 0.6
+ }),
+ colorEndPrimary: primaryColor,
+ colorStartInfo: changeColor(infoColor, {
+ alpha: 0.6
+ }),
+ colorEndInfo: infoColor,
+ colorStartWarning: changeColor(warningColor, {
+ alpha: 0.6
+ }),
+ colorEndWarning: warningColor,
+ colorStartError: changeColor(errorColor, {
+ alpha: 0.6
+ }),
+ colorEndError: errorColor,
+ colorStartSuccess: changeColor(successColor, {
+ alpha: 0.6
+ }),
+ colorEndSuccess: successColor
+ };
+}
+const gradientTextLight = {
+ name: "GradientText",
+ common: derived,
+ self: self$A
+};
+const inputNumberDark = {
+ name: "InputNumber",
+ common: derived$1,
+ peers: {
+ Button: buttonDark,
+ Input: inputDark
+ },
+ self(vars) {
+ const {
+ textColorDisabled
+ } = vars;
+ return {
+ iconColorDisabled: textColorDisabled
+ };
+ }
+};
+function self$z(vars) {
+ const {
+ textColorDisabled
+ } = vars;
+ return {
+ iconColorDisabled: textColorDisabled
+ };
+}
+const inputNumberLight = createTheme({
+ name: "InputNumber",
+ common: derived,
+ peers: {
+ Button: buttonLight,
+ Input: inputLight
+ },
+ self: self$z
+});
+const layoutDark = {
+ name: "Layout",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark
+ },
+ self(vars) {
+ const {
+ textColor2,
+ bodyColor,
+ popoverColor,
+ cardColor,
+ dividerColor,
+ scrollbarColor,
+ scrollbarColorHover
+ } = vars;
+ return {
+ textColor: textColor2,
+ textColorInverted: textColor2,
+ color: bodyColor,
+ colorEmbedded: bodyColor,
+ headerColor: cardColor,
+ headerColorInverted: cardColor,
+ footerColor: cardColor,
+ footerColorInverted: cardColor,
+ headerBorderColor: dividerColor,
+ headerBorderColorInverted: dividerColor,
+ footerBorderColor: dividerColor,
+ footerBorderColorInverted: dividerColor,
+ siderBorderColor: dividerColor,
+ siderBorderColorInverted: dividerColor,
+ siderColor: cardColor,
+ siderColorInverted: cardColor,
+ siderToggleButtonBorder: "1px solid transparent",
+ siderToggleButtonColor: popoverColor,
+ siderToggleButtonIconColor: textColor2,
+ siderToggleButtonIconColorInverted: textColor2,
+ siderToggleBarColor: composite(bodyColor, scrollbarColor),
+ siderToggleBarColorHover: composite(bodyColor, scrollbarColorHover),
+ __invertScrollbar: "false"
+ };
+ }
+};
+function self$y(vars) {
+ const {
+ baseColor,
+ textColor2,
+ bodyColor,
+ cardColor,
+ dividerColor,
+ actionColor,
+ scrollbarColor,
+ scrollbarColorHover,
+ invertedColor
+ } = vars;
+ return {
+ textColor: textColor2,
+ textColorInverted: "#FFF",
+ color: bodyColor,
+ colorEmbedded: actionColor,
+ headerColor: cardColor,
+ headerColorInverted: invertedColor,
+ footerColor: actionColor,
+ footerColorInverted: invertedColor,
+ headerBorderColor: dividerColor,
+ headerBorderColorInverted: invertedColor,
+ footerBorderColor: dividerColor,
+ footerBorderColorInverted: invertedColor,
+ siderBorderColor: dividerColor,
+ siderBorderColorInverted: invertedColor,
+ siderColor: cardColor,
+ siderColorInverted: invertedColor,
+ siderToggleButtonBorder: `1px solid ${dividerColor}`,
+ siderToggleButtonColor: baseColor,
+ siderToggleButtonIconColor: textColor2,
+ siderToggleButtonIconColorInverted: textColor2,
+ siderToggleBarColor: composite(bodyColor, scrollbarColor),
+ siderToggleBarColorHover: composite(bodyColor, scrollbarColorHover),
+ // hack for inverted background
+ __invertScrollbar: "true"
+ };
+}
+const layoutLight = createTheme({
+ name: "Layout",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight
+ },
+ self: self$y
+});
+const rowDark = {
+ name: "Row",
+ common: derived$1
+};
+const rowLight = {
+ name: "Row",
+ common: derived
+};
+function self$x(vars) {
+ const {
+ textColor2,
+ cardColor,
+ modalColor,
+ popoverColor,
+ dividerColor,
+ borderRadius,
+ fontSize: fontSize2,
+ hoverColor
+ } = vars;
+ return {
+ textColor: textColor2,
+ color: cardColor,
+ colorHover: hoverColor,
+ colorModal: modalColor,
+ colorHoverModal: composite(modalColor, hoverColor),
+ colorPopover: popoverColor,
+ colorHoverPopover: composite(popoverColor, hoverColor),
+ borderColor: dividerColor,
+ borderColorModal: composite(modalColor, dividerColor),
+ borderColorPopover: composite(popoverColor, dividerColor),
+ borderRadius,
+ fontSize: fontSize2
+ };
+}
+const listLight = {
+ name: "List",
+ common: derived,
+ self: self$x
+};
+const listDark$1 = {
+ name: "List",
+ common: derived$1,
+ self: self$x
+};
+const logDark = {
+ name: "Log",
+ common: derived$1,
+ peers: {
+ Scrollbar: scrollbarDark,
+ Code: codeDark
+ },
+ self(vars) {
+ const {
+ textColor2,
+ inputColor,
+ fontSize: fontSize2,
+ primaryColor
+ } = vars;
+ return {
+ loaderFontSize: fontSize2,
+ loaderTextColor: textColor2,
+ loaderColor: inputColor,
+ loaderBorder: "1px solid #0000",
+ loadingColor: primaryColor
+ };
+ }
+};
+function self$w(vars) {
+ const {
+ textColor2,
+ modalColor,
+ borderColor,
+ fontSize: fontSize2,
+ primaryColor
+ } = vars;
+ return {
+ loaderFontSize: fontSize2,
+ loaderTextColor: textColor2,
+ loaderColor: modalColor,
+ loaderBorder: `1px solid ${borderColor}`,
+ loadingColor: primaryColor
+ };
+}
+const logLight = createTheme({
+ name: "Log",
+ common: derived,
+ peers: {
+ Scrollbar: scrollbarLight,
+ Code: codeLight
+ },
+ self: self$w
+});
+const listDark = {
+ name: "Mention",
+ common: derived$1,
+ peers: {
+ InternalSelectMenu: internalSelectMenuDark,
+ Input: inputDark
+ },
+ self(vars) {
+ const {
+ boxShadow2
+ } = vars;
+ return {
+ menuBoxShadow: boxShadow2
+ };
+ }
+};
+function self$v(vars) {
+ const {
+ boxShadow2
+ } = vars;
+ return {
+ menuBoxShadow: boxShadow2
+ };
+}
+const mentionLight = createTheme({
+ name: "Mention",
+ common: derived,
+ peers: {
+ InternalSelectMenu: internalSelectMenuLight,
+ Input: inputLight
+ },
+ self: self$v
+});
+function createPartialInvertedVars(color, activeItemColor, activeTextColor, groupTextColor) {
+ return {
+ itemColorHoverInverted: "#0000",
+ itemColorActiveInverted: activeItemColor,
+ itemColorActiveHoverInverted: activeItemColor,
+ itemColorActiveCollapsedInverted: activeItemColor,
+ itemTextColorInverted: color,
+ itemTextColorHoverInverted: activeTextColor,
+ itemTextColorChildActiveInverted: activeTextColor,
+ itemTextColorChildActiveHoverInverted: activeTextColor,
+ itemTextColorActiveInverted: activeTextColor,
+ itemTextColorActiveHoverInverted: activeTextColor,
+ itemTextColorHorizontalInverted: color,
+ itemTextColorHoverHorizontalInverted: activeTextColor,
+ itemTextColorChildActiveHorizontalInverted: activeTextColor,
+ itemTextColorChildActiveHoverHorizontalInverted: activeTextColor,
+ itemTextColorActiveHorizontalInverted: activeTextColor,
+ itemTextColorActiveHoverHorizontalInverted: activeTextColor,
+ itemIconColorInverted: color,
+ itemIconColorHoverInverted: activeTextColor,
+ itemIconColorActiveInverted: activeTextColor,
+ itemIconColorActiveHoverInverted: activeTextColor,
+ itemIconColorChildActiveInverted: activeTextColor,
+ itemIconColorChildActiveHoverInverted: activeTextColor,
+ itemIconColorCollapsedInverted: color,
+ itemIconColorHorizontalInverted: color,
+ itemIconColorHoverHorizontalInverted: activeTextColor,
+ itemIconColorActiveHorizontalInverted: activeTextColor,
+ itemIconColorActiveHoverHorizontalInverted: activeTextColor,
+ itemIconColorChildActiveHorizontalInverted: activeTextColor,
+ itemIconColorChildActiveHoverHorizontalInverted: activeTextColor,
+ arrowColorInverted: color,
+ arrowColorHoverInverted: activeTextColor,
+ arrowColorActiveInverted: activeTextColor,
+ arrowColorActiveHoverInverted: activeTextColor,
+ arrowColorChildActiveInverted: activeTextColor,
+ arrowColorChildActiveHoverInverted: activeTextColor,
+ groupTextColorInverted: groupTextColor
+ };
+}
+function self$u(vars) {
+ const {
+ borderRadius,
+ textColor3,
+ primaryColor,
+ textColor2,
+ textColor1,
+ fontSize: fontSize2,
+ dividerColor,
+ hoverColor,
+ primaryColorHover
+ } = vars;
+ return Object.assign({
+ borderRadius,
+ color: "#0000",
+ groupTextColor: textColor3,
+ itemColorHover: hoverColor,
+ itemColorActive: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ itemColorActiveHover: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ itemColorActiveCollapsed: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ itemTextColor: textColor2,
+ itemTextColorHover: textColor2,
+ itemTextColorActive: primaryColor,
+ itemTextColorActiveHover: primaryColor,
+ itemTextColorChildActive: primaryColor,
+ itemTextColorChildActiveHover: primaryColor,
+ itemTextColorHorizontal: textColor2,
+ itemTextColorHoverHorizontal: primaryColorHover,
+ itemTextColorActiveHorizontal: primaryColor,
+ itemTextColorActiveHoverHorizontal: primaryColor,
+ itemTextColorChildActiveHorizontal: primaryColor,
+ itemTextColorChildActiveHoverHorizontal: primaryColor,
+ itemIconColor: textColor1,
+ itemIconColorHover: textColor1,
+ itemIconColorActive: primaryColor,
+ itemIconColorActiveHover: primaryColor,
+ itemIconColorChildActive: primaryColor,
+ itemIconColorChildActiveHover: primaryColor,
+ itemIconColorCollapsed: textColor1,
+ itemIconColorHorizontal: textColor1,
+ itemIconColorHoverHorizontal: primaryColorHover,
+ itemIconColorActiveHorizontal: primaryColor,
+ itemIconColorActiveHoverHorizontal: primaryColor,
+ itemIconColorChildActiveHorizontal: primaryColor,
+ itemIconColorChildActiveHoverHorizontal: primaryColor,
+ itemHeight: "42px",
+ arrowColor: textColor2,
+ arrowColorHover: textColor2,
+ arrowColorActive: primaryColor,
+ arrowColorActiveHover: primaryColor,
+ arrowColorChildActive: primaryColor,
+ arrowColorChildActiveHover: primaryColor,
+ colorInverted: "#0000",
+ borderColorHorizontal: "#0000",
+ fontSize: fontSize2,
+ dividerColor
+ }, createPartialInvertedVars("#BBB", primaryColor, "#FFF", "#AAA"));
+}
+const menuLight = createTheme({
+ name: "Menu",
+ common: derived,
+ peers: {
+ Tooltip: tooltipLight,
+ Dropdown: dropdownLight
+ },
+ self: self$u
+});
+const menuDark = {
+ name: "Menu",
+ common: derived$1,
+ peers: {
+ Tooltip: tooltipDark,
+ Dropdown: dropdownDark
+ },
+ self(vars) {
+ const {
+ primaryColor,
+ primaryColorSuppl
+ } = vars;
+ const commonSelf = self$u(vars);
+ commonSelf.itemColorActive = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ commonSelf.itemColorActiveHover = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ commonSelf.itemColorActiveCollapsed = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ commonSelf.itemColorActiveInverted = primaryColorSuppl;
+ commonSelf.itemColorActiveHoverInverted = primaryColorSuppl;
+ commonSelf.itemColorActiveCollapsedInverted = primaryColorSuppl;
+ return commonSelf;
+ }
+};
+const common = {
+ titleFontSize: "18px",
+ backSize: "22px"
+};
+function self$t(vars) {
+ const {
+ textColor1,
+ textColor2,
+ textColor3,
+ fontSize: fontSize2,
+ fontWeightStrong,
+ primaryColorHover,
+ primaryColorPressed
+ } = vars;
+ return Object.assign(Object.assign({}, common), {
+ titleFontWeight: fontWeightStrong,
+ fontSize: fontSize2,
+ titleTextColor: textColor1,
+ backColor: textColor2,
+ backColorHover: primaryColorHover,
+ backColorPressed: primaryColorPressed,
+ subtitleTextColor: textColor3
+ });
+}
+const pageHeaderLight = createTheme({
+ name: "PageHeader",
+ common: derived,
+ self: self$t
+});
+const pageHeaderDark = {
+ name: "PageHeader",
+ common: derived$1,
+ self: self$t
+};
+const commonVars$2 = {
+ iconSize: "22px"
+};
+function self$s(vars) {
+ const {
+ fontSize: fontSize2,
+ warningColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars$2), {
+ fontSize: fontSize2,
+ iconColor: warningColor
+ });
+}
+const popconfirmLight = createTheme({
+ name: "Popconfirm",
+ common: derived,
+ peers: {
+ Button: buttonLight,
+ Popover: popoverLight
+ },
+ self: self$s
+});
+const popconfirmDark = {
+ name: "Popconfirm",
+ common: derived$1,
+ peers: {
+ Button: buttonDark,
+ Popover: popoverDark
+ },
+ self: self$s
+};
+function self$r(vars) {
+ const {
+ infoColor,
+ successColor,
+ warningColor,
+ errorColor,
+ textColor2,
+ progressRailColor,
+ fontSize: fontSize2,
+ fontWeight
+ } = vars;
+ return {
+ fontSize: fontSize2,
+ fontSizeCircle: "28px",
+ fontWeightCircle: fontWeight,
+ railColor: progressRailColor,
+ railHeight: "8px",
+ iconSizeCircle: "36px",
+ iconSizeLine: "18px",
+ iconColor: infoColor,
+ iconColorInfo: infoColor,
+ iconColorSuccess: successColor,
+ iconColorWarning: warningColor,
+ iconColorError: errorColor,
+ textColorCircle: textColor2,
+ textColorLineInner: "rgb(255, 255, 255)",
+ textColorLineOuter: textColor2,
+ fillColor: infoColor,
+ fillColorInfo: infoColor,
+ fillColorSuccess: successColor,
+ fillColorWarning: warningColor,
+ fillColorError: errorColor,
+ lineBgProcessing: "linear-gradient(90deg, rgba(255, 255, 255, .3) 0%, rgba(255, 255, 255, .5) 100%)"
+ };
+}
+const progressLight = {
+ name: "Progress",
+ common: derived,
+ self: self$r
+};
+const progressDark = {
+ name: "Progress",
+ common: derived$1,
+ self(vars) {
+ const commonSelf = self$r(vars);
+ commonSelf.textColorLineInner = "rgb(0, 0, 0)";
+ commonSelf.lineBgProcessing = "linear-gradient(90deg, rgba(255, 255, 255, .3) 0%, rgba(255, 255, 255, .5) 100%)";
+ return commonSelf;
+ }
+};
+const rateDark = {
+ name: "Rate",
+ common: derived$1,
+ self(vars) {
+ const {
+ railColor
+ } = vars;
+ return {
+ itemColor: railColor,
+ itemColorActive: "#CCAA33",
+ itemSize: "20px",
+ sizeSmall: "16px",
+ sizeMedium: "20px",
+ sizeLarge: "24px"
+ };
+ }
+};
+function self$q(vars) {
+ const {
+ railColor
+ } = vars;
+ return {
+ itemColor: railColor,
+ itemColorActive: "#FFCC33",
+ sizeSmall: "16px",
+ sizeMedium: "20px",
+ sizeLarge: "24px"
+ };
+}
+const themeLight$4 = {
+ name: "Rate",
+ common: derived,
+ self: self$q
+};
+const commonVariables$3 = {
+ titleFontSizeSmall: "26px",
+ titleFontSizeMedium: "32px",
+ titleFontSizeLarge: "40px",
+ titleFontSizeHuge: "48px",
+ fontSizeSmall: "14px",
+ fontSizeMedium: "14px",
+ fontSizeLarge: "15px",
+ fontSizeHuge: "16px",
+ iconSizeSmall: "64px",
+ iconSizeMedium: "80px",
+ iconSizeLarge: "100px",
+ iconSizeHuge: "125px",
+ iconColor418: void 0,
+ iconColor404: void 0,
+ iconColor403: void 0,
+ iconColor500: void 0
+};
+function self$p(vars) {
+ const {
+ textColor2,
+ textColor1,
+ errorColor,
+ successColor,
+ infoColor,
+ warningColor,
+ lineHeight: lineHeight2,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$3), {
+ lineHeight: lineHeight2,
+ titleFontWeight: fontWeightStrong,
+ titleTextColor: textColor1,
+ textColor: textColor2,
+ iconColorError: errorColor,
+ iconColorSuccess: successColor,
+ iconColorInfo: infoColor,
+ iconColorWarning: warningColor
+ });
+}
+const resultLight = {
+ name: "Result",
+ common: derived,
+ self: self$p
+};
+const resultDark = {
+ name: "Result",
+ common: derived$1,
+ self: self$p
+};
+const sizeVariables$3 = {
+ railHeight: "4px",
+ railWidthVertical: "4px",
+ handleSize: "18px",
+ dotHeight: "8px",
+ dotWidth: "8px",
+ dotBorderRadius: "4px"
+};
+const sliderDark = {
+ name: "Slider",
+ common: derived$1,
+ self(vars) {
+ const boxShadow = "0 2px 8px 0 rgba(0, 0, 0, 0.12)";
+ const {
+ railColor,
+ modalColor,
+ primaryColorSuppl,
+ popoverColor,
+ textColor2,
+ cardColor,
+ borderRadius,
+ fontSize: fontSize2,
+ opacityDisabled
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables$3), {
+ fontSize: fontSize2,
+ markFontSize: fontSize2,
+ railColor,
+ railColorHover: railColor,
+ fillColor: primaryColorSuppl,
+ fillColorHover: primaryColorSuppl,
+ opacityDisabled,
+ handleColor: "#FFF",
+ dotColor: cardColor,
+ dotColorModal: modalColor,
+ dotColorPopover: popoverColor,
+ handleBoxShadow: "0px 2px 4px 0 rgba(0, 0, 0, 0.4)",
+ handleBoxShadowHover: "0px 2px 4px 0 rgba(0, 0, 0, 0.4)",
+ handleBoxShadowActive: "0px 2px 4px 0 rgba(0, 0, 0, 0.4)",
+ handleBoxShadowFocus: "0px 2px 4px 0 rgba(0, 0, 0, 0.4)",
+ indicatorColor: popoverColor,
+ indicatorBoxShadow: boxShadow,
+ indicatorTextColor: textColor2,
+ indicatorBorderRadius: borderRadius,
+ dotBorder: `2px solid ${railColor}`,
+ dotBorderActive: `2px solid ${primaryColorSuppl}`,
+ dotBoxShadow: ""
+ });
+ }
+};
+function self$o(vars) {
+ const indicatorColor = "rgba(0, 0, 0, .85)";
+ const boxShadow = "0 2px 8px 0 rgba(0, 0, 0, 0.12)";
+ const {
+ railColor,
+ primaryColor,
+ baseColor,
+ cardColor,
+ modalColor,
+ popoverColor,
+ borderRadius,
+ fontSize: fontSize2,
+ opacityDisabled
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables$3), {
+ fontSize: fontSize2,
+ markFontSize: fontSize2,
+ railColor,
+ railColorHover: railColor,
+ fillColor: primaryColor,
+ fillColorHover: primaryColor,
+ opacityDisabled,
+ handleColor: "#FFF",
+ dotColor: cardColor,
+ dotColorModal: modalColor,
+ dotColorPopover: popoverColor,
+ handleBoxShadow: "0 1px 4px 0 rgba(0, 0, 0, 0.3), inset 0 0 1px 0 rgba(0, 0, 0, 0.05)",
+ handleBoxShadowHover: "0 1px 4px 0 rgba(0, 0, 0, 0.3), inset 0 0 1px 0 rgba(0, 0, 0, 0.05)",
+ handleBoxShadowActive: "0 1px 4px 0 rgba(0, 0, 0, 0.3), inset 0 0 1px 0 rgba(0, 0, 0, 0.05)",
+ handleBoxShadowFocus: "0 1px 4px 0 rgba(0, 0, 0, 0.3), inset 0 0 1px 0 rgba(0, 0, 0, 0.05)",
+ indicatorColor,
+ indicatorBoxShadow: boxShadow,
+ indicatorTextColor: baseColor,
+ indicatorBorderRadius: borderRadius,
+ dotBorder: `2px solid ${railColor}`,
+ dotBorderActive: `2px solid ${primaryColor}`,
+ dotBoxShadow: ""
+ });
+}
+const sliderLight = {
+ name: "Slider",
+ common: derived,
+ self: self$o
+};
+function self$n(vars) {
+ const {
+ opacityDisabled,
+ heightTiny,
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ heightHuge,
+ primaryColor,
+ fontSize: fontSize2
+ } = vars;
+ return {
+ fontSize: fontSize2,
+ textColor: primaryColor,
+ sizeTiny: heightTiny,
+ sizeSmall: heightSmall,
+ sizeMedium: heightMedium,
+ sizeLarge: heightLarge,
+ sizeHuge: heightHuge,
+ color: primaryColor,
+ opacitySpinning: opacityDisabled
+ };
+}
+const spinLight = {
+ name: "Spin",
+ common: derived,
+ self: self$n
+};
+const spinDark = {
+ name: "Spin",
+ common: derived$1,
+ self: self$n
+};
+function self$m(vars) {
+ const {
+ textColor2,
+ textColor3,
+ fontSize: fontSize2,
+ fontWeight
+ } = vars;
+ return {
+ labelFontSize: fontSize2,
+ labelFontWeight: fontWeight,
+ valueFontWeight: fontWeight,
+ valueFontSize: "24px",
+ labelTextColor: textColor3,
+ valuePrefixTextColor: textColor2,
+ valueSuffixTextColor: textColor2,
+ valueTextColor: textColor2
+ };
+}
+const statisticLight = {
+ name: "Statistic",
+ common: derived,
+ self: self$m
+};
+const statisticDark = {
+ name: "Statistic",
+ common: derived$1,
+ self: self$m
+};
+const commonVariables$2 = {
+ stepHeaderFontSizeSmall: "14px",
+ stepHeaderFontSizeMedium: "16px",
+ indicatorIndexFontSizeSmall: "14px",
+ indicatorIndexFontSizeMedium: "16px",
+ indicatorSizeSmall: "22px",
+ indicatorSizeMedium: "28px",
+ indicatorIconSizeSmall: "14px",
+ indicatorIconSizeMedium: "18px"
+};
+function self$l(vars) {
+ const {
+ fontWeightStrong,
+ baseColor,
+ textColorDisabled,
+ primaryColor,
+ errorColor,
+ textColor1,
+ textColor2
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$2), {
+ stepHeaderFontWeight: fontWeightStrong,
+ indicatorTextColorProcess: baseColor,
+ indicatorTextColorWait: textColorDisabled,
+ indicatorTextColorFinish: primaryColor,
+ indicatorTextColorError: errorColor,
+ indicatorBorderColorProcess: primaryColor,
+ indicatorBorderColorWait: textColorDisabled,
+ indicatorBorderColorFinish: primaryColor,
+ indicatorBorderColorError: errorColor,
+ indicatorColorProcess: primaryColor,
+ indicatorColorWait: "#0000",
+ indicatorColorFinish: "#0000",
+ indicatorColorError: "#0000",
+ splitorColorProcess: textColorDisabled,
+ splitorColorWait: textColorDisabled,
+ splitorColorFinish: primaryColor,
+ splitorColorError: textColorDisabled,
+ headerTextColorProcess: textColor1,
+ headerTextColorWait: textColorDisabled,
+ headerTextColorFinish: textColorDisabled,
+ headerTextColorError: errorColor,
+ descriptionTextColorProcess: textColor2,
+ descriptionTextColorWait: textColorDisabled,
+ descriptionTextColorFinish: textColorDisabled,
+ descriptionTextColorError: errorColor
+ });
+}
+const stepsLight = {
+ name: "Steps",
+ common: derived,
+ self: self$l
+};
+const stepsDark = {
+ name: "Steps",
+ common: derived$1,
+ self: self$l
+};
+const commonVars$1 = {
+ buttonHeightSmall: "14px",
+ buttonHeightMedium: "18px",
+ buttonHeightLarge: "22px",
+ buttonWidthSmall: "14px",
+ buttonWidthMedium: "18px",
+ buttonWidthLarge: "22px",
+ buttonWidthPressedSmall: "20px",
+ buttonWidthPressedMedium: "24px",
+ buttonWidthPressedLarge: "28px",
+ railHeightSmall: "18px",
+ railHeightMedium: "22px",
+ railHeightLarge: "26px",
+ railWidthSmall: "32px",
+ railWidthMedium: "40px",
+ railWidthLarge: "48px"
+};
+const switchDark = {
+ name: "Switch",
+ common: derived$1,
+ self(vars) {
+ const {
+ primaryColorSuppl,
+ opacityDisabled,
+ borderRadius,
+ primaryColor,
+ textColor2,
+ baseColor
+ } = vars;
+ const railOverlayColor = "rgba(255, 255, 255, .20)";
+ return Object.assign(Object.assign({}, commonVars$1), {
+ iconColor: baseColor,
+ textColor: textColor2,
+ loadingColor: primaryColorSuppl,
+ opacityDisabled,
+ railColor: railOverlayColor,
+ railColorActive: primaryColorSuppl,
+ buttonBoxShadow: "0px 2px 4px 0 rgba(0, 0, 0, 0.4)",
+ buttonColor: "#FFF",
+ railBorderRadiusSmall: borderRadius,
+ railBorderRadiusMedium: borderRadius,
+ railBorderRadiusLarge: borderRadius,
+ buttonBorderRadiusSmall: borderRadius,
+ buttonBorderRadiusMedium: borderRadius,
+ buttonBorderRadiusLarge: borderRadius,
+ boxShadowFocus: `0 0 8px 0 ${changeColor(primaryColor, {
+ alpha: 0.3
+ })}`
+ });
+ }
+};
+function self$k(vars) {
+ const {
+ primaryColor,
+ opacityDisabled,
+ borderRadius,
+ textColor3
+ } = vars;
+ const railOverlayColor = "rgba(0, 0, 0, .14)";
+ return Object.assign(Object.assign({}, commonVars$1), {
+ iconColor: textColor3,
+ textColor: "white",
+ loadingColor: primaryColor,
+ opacityDisabled,
+ railColor: railOverlayColor,
+ railColorActive: primaryColor,
+ buttonBoxShadow: "0 1px 4px 0 rgba(0, 0, 0, 0.3), inset 0 0 1px 0 rgba(0, 0, 0, 0.05)",
+ buttonColor: "#FFF",
+ railBorderRadiusSmall: borderRadius,
+ railBorderRadiusMedium: borderRadius,
+ railBorderRadiusLarge: borderRadius,
+ buttonBorderRadiusSmall: borderRadius,
+ buttonBorderRadiusMedium: borderRadius,
+ buttonBorderRadiusLarge: borderRadius,
+ boxShadowFocus: `0 0 0 2px ${changeColor(primaryColor, {
+ alpha: 0.2
+ })}`
+ });
+}
+const switchLight = {
+ name: "Switch",
+ common: derived,
+ self: self$k
+};
+const sizeVariables$2 = {
+ thPaddingSmall: "6px",
+ thPaddingMedium: "12px",
+ thPaddingLarge: "12px",
+ tdPaddingSmall: "6px",
+ tdPaddingMedium: "12px",
+ tdPaddingLarge: "12px"
+};
+function self$j(vars) {
+ const {
+ dividerColor,
+ cardColor,
+ modalColor,
+ popoverColor,
+ tableHeaderColor,
+ tableColorStriped,
+ textColor1,
+ textColor2,
+ borderRadius,
+ fontWeightStrong,
+ lineHeight: lineHeight2,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables$2), {
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ lineHeight: lineHeight2,
+ borderRadius,
+ borderColor: composite(cardColor, dividerColor),
+ borderColorModal: composite(modalColor, dividerColor),
+ borderColorPopover: composite(popoverColor, dividerColor),
+ tdColor: cardColor,
+ tdColorModal: modalColor,
+ tdColorPopover: popoverColor,
+ tdColorStriped: composite(cardColor, tableColorStriped),
+ tdColorStripedModal: composite(modalColor, tableColorStriped),
+ tdColorStripedPopover: composite(popoverColor, tableColorStriped),
+ thColor: composite(cardColor, tableHeaderColor),
+ thColorModal: composite(modalColor, tableHeaderColor),
+ thColorPopover: composite(popoverColor, tableHeaderColor),
+ thTextColor: textColor1,
+ tdTextColor: textColor2,
+ thFontWeight: fontWeightStrong
+ });
+}
+const tableLight = {
+ name: "Table",
+ common: derived,
+ self: self$j
+};
+const tableDark = {
+ name: "Table",
+ common: derived$1,
+ self: self$j
+};
+const sizeVariables$1 = {
+ tabFontSizeSmall: "14px",
+ tabFontSizeMedium: "14px",
+ tabFontSizeLarge: "16px",
+ tabGapSmallLine: "36px",
+ tabGapMediumLine: "36px",
+ tabGapLargeLine: "36px",
+ tabGapSmallLineVertical: "8px",
+ tabGapMediumLineVertical: "8px",
+ tabGapLargeLineVertical: "8px",
+ tabPaddingSmallLine: "6px 0",
+ tabPaddingMediumLine: "10px 0",
+ tabPaddingLargeLine: "14px 0",
+ tabPaddingVerticalSmallLine: "6px 12px",
+ tabPaddingVerticalMediumLine: "8px 16px",
+ tabPaddingVerticalLargeLine: "10px 20px",
+ tabGapSmallBar: "36px",
+ tabGapMediumBar: "36px",
+ tabGapLargeBar: "36px",
+ tabGapSmallBarVertical: "8px",
+ tabGapMediumBarVertical: "8px",
+ tabGapLargeBarVertical: "8px",
+ tabPaddingSmallBar: "4px 0",
+ tabPaddingMediumBar: "6px 0",
+ tabPaddingLargeBar: "10px 0",
+ tabPaddingVerticalSmallBar: "6px 12px",
+ tabPaddingVerticalMediumBar: "8px 16px",
+ tabPaddingVerticalLargeBar: "10px 20px",
+ tabGapSmallCard: "4px",
+ tabGapMediumCard: "4px",
+ tabGapLargeCard: "4px",
+ tabGapSmallCardVertical: "4px",
+ tabGapMediumCardVertical: "4px",
+ tabGapLargeCardVertical: "4px",
+ tabPaddingSmallCard: "8px 16px",
+ tabPaddingMediumCard: "10px 20px",
+ tabPaddingLargeCard: "12px 24px",
+ tabPaddingSmallSegment: "4px 0",
+ tabPaddingMediumSegment: "6px 0",
+ tabPaddingLargeSegment: "8px 0",
+ tabPaddingVerticalLargeSegment: "0 8px",
+ tabPaddingVerticalSmallCard: "8px 12px",
+ tabPaddingVerticalMediumCard: "10px 16px",
+ tabPaddingVerticalLargeCard: "12px 20px",
+ tabPaddingVerticalSmallSegment: "0 4px",
+ tabPaddingVerticalMediumSegment: "0 6px",
+ tabGapSmallSegment: "0",
+ tabGapMediumSegment: "0",
+ tabGapLargeSegment: "0",
+ tabGapSmallSegmentVertical: "0",
+ tabGapMediumSegmentVertical: "0",
+ tabGapLargeSegmentVertical: "0",
+ panePaddingSmall: "8px 0 0 0",
+ panePaddingMedium: "12px 0 0 0",
+ panePaddingLarge: "16px 0 0 0",
+ closeSize: "18px",
+ closeIconSize: "14px"
+};
+function self$i(vars) {
+ const {
+ textColor2,
+ primaryColor,
+ textColorDisabled,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ tabColor,
+ baseColor,
+ dividerColor,
+ fontWeight,
+ textColor1,
+ borderRadius,
+ fontSize: fontSize2,
+ fontWeightStrong
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables$1), {
+ colorSegment: tabColor,
+ tabFontSizeCard: fontSize2,
+ tabTextColorLine: textColor1,
+ tabTextColorActiveLine: primaryColor,
+ tabTextColorHoverLine: primaryColor,
+ tabTextColorDisabledLine: textColorDisabled,
+ tabTextColorSegment: textColor1,
+ tabTextColorActiveSegment: textColor2,
+ tabTextColorHoverSegment: textColor2,
+ tabTextColorDisabledSegment: textColorDisabled,
+ tabTextColorBar: textColor1,
+ tabTextColorActiveBar: primaryColor,
+ tabTextColorHoverBar: primaryColor,
+ tabTextColorDisabledBar: textColorDisabled,
+ tabTextColorCard: textColor1,
+ tabTextColorHoverCard: textColor1,
+ tabTextColorActiveCard: primaryColor,
+ tabTextColorDisabledCard: textColorDisabled,
+ barColor: primaryColor,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ closeColorHover,
+ closeColorPressed,
+ closeBorderRadius: borderRadius,
+ tabColor,
+ tabColorSegment: baseColor,
+ tabBorderColor: dividerColor,
+ tabFontWeightActive: fontWeight,
+ tabFontWeight: fontWeight,
+ tabBorderRadius: borderRadius,
+ paneTextColor: textColor2,
+ fontWeightStrong
+ });
+}
+const tabsLight = {
+ name: "Tabs",
+ common: derived,
+ self: self$i
+};
+const tabsDark = {
+ name: "Tabs",
+ common: derived$1,
+ self(vars) {
+ const commonSelf = self$i(vars);
+ const {
+ inputColor
+ } = vars;
+ commonSelf.colorSegment = inputColor;
+ commonSelf.tabColorSegment = inputColor;
+ return commonSelf;
+ }
+};
+function self$h(vars) {
+ const {
+ textColor1,
+ textColor2,
+ fontWeightStrong,
+ fontSize: fontSize2
+ } = vars;
+ return {
+ fontSize: fontSize2,
+ titleTextColor: textColor1,
+ textColor: textColor2,
+ titleFontWeight: fontWeightStrong
+ };
+}
+const thingLight = {
+ name: "Thing",
+ common: derived,
+ self: self$h
+};
+const thingDark = {
+ name: "Thing",
+ common: derived$1,
+ self: self$h
+};
+const sizeVariables = {
+ titleMarginMedium: "0 0 6px 0",
+ titleMarginLarge: "-2px 0 6px 0",
+ titleFontSizeMedium: "14px",
+ titleFontSizeLarge: "16px",
+ iconSizeMedium: "14px",
+ iconSizeLarge: "14px"
+};
+const timelineDark = {
+ name: "Timeline",
+ common: derived$1,
+ self(vars) {
+ const {
+ textColor3,
+ infoColorSuppl,
+ errorColorSuppl,
+ successColorSuppl,
+ warningColorSuppl,
+ textColor1,
+ textColor2,
+ railColor,
+ fontWeightStrong,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables), {
+ contentFontSize: fontSize2,
+ titleFontWeight: fontWeightStrong,
+ circleBorder: `2px solid ${textColor3}`,
+ circleBorderInfo: `2px solid ${infoColorSuppl}`,
+ circleBorderError: `2px solid ${errorColorSuppl}`,
+ circleBorderSuccess: `2px solid ${successColorSuppl}`,
+ circleBorderWarning: `2px solid ${warningColorSuppl}`,
+ iconColor: textColor3,
+ iconColorInfo: infoColorSuppl,
+ iconColorError: errorColorSuppl,
+ iconColorSuccess: successColorSuppl,
+ iconColorWarning: warningColorSuppl,
+ titleTextColor: textColor1,
+ contentTextColor: textColor2,
+ metaTextColor: textColor3,
+ lineColor: railColor
+ });
+ }
+};
+function self$g(vars) {
+ const {
+ textColor3,
+ infoColor,
+ errorColor,
+ successColor,
+ warningColor,
+ textColor1,
+ textColor2,
+ railColor,
+ fontWeightStrong,
+ fontSize: fontSize2
+ } = vars;
+ return Object.assign(Object.assign({}, sizeVariables), {
+ contentFontSize: fontSize2,
+ titleFontWeight: fontWeightStrong,
+ circleBorder: `2px solid ${textColor3}`,
+ circleBorderInfo: `2px solid ${infoColor}`,
+ circleBorderError: `2px solid ${errorColor}`,
+ circleBorderSuccess: `2px solid ${successColor}`,
+ circleBorderWarning: `2px solid ${warningColor}`,
+ iconColor: textColor3,
+ iconColorInfo: infoColor,
+ iconColorError: errorColor,
+ iconColorSuccess: successColor,
+ iconColorWarning: warningColor,
+ titleTextColor: textColor1,
+ contentTextColor: textColor2,
+ metaTextColor: textColor3,
+ lineColor: railColor
+ });
+}
+const timelineLight = {
+ name: "Timeline",
+ common: derived,
+ self: self$g
+};
+const commonVariables$1 = {
+ extraFontSizeSmall: "12px",
+ extraFontSizeMedium: "12px",
+ extraFontSizeLarge: "14px",
+ titleFontSizeSmall: "14px",
+ titleFontSizeMedium: "16px",
+ titleFontSizeLarge: "16px",
+ closeSize: "20px",
+ closeIconSize: "16px",
+ headerHeightSmall: "44px",
+ headerHeightMedium: "44px",
+ headerHeightLarge: "50px"
+};
+const transferDark$1 = {
+ name: "Transfer",
+ common: derived$1,
+ peers: {
+ Checkbox: checkboxDark,
+ Scrollbar: scrollbarDark,
+ Input: inputDark,
+ Empty: emptyDark,
+ Button: buttonDark
+ },
+ self(vars) {
+ const {
+ fontWeight,
+ fontSizeLarge,
+ fontSizeMedium,
+ fontSizeSmall,
+ heightLarge,
+ heightMedium,
+ borderRadius,
+ inputColor,
+ tableHeaderColor,
+ textColor1,
+ textColorDisabled,
+ textColor2,
+ textColor3,
+ hoverColor,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed,
+ dividerColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$1), {
+ itemHeightSmall: heightMedium,
+ itemHeightMedium: heightMedium,
+ itemHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadius,
+ dividerColor,
+ borderColor: "#0000",
+ listColor: inputColor,
+ headerColor: tableHeaderColor,
+ titleTextColor: textColor1,
+ titleTextColorDisabled: textColorDisabled,
+ extraTextColor: textColor3,
+ extraTextColorDisabled: textColorDisabled,
+ itemTextColor: textColor2,
+ itemTextColorDisabled: textColorDisabled,
+ itemColorPending: hoverColor,
+ titleFontWeight: fontWeight,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed
+ });
+ }
+};
+function self$f(vars) {
+ const {
+ fontWeight,
+ fontSizeLarge,
+ fontSizeMedium,
+ fontSizeSmall,
+ heightLarge,
+ heightMedium,
+ borderRadius,
+ cardColor,
+ tableHeaderColor,
+ textColor1,
+ textColorDisabled,
+ textColor2,
+ textColor3,
+ borderColor,
+ hoverColor,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables$1), {
+ itemHeightSmall: heightMedium,
+ itemHeightMedium: heightMedium,
+ itemHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadius,
+ dividerColor: borderColor,
+ borderColor,
+ listColor: cardColor,
+ headerColor: composite(cardColor, tableHeaderColor),
+ titleTextColor: textColor1,
+ titleTextColorDisabled: textColorDisabled,
+ extraTextColor: textColor3,
+ extraTextColorDisabled: textColorDisabled,
+ itemTextColor: textColor2,
+ itemTextColorDisabled: textColorDisabled,
+ itemColorPending: hoverColor,
+ titleFontWeight: fontWeight,
+ closeColorHover,
+ closeColorPressed,
+ closeIconColor,
+ closeIconColorHover,
+ closeIconColorPressed
+ });
+}
+const transferLight$1 = createTheme({
+ name: "Transfer",
+ common: derived,
+ peers: {
+ Checkbox: checkboxLight,
+ Scrollbar: scrollbarLight,
+ Input: inputLight,
+ Empty: emptyLight,
+ Button: buttonLight
+ },
+ self: self$f
+});
+function self$e(vars) {
+ const {
+ borderRadiusSmall,
+ dividerColor,
+ hoverColor,
+ pressedColor,
+ primaryColor,
+ textColor3,
+ textColor2,
+ textColorDisabled,
+ fontSize: fontSize2
+ } = vars;
+ return {
+ fontSize: fontSize2,
+ lineHeight: "1.5",
+ nodeHeight: "30px",
+ nodeWrapperPadding: "3px 0",
+ nodeBorderRadius: borderRadiusSmall,
+ nodeColorHover: hoverColor,
+ nodeColorPressed: pressedColor,
+ nodeColorActive: changeColor(primaryColor, {
+ alpha: 0.1
+ }),
+ arrowColor: textColor3,
+ nodeTextColor: textColor2,
+ nodeTextColorDisabled: textColorDisabled,
+ loadingColor: primaryColor,
+ dropMarkColor: primaryColor,
+ lineColor: dividerColor
+ };
+}
+const treeLight = createTheme({
+ name: "Tree",
+ common: derived,
+ peers: {
+ Checkbox: checkboxLight,
+ Scrollbar: scrollbarLight,
+ Empty: emptyLight
+ },
+ self: self$e
+});
+const treeDark = {
+ name: "Tree",
+ common: derived$1,
+ peers: {
+ Checkbox: checkboxDark,
+ Scrollbar: scrollbarDark,
+ Empty: emptyDark
+ },
+ self(vars) {
+ const {
+ primaryColor
+ } = vars;
+ const commonSelf = self$e(vars);
+ commonSelf.nodeColorActive = changeColor(primaryColor, {
+ alpha: 0.15
+ });
+ return commonSelf;
+ }
+};
+const treeSelectDark = {
+ name: "TreeSelect",
+ common: derived$1,
+ peers: {
+ Tree: treeDark,
+ Empty: emptyDark,
+ InternalSelection: internalSelectionDark
+ }
+};
+function self$d(vars) {
+ const {
+ popoverColor,
+ boxShadow2,
+ borderRadius,
+ heightMedium,
+ dividerColor,
+ textColor2
+ } = vars;
+ return {
+ menuPadding: "4px",
+ menuColor: popoverColor,
+ menuBoxShadow: boxShadow2,
+ menuBorderRadius: borderRadius,
+ menuHeight: `calc(${heightMedium} * 7.6)`,
+ actionDividerColor: dividerColor,
+ actionTextColor: textColor2,
+ actionPadding: "8px 12px",
+ headerDividerColor: dividerColor,
+ headerTextColor: textColor2,
+ headerPadding: "8px 12px"
+ };
+}
+const treeSelectLight = createTheme({
+ name: "TreeSelect",
+ common: derived,
+ peers: {
+ Tree: treeLight,
+ Empty: emptyLight,
+ InternalSelection: internalSelectionLight
+ },
+ self: self$d
+});
+const commonVars = {
+ headerFontSize1: "30px",
+ headerFontSize2: "22px",
+ headerFontSize3: "18px",
+ headerFontSize4: "16px",
+ headerFontSize5: "16px",
+ headerFontSize6: "16px",
+ headerMargin1: "28px 0 20px 0",
+ headerMargin2: "28px 0 20px 0",
+ headerMargin3: "28px 0 20px 0",
+ headerMargin4: "28px 0 18px 0",
+ headerMargin5: "28px 0 18px 0",
+ headerMargin6: "28px 0 18px 0",
+ headerPrefixWidth1: "16px",
+ headerPrefixWidth2: "16px",
+ headerPrefixWidth3: "12px",
+ headerPrefixWidth4: "12px",
+ headerPrefixWidth5: "12px",
+ headerPrefixWidth6: "12px",
+ headerBarWidth1: "4px",
+ headerBarWidth2: "4px",
+ headerBarWidth3: "3px",
+ headerBarWidth4: "3px",
+ headerBarWidth5: "3px",
+ headerBarWidth6: "3px",
+ pMargin: "16px 0 16px 0",
+ liMargin: ".25em 0 0 0",
+ olPadding: "0 0 0 2em",
+ ulPadding: "0 0 0 2em"
+};
+function self$c(vars) {
+ const {
+ primaryColor,
+ textColor2,
+ borderColor,
+ lineHeight: lineHeight2,
+ fontSize: fontSize2,
+ borderRadiusSmall,
+ dividerColor,
+ fontWeightStrong,
+ textColor1,
+ textColor3,
+ infoColor,
+ warningColor,
+ errorColor,
+ successColor,
+ codeColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVars), {
+ aTextColor: primaryColor,
+ blockquoteTextColor: textColor2,
+ blockquotePrefixColor: borderColor,
+ blockquoteLineHeight: lineHeight2,
+ blockquoteFontSize: fontSize2,
+ codeBorderRadius: borderRadiusSmall,
+ liTextColor: textColor2,
+ liLineHeight: lineHeight2,
+ liFontSize: fontSize2,
+ hrColor: dividerColor,
+ headerFontWeight: fontWeightStrong,
+ headerTextColor: textColor1,
+ pTextColor: textColor2,
+ pTextColor1Depth: textColor1,
+ pTextColor2Depth: textColor2,
+ pTextColor3Depth: textColor3,
+ pLineHeight: lineHeight2,
+ pFontSize: fontSize2,
+ headerBarColor: primaryColor,
+ headerBarColorPrimary: primaryColor,
+ headerBarColorInfo: infoColor,
+ headerBarColorError: errorColor,
+ headerBarColorWarning: warningColor,
+ headerBarColorSuccess: successColor,
+ textColor: textColor2,
+ textColor1Depth: textColor1,
+ textColor2Depth: textColor2,
+ textColor3Depth: textColor3,
+ textColorPrimary: primaryColor,
+ textColorInfo: infoColor,
+ textColorSuccess: successColor,
+ textColorWarning: warningColor,
+ textColorError: errorColor,
+ codeTextColor: textColor2,
+ codeColor,
+ codeBorder: "1px solid #0000"
+ });
+}
+const typographyLight = {
+ name: "Typography",
+ common: derived,
+ self: self$c
+};
+const typographyDark = {
+ name: "Typography",
+ common: derived$1,
+ self: self$c
+};
+function self$b(vars) {
+ const {
+ iconColor,
+ primaryColor,
+ errorColor,
+ textColor2,
+ successColor,
+ opacityDisabled,
+ actionColor,
+ borderColor,
+ hoverColor,
+ lineHeight: lineHeight2,
+ borderRadius,
+ fontSize: fontSize2
+ } = vars;
+ return {
+ fontSize: fontSize2,
+ lineHeight: lineHeight2,
+ borderRadius,
+ draggerColor: actionColor,
+ draggerBorder: `1px dashed ${borderColor}`,
+ draggerBorderHover: `1px dashed ${primaryColor}`,
+ itemColorHover: hoverColor,
+ itemColorHoverError: changeColor(errorColor, {
+ alpha: 0.06
+ }),
+ itemTextColor: textColor2,
+ itemTextColorError: errorColor,
+ itemTextColorSuccess: successColor,
+ itemIconColor: iconColor,
+ itemDisabledOpacity: opacityDisabled,
+ itemBorderImageCardError: `1px solid ${errorColor}`,
+ itemBorderImageCard: `1px solid ${borderColor}`
+ };
+}
+const uploadLight = createTheme({
+ name: "Upload",
+ common: derived,
+ peers: {
+ Button: buttonLight,
+ Progress: progressLight
+ },
+ self: self$b
+});
+const uploadDark = {
+ name: "Upload",
+ common: derived$1,
+ peers: {
+ Button: buttonDark,
+ Progress: progressDark
+ },
+ self(vars) {
+ const {
+ errorColor
+ } = vars;
+ const commonSelf = self$b(vars);
+ commonSelf.itemColorHoverError = changeColor(errorColor, {
+ alpha: 0.09
+ });
+ return commonSelf;
+ }
+};
+const watermarkDark = {
+ name: "Watermark",
+ common: derived$1,
+ self(vars) {
+ const {
+ fontFamily: fontFamily2
+ } = vars;
+ return {
+ fontFamily: fontFamily2
+ };
+ }
+};
+const watermarkLight = createTheme({
+ name: "Watermark",
+ common: derived,
+ self(vars) {
+ const {
+ fontFamily: fontFamily2
+ } = vars;
+ return {
+ fontFamily: fontFamily2
+ };
+ }
+});
+function self$a(vars) {
+ const {
+ popoverColor,
+ dividerColor,
+ borderRadius
+ } = vars;
+ return {
+ color: popoverColor,
+ buttonBorderColor: dividerColor,
+ borderRadiusSquare: borderRadius,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .12)"
+ };
+}
+const themeLight$3 = {
+ name: "FloatButtonGroup",
+ common: derived,
+ self: self$a
+};
+const floatButtonDark = {
+ name: "FloatButton",
+ common: derived$1,
+ self(vars) {
+ const {
+ popoverColor,
+ textColor2,
+ buttonColor2Hover,
+ buttonColor2Pressed,
+ primaryColor,
+ primaryColorHover,
+ primaryColorPressed,
+ baseColor,
+ borderRadius
+ } = vars;
+ return {
+ color: popoverColor,
+ textColor: textColor2,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .12)",
+ boxShadowHover: "0 2px 12px 0px rgba(0, 0, 0, .18)",
+ boxShadowPressed: "0 2px 12px 0px rgba(0, 0, 0, .18)",
+ colorHover: buttonColor2Hover,
+ colorPressed: buttonColor2Pressed,
+ colorPrimary: primaryColor,
+ colorPrimaryHover: primaryColorHover,
+ colorPrimaryPressed: primaryColorPressed,
+ textColorPrimary: baseColor,
+ borderRadiusSquare: borderRadius
+ };
+ }
+};
+function self$9(vars) {
+ const {
+ popoverColor,
+ textColor2,
+ buttonColor2Hover,
+ buttonColor2Pressed,
+ primaryColor,
+ primaryColorHover,
+ primaryColorPressed,
+ borderRadius
+ } = vars;
+ return {
+ color: popoverColor,
+ colorHover: buttonColor2Hover,
+ colorPressed: buttonColor2Pressed,
+ colorPrimary: primaryColor,
+ colorPrimaryHover: primaryColorHover,
+ colorPrimaryPressed: primaryColorPressed,
+ textColor: textColor2,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .16)",
+ boxShadowHover: "0 2px 12px 0px rgba(0, 0, 0, .24)",
+ boxShadowPressed: "0 2px 12px 0px rgba(0, 0, 0, .24)",
+ textColorPrimary: "#fff",
+ borderRadiusSquare: borderRadius
+ };
+}
+const themeLight$2 = {
+ name: "FloatButton",
+ common: derived,
+ self: self$9
+};
+function self$8(vars) {
+ const {
+ primaryColor,
+ baseColor
+ } = vars;
+ return {
+ color: primaryColor,
+ iconColor: baseColor
+ };
+}
+const iconWrapperLight = {
+ name: "IconWrapper",
+ common: derived,
+ self: self$8
+};
+const iconDark = {
+ name: "IconWrapper",
+ common: derived$1,
+ self: self$8
+};
+const imageDark = {
+ name: "Image",
+ common: derived$1,
+ peers: {
+ Tooltip: tooltipDark
+ },
+ self: (vars) => {
+ const {
+ textColor2
+ } = vars;
+ return {
+ toolbarIconColor: textColor2,
+ toolbarColor: "rgba(0, 0, 0, .35)",
+ toolbarBoxShadow: "none",
+ toolbarBorderRadius: "24px"
+ };
+ }
+};
+function self$7() {
+ return {
+ toolbarIconColor: "rgba(255, 255, 255, .9)",
+ toolbarColor: "rgba(0, 0, 0, .35)",
+ toolbarBoxShadow: "none",
+ toolbarBorderRadius: "24px"
+ };
+}
+const imageLight = createTheme({
+ name: "Image",
+ common: derived,
+ peers: {
+ Tooltip: tooltipLight
+ },
+ self: self$7
+});
+const commonVariables = {
+ extraFontSize: "12px",
+ width: "440px"
+};
+const transferDark = {
+ name: "Transfer",
+ common: derived$1,
+ peers: {
+ Checkbox: checkboxDark,
+ Scrollbar: scrollbarDark,
+ Input: inputDark,
+ Empty: emptyDark,
+ Button: buttonDark
+ },
+ self(vars) {
+ const {
+ iconColorDisabled,
+ iconColor,
+ fontWeight,
+ fontSizeLarge,
+ fontSizeMedium,
+ fontSizeSmall,
+ heightLarge,
+ heightMedium,
+ heightSmall,
+ borderRadius,
+ inputColor,
+ tableHeaderColor,
+ textColor1,
+ textColorDisabled,
+ textColor2,
+ hoverColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables), {
+ itemHeightSmall: heightSmall,
+ itemHeightMedium: heightMedium,
+ itemHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadius,
+ borderColor: "#0000",
+ listColor: inputColor,
+ headerColor: tableHeaderColor,
+ titleTextColor: textColor1,
+ titleTextColorDisabled: textColorDisabled,
+ extraTextColor: textColor2,
+ filterDividerColor: "#0000",
+ itemTextColor: textColor2,
+ itemTextColorDisabled: textColorDisabled,
+ itemColorPending: hoverColor,
+ titleFontWeight: fontWeight,
+ iconColor,
+ iconColorDisabled
+ });
+ }
+};
+function self$6(vars) {
+ const {
+ fontWeight,
+ iconColorDisabled,
+ iconColor,
+ fontSizeLarge,
+ fontSizeMedium,
+ fontSizeSmall,
+ heightLarge,
+ heightMedium,
+ heightSmall,
+ borderRadius,
+ cardColor,
+ tableHeaderColor,
+ textColor1,
+ textColorDisabled,
+ textColor2,
+ borderColor,
+ hoverColor
+ } = vars;
+ return Object.assign(Object.assign({}, commonVariables), {
+ itemHeightSmall: heightSmall,
+ itemHeightMedium: heightMedium,
+ itemHeightLarge: heightLarge,
+ fontSizeSmall,
+ fontSizeMedium,
+ fontSizeLarge,
+ borderRadius,
+ borderColor,
+ listColor: cardColor,
+ headerColor: composite(cardColor, tableHeaderColor),
+ titleTextColor: textColor1,
+ titleTextColorDisabled: textColorDisabled,
+ extraTextColor: textColor2,
+ filterDividerColor: borderColor,
+ itemTextColor: textColor2,
+ itemTextColorDisabled: textColorDisabled,
+ itemColorPending: hoverColor,
+ titleFontWeight: fontWeight,
+ iconColor,
+ iconColorDisabled
+ });
+}
+const transferLight = createTheme({
+ name: "Transfer",
+ common: derived,
+ peers: {
+ Checkbox: checkboxLight,
+ Scrollbar: scrollbarLight,
+ Input: inputLight,
+ Empty: emptyLight,
+ Button: buttonLight
+ },
+ self: self$6
+});
+function self$5() {
+ return {};
+}
+const marqueeLight = {
+ name: "Marquee",
+ common: derived,
+ self: self$5
+};
+const marqueeDark = {
+ name: "Marquee",
+ common: derived$1,
+ self: self$5
+};
+const qrcodeDark = {
+ name: "QrCode",
+ common: derived$1,
+ self: (vars) => {
+ return {
+ borderRadius: vars.borderRadius
+ };
+ }
+};
+function self$4(vars) {
+ return {
+ borderRadius: vars.borderRadius
+ };
+}
+const themeLight$1 = {
+ name: "QrCode",
+ common: derived,
+ self: self$4
+};
+const scrollbarProps = Object.assign(Object.assign({}, useTheme.props), {
+ trigger: String,
+ xScrollable: Boolean,
+ onScroll: Function,
+ contentClass: String,
+ contentStyle: [Object, String],
+ size: Number,
+ yPlacement: {
+ type: String,
+ default: "right"
+ },
+ xPlacement: {
+ type: String,
+ default: "bottom"
+ }
+});
+const Scrollbar = /* @__PURE__ */ defineComponent({
+ name: "Scrollbar",
+ props: scrollbarProps,
+ setup() {
+ const scrollbarInstRef = ref(null);
+ const exposedMethods = {
+ scrollTo: (...args) => {
+ var _a;
+ (_a = scrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.scrollTo(args[0], args[1]);
+ },
+ scrollBy: (...args) => {
+ var _a;
+ (_a = scrollbarInstRef.value) === null || _a === void 0 ? void 0 : _a.scrollBy(args[0], args[1]);
+ }
+ };
+ return Object.assign(Object.assign({}, exposedMethods), {
+ scrollbarInstRef
+ });
+ },
+ render() {
+ return h(Scrollbar$1, Object.assign({
+ ref: "scrollbarInstRef"
+ }, this.$props), this.$slots);
+ }
+});
+const skeletonDark = {
+ name: "Skeleton",
+ common: derived$1,
+ self(vars) {
+ const {
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadius
+ } = vars;
+ return {
+ color: "rgba(255, 255, 255, 0.12)",
+ colorEnd: "rgba(255, 255, 255, 0.18)",
+ borderRadius,
+ heightSmall,
+ heightMedium,
+ heightLarge
+ };
+ }
+};
+function self$3(vars) {
+ const {
+ heightSmall,
+ heightMedium,
+ heightLarge,
+ borderRadius
+ } = vars;
+ return {
+ color: "#eee",
+ colorEnd: "#ddd",
+ borderRadius,
+ heightSmall,
+ heightMedium,
+ heightLarge
+ };
+}
+const skeletonLight = {
+ name: "Skeleton",
+ common: derived,
+ self: self$3
+};
+const style = c([c("@keyframes spin-rotate", `
+ from {
+ transform: rotate(0);
+ }
+ to {
+ transform: rotate(360deg);
+ }
+ `), cB("spin-container", `
+ position: relative;
+ `, [cB("spin-body", `
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ transform: translateX(-50%) translateY(-50%);
+ `, [fadeInTransition()])]), cB("spin-body", `
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ flex-direction: column;
+ `), cB("spin", `
+ display: inline-flex;
+ height: var(--n-size);
+ width: var(--n-size);
+ font-size: var(--n-size);
+ color: var(--n-color);
+ `, [cM("rotate", `
+ animation: spin-rotate 2s linear infinite;
+ `)]), cB("spin-description", `
+ display: inline-block;
+ font-size: var(--n-font-size);
+ color: var(--n-text-color);
+ transition: color .3s var(--n-bezier);
+ margin-top: 8px;
+ `), cB("spin-content", `
+ opacity: 1;
+ transition: opacity .3s var(--n-bezier);
+ pointer-events: all;
+ `, [cM("spinning", `
+ user-select: none;
+ -webkit-user-select: none;
+ pointer-events: none;
+ opacity: var(--n-opacity-spinning);
+ `)])]);
+const STROKE_WIDTH = {
+ small: 20,
+ medium: 18,
+ large: 16
+};
+const spinProps = Object.assign(Object.assign({}, useTheme.props), {
+ contentClass: String,
+ contentStyle: [Object, String],
+ description: String,
+ stroke: String,
+ size: {
+ type: [String, Number],
+ default: "medium"
+ },
+ show: {
+ type: Boolean,
+ default: true
+ },
+ strokeWidth: Number,
+ rotate: {
+ type: Boolean,
+ default: true
+ },
+ spinning: {
+ type: Boolean,
+ validator: () => {
+ return true;
+ },
+ default: void 0
+ },
+ delay: Number
+});
+const __unplugin_components_0 = /* @__PURE__ */ defineComponent({
+ name: "Spin",
+ props: spinProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled
+ } = useConfig(props);
+ const themeRef = useTheme("Spin", "-spin", style, spinLight, props, mergedClsPrefixRef);
+ const cssVarsRef = computed(() => {
+ const {
+ size: spinSize
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut: cubicBezierEaseInOut2
+ },
+ self: self2
+ } = themeRef.value;
+ const {
+ opacitySpinning,
+ color,
+ textColor
+ } = self2;
+ const size2 = typeof spinSize === "number" ? pxfy(spinSize) : self2[createKey("size", spinSize)];
+ return {
+ "--n-bezier": cubicBezierEaseInOut2,
+ "--n-opacity-spinning": opacitySpinning,
+ "--n-size": size2,
+ "--n-color": color,
+ "--n-text-color": textColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("spin", computed(() => {
+ const {
+ size: size2
+ } = props;
+ return typeof size2 === "number" ? String(size2) : size2[0];
+ }), cssVarsRef, props) : void 0;
+ const compitableShow = useCompitable(props, ["spinning", "show"]);
+ const activeRef = ref(false);
+ watchEffect((onCleanup) => {
+ let timerId;
+ if (compitableShow.value) {
+ const {
+ delay
+ } = props;
+ if (delay) {
+ timerId = window.setTimeout(() => {
+ activeRef.value = true;
+ }, delay);
+ onCleanup(() => {
+ clearTimeout(timerId);
+ });
+ return;
+ }
+ }
+ activeRef.value = compitableShow.value;
+ });
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ active: activeRef,
+ mergedStrokeWidth: computed(() => {
+ const {
+ strokeWidth
+ } = props;
+ if (strokeWidth !== void 0) return strokeWidth;
+ const {
+ size: size2
+ } = props;
+ return STROKE_WIDTH[typeof size2 === "number" ? "medium" : size2];
+ }),
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ var _a, _b;
+ const {
+ $slots,
+ mergedClsPrefix,
+ description: description2
+ } = this;
+ const rotate = $slots.icon && this.rotate;
+ const descriptionNode = (description2 || $slots.description) && h("div", {
+ class: `${mergedClsPrefix}-spin-description`
+ }, description2 || ((_a = $slots.description) === null || _a === void 0 ? void 0 : _a.call($slots)));
+ const icon = $slots.icon ? h("div", {
+ class: [`${mergedClsPrefix}-spin-body`, this.themeClass]
+ }, h("div", {
+ class: [`${mergedClsPrefix}-spin`, rotate && `${mergedClsPrefix}-spin--rotate`],
+ style: $slots.default ? "" : this.cssVars
+ }, $slots.icon()), descriptionNode) : h("div", {
+ class: [`${mergedClsPrefix}-spin-body`, this.themeClass]
+ }, h(NBaseLoading, {
+ clsPrefix: mergedClsPrefix,
+ style: $slots.default ? "" : this.cssVars,
+ stroke: this.stroke,
+ "stroke-width": this.mergedStrokeWidth,
+ class: `${mergedClsPrefix}-spin`
+ }), descriptionNode);
+ (_b = this.onRender) === null || _b === void 0 ? void 0 : _b.call(this);
+ return $slots.default ? h("div", {
+ class: [`${mergedClsPrefix}-spin-container`, this.themeClass],
+ style: this.cssVars
+ }, h("div", {
+ class: [`${mergedClsPrefix}-spin-content`, this.active && `${mergedClsPrefix}-spin-content--spinning`, this.contentClass],
+ style: this.contentStyle
+ }, $slots), h(Transition, {
+ name: "fade-in-transition"
+ }, {
+ default: () => this.active ? icon : null
+ })) : icon;
+ }
+});
+const splitDark = {
+ name: "Split",
+ common: derived$1
+};
+function self$2(vars) {
+ const {
+ primaryColorHover,
+ borderColor
+ } = vars;
+ return {
+ resizableTriggerColorHover: primaryColorHover,
+ resizableTriggerColor: borderColor
+ };
+}
+const themeLight = {
+ name: "Split",
+ common: derived,
+ self: self$2
+};
+const self$1 = () => ({});
+const equationLight = {
+ name: "Equation",
+ common: derived,
+ self: self$1
+};
+const equationDark = {
+ name: "Equation",
+ common: derived$1,
+ self: self$1
+};
+const floatButtonGroupDark = {
+ name: "FloatButtonGroup",
+ common: derived$1,
+ self(vars) {
+ const {
+ popoverColor,
+ dividerColor,
+ borderRadius
+ } = vars;
+ return {
+ color: popoverColor,
+ buttonBorderColor: dividerColor,
+ borderRadiusSquare: borderRadius,
+ boxShadow: "0 2px 8px 0px rgba(0, 0, 0, .12)"
+ };
+ }
+};
+const lightTheme = {
+ name: "light",
+ common: derived,
+ Alert: alertLight,
+ Anchor: anchorLight,
+ AutoComplete: autoCompleteLight,
+ Avatar: avatarLight,
+ AvatarGroup: avatarGroupLight,
+ BackTop: backTopLight,
+ Badge: badgeLight,
+ Breadcrumb: breadcrumbLight,
+ Button: buttonLight,
+ ButtonGroup: buttonGroupLight,
+ Calendar: calendarLight,
+ Card: cardLight,
+ Carousel: carouselLight,
+ Cascader: cascaderLight,
+ Checkbox: checkboxLight,
+ Code: codeLight,
+ Collapse: collapseLight,
+ CollapseTransition: collapseTransitionLight,
+ ColorPicker: colorPickerLight,
+ DataTable: dataTableLight,
+ DatePicker: datePickerLight,
+ Descriptions: descriptionsLight,
+ Dialog: dialogLight,
+ Divider: dividerLight,
+ Drawer: drawerLight,
+ Dropdown: dropdownLight,
+ DynamicInput: dynamicInputLight,
+ DynamicTags: dynamicTagsLight,
+ Element: elementLight,
+ Empty: emptyLight,
+ Equation: equationLight,
+ Ellipsis: ellipsisLight,
+ Flex: flexLight,
+ Form: formLight,
+ GradientText: gradientTextLight,
+ Icon: iconLight,
+ IconWrapper: iconWrapperLight,
+ Image: imageLight,
+ Input: inputLight,
+ InputNumber: inputNumberLight,
+ Layout: layoutLight,
+ LegacyTransfer: transferLight,
+ List: listLight,
+ LoadingBar: loadingBarLight,
+ Log: logLight,
+ Menu: menuLight,
+ Mention: mentionLight,
+ Message: messageLight,
+ Modal: modalLight,
+ Notification: notificationLight,
+ PageHeader: pageHeaderLight,
+ Pagination: paginationLight,
+ Popconfirm: popconfirmLight,
+ Popover: popoverLight,
+ Popselect: popselectLight,
+ Progress: progressLight,
+ QrCode: themeLight$1,
+ Radio: radioLight,
+ Rate: themeLight$4,
+ Row: rowLight,
+ Result: resultLight,
+ Scrollbar: scrollbarLight,
+ Skeleton: skeletonLight,
+ Select: selectLight,
+ Slider: sliderLight,
+ Space: spaceLight,
+ Spin: spinLight,
+ Statistic: statisticLight,
+ Steps: stepsLight,
+ Switch: switchLight,
+ Table: tableLight,
+ Tabs: tabsLight,
+ Tag: tagLight,
+ Thing: thingLight,
+ TimePicker: timePickerLight,
+ Timeline: timelineLight,
+ Tooltip: tooltipLight,
+ Transfer: transferLight$1,
+ Tree: treeLight,
+ TreeSelect: treeSelectLight,
+ Typography: typographyLight,
+ Upload: uploadLight,
+ Watermark: watermarkLight,
+ Split: themeLight,
+ FloatButton: themeLight$2,
+ FloatButtonGroup: themeLight$3,
+ Marquee: marqueeLight
+};
+const darkTheme = {
+ name: "dark",
+ common: derived$1,
+ Alert: alertDark,
+ Anchor: anchorDark,
+ AutoComplete: autoCompleteDark,
+ Avatar: avatarDark,
+ AvatarGroup: avatarGroupDark,
+ BackTop: backTopDark,
+ Badge: badgeDark,
+ Breadcrumb: breadcrumbDark,
+ Button: buttonDark,
+ ButtonGroup: buttonGroupDark,
+ Calendar: calendarDark,
+ Card: cardDark,
+ Carousel: carouselDark,
+ Cascader: cascaderDark,
+ Checkbox: checkboxDark,
+ Code: codeDark,
+ Collapse: collapseDark,
+ CollapseTransition: collapseTransitionDark,
+ ColorPicker: colorPickerDark,
+ DataTable: dataTableDark,
+ DatePicker: datePickerDark,
+ Descriptions: descriptionsDark,
+ Dialog: dialogDark,
+ Divider: dividerDark,
+ Drawer: drawerDark,
+ Dropdown: dropdownDark,
+ DynamicInput: dynamicInputDark,
+ DynamicTags: dynamicTagsDark,
+ Element: elementDark,
+ Empty: emptyDark,
+ Ellipsis: ellipsisDark,
+ Equation: equationDark,
+ Flex: flexDark,
+ Form: formItemDark,
+ GradientText: gradientTextDark,
+ Icon: iconDark$1,
+ IconWrapper: iconDark,
+ Image: imageDark,
+ Input: inputDark,
+ InputNumber: inputNumberDark,
+ LegacyTransfer: transferDark,
+ Layout: layoutDark,
+ List: listDark$1,
+ LoadingBar: loadingBarDark,
+ Log: logDark,
+ Menu: menuDark,
+ Mention: listDark,
+ Message: messageDark,
+ Modal: modalDark,
+ Notification: notificationDark,
+ PageHeader: pageHeaderDark,
+ Pagination: paginationDark,
+ Popconfirm: popconfirmDark,
+ Popover: popoverDark,
+ Popselect: popselect,
+ Progress: progressDark,
+ QrCode: qrcodeDark,
+ Radio: radioDark,
+ Rate: rateDark,
+ Result: resultDark,
+ Row: rowDark,
+ Scrollbar: scrollbarDark,
+ Select: selectDark,
+ Skeleton: skeletonDark,
+ Slider: sliderDark,
+ Space: spaceDark,
+ Spin: spinDark,
+ Statistic: statisticDark,
+ Steps: stepsDark,
+ Switch: switchDark,
+ Table: tableDark,
+ Tabs: tabsDark,
+ Tag: tagDark,
+ Thing: thingDark,
+ TimePicker: timePickerDark,
+ Timeline: timelineDark,
+ Tooltip: tooltipDark,
+ Transfer: transferDark$1,
+ Tree: treeDark,
+ TreeSelect: treeSelectDark,
+ Typography: typographyDark,
+ Upload: uploadDark,
+ Watermark: watermarkDark,
+ Split: splitDark,
+ FloatButton: floatButtonDark,
+ FloatButtonGroup: floatButtonGroupDark,
+ Marquee: marqueeDark
+};
+const _imports_0 = "" + new URL("icon-mGmYaNg4.png", import.meta.url).href;
+function bind(fn, thisArg) {
+ return function wrap() {
+ return fn.apply(thisArg, arguments);
+ };
+}
+const { toString: toString$1 } = Object.prototype;
+const { getPrototypeOf } = Object;
+const kindOf = /* @__PURE__ */ ((cache2) => (thing) => {
+ const str = toString$1.call(thing);
+ return cache2[str] || (cache2[str] = str.slice(8, -1).toLowerCase());
+})(/* @__PURE__ */ Object.create(null));
+const kindOfTest = (type) => {
+ type = type.toLowerCase();
+ return (thing) => kindOf(thing) === type;
+};
+const typeOfTest = (type) => (thing) => typeof thing === type;
+const { isArray } = Array;
+const isUndefined = typeOfTest("undefined");
+function isBuffer(val) {
+ return val !== null && !isUndefined(val) && val.constructor !== null && !isUndefined(val.constructor) && isFunction(val.constructor.isBuffer) && val.constructor.isBuffer(val);
+}
+const isArrayBuffer = kindOfTest("ArrayBuffer");
+function isArrayBufferView(val) {
+ let result;
+ if (typeof ArrayBuffer !== "undefined" && ArrayBuffer.isView) {
+ result = ArrayBuffer.isView(val);
+ } else {
+ result = val && val.buffer && isArrayBuffer(val.buffer);
+ }
+ return result;
+}
+const isString = typeOfTest("string");
+const isFunction = typeOfTest("function");
+const isNumber = typeOfTest("number");
+const isObject$1 = (thing) => thing !== null && typeof thing === "object";
+const isBoolean = (thing) => thing === true || thing === false;
+const isPlainObject = (val) => {
+ if (kindOf(val) !== "object") {
+ return false;
+ }
+ const prototype2 = getPrototypeOf(val);
+ return (prototype2 === null || prototype2 === Object.prototype || Object.getPrototypeOf(prototype2) === null) && !(Symbol.toStringTag in val) && !(Symbol.iterator in val);
+};
+const isDate = kindOfTest("Date");
+const isFile = kindOfTest("File");
+const isBlob = kindOfTest("Blob");
+const isFileList = kindOfTest("FileList");
+const isStream = (val) => isObject$1(val) && isFunction(val.pipe);
+const isFormData = (thing) => {
+ let kind;
+ return thing && (typeof FormData === "function" && thing instanceof FormData || isFunction(thing.append) && ((kind = kindOf(thing)) === "formdata" || // detect form-data instance
+ kind === "object" && isFunction(thing.toString) && thing.toString() === "[object FormData]"));
+};
+const isURLSearchParams = kindOfTest("URLSearchParams");
+const [isReadableStream, isRequest, isResponse, isHeaders] = ["ReadableStream", "Request", "Response", "Headers"].map(kindOfTest);
+const trim = (str) => str.trim ? str.trim() : str.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
+function forEach(obj, fn, { allOwnKeys = false } = {}) {
+ if (obj === null || typeof obj === "undefined") {
+ return;
+ }
+ let i;
+ let l;
+ if (typeof obj !== "object") {
+ obj = [obj];
+ }
+ if (isArray(obj)) {
+ for (i = 0, l = obj.length; i < l; i++) {
+ fn.call(null, obj[i], i, obj);
+ }
+ } else {
+ const keys = allOwnKeys ? Object.getOwnPropertyNames(obj) : Object.keys(obj);
+ const len = keys.length;
+ let key;
+ for (i = 0; i < len; i++) {
+ key = keys[i];
+ fn.call(null, obj[key], key, obj);
+ }
+ }
+}
+function findKey(obj, key) {
+ key = key.toLowerCase();
+ const keys = Object.keys(obj);
+ let i = keys.length;
+ let _key;
+ while (i-- > 0) {
+ _key = keys[i];
+ if (key === _key.toLowerCase()) {
+ return _key;
+ }
+ }
+ return null;
+}
+const _global$1 = (() => {
+ if (typeof globalThis !== "undefined") return globalThis;
+ return typeof self !== "undefined" ? self : typeof window !== "undefined" ? window : global;
+})();
+const isContextDefined = (context) => !isUndefined(context) && context !== _global$1;
+function merge() {
+ const { caseless } = isContextDefined(this) && this || {};
+ const result = {};
+ const assignValue2 = (val, key) => {
+ const targetKey = caseless && findKey(result, key) || key;
+ if (isPlainObject(result[targetKey]) && isPlainObject(val)) {
+ result[targetKey] = merge(result[targetKey], val);
+ } else if (isPlainObject(val)) {
+ result[targetKey] = merge({}, val);
+ } else if (isArray(val)) {
+ result[targetKey] = val.slice();
+ } else {
+ result[targetKey] = val;
+ }
+ };
+ for (let i = 0, l = arguments.length; i < l; i++) {
+ arguments[i] && forEach(arguments[i], assignValue2);
+ }
+ return result;
+}
+const extend = (a, b, thisArg, { allOwnKeys } = {}) => {
+ forEach(b, (val, key) => {
+ if (thisArg && isFunction(val)) {
+ a[key] = bind(val, thisArg);
+ } else {
+ a[key] = val;
+ }
+ }, { allOwnKeys });
+ return a;
+};
+const stripBOM = (content) => {
+ if (content.charCodeAt(0) === 65279) {
+ content = content.slice(1);
+ }
+ return content;
+};
+const inherits = (constructor, superConstructor, props, descriptors2) => {
+ constructor.prototype = Object.create(superConstructor.prototype, descriptors2);
+ constructor.prototype.constructor = constructor;
+ Object.defineProperty(constructor, "super", {
+ value: superConstructor.prototype
+ });
+ props && Object.assign(constructor.prototype, props);
+};
+const toFlatObject = (sourceObj, destObj, filter2, propFilter) => {
+ let props;
+ let i;
+ let prop;
+ const merged = {};
+ destObj = destObj || {};
+ if (sourceObj == null) return destObj;
+ do {
+ props = Object.getOwnPropertyNames(sourceObj);
+ i = props.length;
+ while (i-- > 0) {
+ prop = props[i];
+ if ((!propFilter || propFilter(prop, sourceObj, destObj)) && !merged[prop]) {
+ destObj[prop] = sourceObj[prop];
+ merged[prop] = true;
+ }
+ }
+ sourceObj = filter2 !== false && getPrototypeOf(sourceObj);
+ } while (sourceObj && (!filter2 || filter2(sourceObj, destObj)) && sourceObj !== Object.prototype);
+ return destObj;
+};
+const endsWith = (str, searchString, position) => {
+ str = String(str);
+ if (position === void 0 || position > str.length) {
+ position = str.length;
+ }
+ position -= searchString.length;
+ const lastIndex = str.indexOf(searchString, position);
+ return lastIndex !== -1 && lastIndex === position;
+};
+const toArray = (thing) => {
+ if (!thing) return null;
+ if (isArray(thing)) return thing;
+ let i = thing.length;
+ if (!isNumber(i)) return null;
+ const arr = new Array(i);
+ while (i-- > 0) {
+ arr[i] = thing[i];
+ }
+ return arr;
+};
+const isTypedArray = /* @__PURE__ */ ((TypedArray) => {
+ return (thing) => {
+ return TypedArray && thing instanceof TypedArray;
+ };
+})(typeof Uint8Array !== "undefined" && getPrototypeOf(Uint8Array));
+const forEachEntry = (obj, fn) => {
+ const generator = obj && obj[Symbol.iterator];
+ const iterator2 = generator.call(obj);
+ let result;
+ while ((result = iterator2.next()) && !result.done) {
+ const pair = result.value;
+ fn.call(obj, pair[0], pair[1]);
+ }
+};
+const matchAll = (regExp, str) => {
+ let matches2;
+ const arr = [];
+ while ((matches2 = regExp.exec(str)) !== null) {
+ arr.push(matches2);
+ }
+ return arr;
+};
+const isHTMLForm = kindOfTest("HTMLFormElement");
+const toCamelCase = (str) => {
+ return str.toLowerCase().replace(
+ /[-_\s]([a-z\d])(\w*)/g,
+ function replacer2(m, p1, p2) {
+ return p1.toUpperCase() + p2;
+ }
+ );
+};
+const hasOwnProperty = (({ hasOwnProperty: hasOwnProperty2 }) => (obj, prop) => hasOwnProperty2.call(obj, prop))(Object.prototype);
+const isRegExp = kindOfTest("RegExp");
+const reduceDescriptors = (obj, reducer) => {
+ const descriptors2 = Object.getOwnPropertyDescriptors(obj);
+ const reducedDescriptors = {};
+ forEach(descriptors2, (descriptor, name2) => {
+ let ret;
+ if ((ret = reducer(descriptor, name2, obj)) !== false) {
+ reducedDescriptors[name2] = ret || descriptor;
+ }
+ });
+ Object.defineProperties(obj, reducedDescriptors);
+};
+const freezeMethods = (obj) => {
+ reduceDescriptors(obj, (descriptor, name2) => {
+ if (isFunction(obj) && ["arguments", "caller", "callee"].indexOf(name2) !== -1) {
+ return false;
+ }
+ const value = obj[name2];
+ if (!isFunction(value)) return;
+ descriptor.enumerable = false;
+ if ("writable" in descriptor) {
+ descriptor.writable = false;
+ return;
+ }
+ if (!descriptor.set) {
+ descriptor.set = () => {
+ throw Error("Can not rewrite read-only method '" + name2 + "'");
+ };
+ }
+ });
+};
+const toObjectSet = (arrayOrString, delimiter) => {
+ const obj = {};
+ const define = (arr) => {
+ arr.forEach((value) => {
+ obj[value] = true;
+ });
+ };
+ isArray(arrayOrString) ? define(arrayOrString) : define(String(arrayOrString).split(delimiter));
+ return obj;
+};
+const noop$1 = () => {
+};
+const toFiniteNumber = (value, defaultValue) => {
+ return value != null && Number.isFinite(value = +value) ? value : defaultValue;
+};
+const ALPHA = "abcdefghijklmnopqrstuvwxyz";
+const DIGIT = "0123456789";
+const ALPHABET = {
+ DIGIT,
+ ALPHA,
+ ALPHA_DIGIT: ALPHA + ALPHA.toUpperCase() + DIGIT
+};
+const generateString = (size2 = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
+ let str = "";
+ const { length } = alphabet;
+ while (size2--) {
+ str += alphabet[Math.random() * length | 0];
+ }
+ return str;
+};
+function isSpecCompliantForm(thing) {
+ return !!(thing && isFunction(thing.append) && thing[Symbol.toStringTag] === "FormData" && thing[Symbol.iterator]);
+}
+const toJSONObject = (obj) => {
+ const stack2 = new Array(10);
+ const visit = (source, i) => {
+ if (isObject$1(source)) {
+ if (stack2.indexOf(source) >= 0) {
+ return;
+ }
+ if (!("toJSON" in source)) {
+ stack2[i] = source;
+ const target = isArray(source) ? [] : {};
+ forEach(source, (value, key) => {
+ const reducedValue = visit(value, i + 1);
+ !isUndefined(reducedValue) && (target[key] = reducedValue);
+ });
+ stack2[i] = void 0;
+ return target;
+ }
+ }
+ return source;
+ };
+ return visit(obj, 0);
+};
+const isAsyncFn = kindOfTest("AsyncFunction");
+const isThenable = (thing) => thing && (isObject$1(thing) || isFunction(thing)) && isFunction(thing.then) && isFunction(thing.catch);
+const _setImmediate = ((setImmediateSupported, postMessageSupported) => {
+ if (setImmediateSupported) {
+ return setImmediate;
+ }
+ return postMessageSupported ? ((token, callbacks2) => {
+ _global$1.addEventListener("message", ({ source, data }) => {
+ if (source === _global$1 && data === token) {
+ callbacks2.length && callbacks2.shift()();
+ }
+ }, false);
+ return (cb) => {
+ callbacks2.push(cb);
+ _global$1.postMessage(token, "*");
+ };
+ })(`axios@${Math.random()}`, []) : (cb) => setTimeout(cb);
+})(
+ typeof setImmediate === "function",
+ isFunction(_global$1.postMessage)
+);
+const asap = typeof queueMicrotask !== "undefined" ? queueMicrotask.bind(_global$1) : typeof process !== "undefined" && process.nextTick || _setImmediate;
+const utils$1 = {
+ isArray,
+ isArrayBuffer,
+ isBuffer,
+ isFormData,
+ isArrayBufferView,
+ isString,
+ isNumber,
+ isBoolean,
+ isObject: isObject$1,
+ isPlainObject,
+ isReadableStream,
+ isRequest,
+ isResponse,
+ isHeaders,
+ isUndefined,
+ isDate,
+ isFile,
+ isBlob,
+ isRegExp,
+ isFunction,
+ isStream,
+ isURLSearchParams,
+ isTypedArray,
+ isFileList,
+ forEach,
+ merge,
+ extend,
+ trim,
+ stripBOM,
+ inherits,
+ toFlatObject,
+ kindOf,
+ kindOfTest,
+ endsWith,
+ toArray,
+ forEachEntry,
+ matchAll,
+ isHTMLForm,
+ hasOwnProperty,
+ hasOwnProp: hasOwnProperty,
+ // an alias to avoid ESLint no-prototype-builtins detection
+ reduceDescriptors,
+ freezeMethods,
+ toObjectSet,
+ toCamelCase,
+ noop: noop$1,
+ toFiniteNumber,
+ findKey,
+ global: _global$1,
+ isContextDefined,
+ ALPHABET,
+ generateString,
+ isSpecCompliantForm,
+ toJSONObject,
+ isAsyncFn,
+ isThenable,
+ setImmediate: _setImmediate,
+ asap
+};
+function AxiosError(message, code, config2, request2, response) {
+ Error.call(this);
+ if (Error.captureStackTrace) {
+ Error.captureStackTrace(this, this.constructor);
+ } else {
+ this.stack = new Error().stack;
+ }
+ this.message = message;
+ this.name = "AxiosError";
+ code && (this.code = code);
+ config2 && (this.config = config2);
+ request2 && (this.request = request2);
+ if (response) {
+ this.response = response;
+ this.status = response.status ? response.status : null;
+ }
+}
+utils$1.inherits(AxiosError, Error, {
+ toJSON: function toJSON() {
+ return {
+ // Standard
+ message: this.message,
+ name: this.name,
+ // Microsoft
+ description: this.description,
+ number: this.number,
+ // Mozilla
+ fileName: this.fileName,
+ lineNumber: this.lineNumber,
+ columnNumber: this.columnNumber,
+ stack: this.stack,
+ // Axios
+ config: utils$1.toJSONObject(this.config),
+ code: this.code,
+ status: this.status
+ };
+ }
+});
+const prototype$1 = AxiosError.prototype;
+const descriptors = {};
+[
+ "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"
+ // eslint-disable-next-line func-names
+].forEach((code) => {
+ descriptors[code] = { value: code };
+});
+Object.defineProperties(AxiosError, descriptors);
+Object.defineProperty(prototype$1, "isAxiosError", { value: true });
+AxiosError.from = (error, code, config2, request2, response, customProps) => {
+ const axiosError = Object.create(prototype$1);
+ utils$1.toFlatObject(error, axiosError, function filter2(obj) {
+ return obj !== Error.prototype;
+ }, (prop) => {
+ return prop !== "isAxiosError";
+ });
+ AxiosError.call(axiosError, error.message, code, config2, request2, response);
+ axiosError.cause = error;
+ axiosError.name = error.name;
+ customProps && Object.assign(axiosError, customProps);
+ return axiosError;
+};
+const httpAdapter = null;
+function isVisitable(thing) {
+ return utils$1.isPlainObject(thing) || utils$1.isArray(thing);
+}
+function removeBrackets(key) {
+ return utils$1.endsWith(key, "[]") ? key.slice(0, -2) : key;
+}
+function renderKey(path, key, dots) {
+ if (!path) return key;
+ return path.concat(key).map(function each(token, i) {
+ token = removeBrackets(token);
+ return !dots && i ? "[" + token + "]" : token;
+ }).join(dots ? "." : "");
+}
+function isFlatArray(arr) {
+ return utils$1.isArray(arr) && !arr.some(isVisitable);
+}
+const predicates = utils$1.toFlatObject(utils$1, {}, null, function filter(prop) {
+ return /^is[A-Z]/.test(prop);
+});
+function toFormData(obj, formData, options) {
+ if (!utils$1.isObject(obj)) {
+ throw new TypeError("target must be an object");
+ }
+ formData = formData || new FormData();
+ options = utils$1.toFlatObject(options, {
+ metaTokens: true,
+ dots: false,
+ indexes: false
+ }, false, function defined(option, source) {
+ return !utils$1.isUndefined(source[option]);
+ });
+ const metaTokens = options.metaTokens;
+ const visitor = options.visitor || defaultVisitor;
+ const dots = options.dots;
+ const indexes = options.indexes;
+ const _Blob = options.Blob || typeof Blob !== "undefined" && Blob;
+ const useBlob = _Blob && utils$1.isSpecCompliantForm(formData);
+ if (!utils$1.isFunction(visitor)) {
+ throw new TypeError("visitor must be a function");
+ }
+ function convertValue(value) {
+ if (value === null) return "";
+ if (utils$1.isDate(value)) {
+ return value.toISOString();
+ }
+ if (!useBlob && utils$1.isBlob(value)) {
+ throw new AxiosError("Blob is not supported. Use a Buffer instead.");
+ }
+ if (utils$1.isArrayBuffer(value) || utils$1.isTypedArray(value)) {
+ return useBlob && typeof Blob === "function" ? new Blob([value]) : Buffer.from(value);
+ }
+ return value;
+ }
+ function defaultVisitor(value, key, path) {
+ let arr = value;
+ if (value && !path && typeof value === "object") {
+ if (utils$1.endsWith(key, "{}")) {
+ key = metaTokens ? key : key.slice(0, -2);
+ value = JSON.stringify(value);
+ } else if (utils$1.isArray(value) && isFlatArray(value) || (utils$1.isFileList(value) || utils$1.endsWith(key, "[]")) && (arr = utils$1.toArray(value))) {
+ key = removeBrackets(key);
+ arr.forEach(function each(el, index) {
+ !(utils$1.isUndefined(el) || el === null) && formData.append(
+ // eslint-disable-next-line no-nested-ternary
+ indexes === true ? renderKey([key], index, dots) : indexes === null ? key : key + "[]",
+ convertValue(el)
+ );
+ });
+ return false;
+ }
+ }
+ if (isVisitable(value)) {
+ return true;
+ }
+ formData.append(renderKey(path, key, dots), convertValue(value));
+ return false;
+ }
+ const stack2 = [];
+ const exposedHelpers = Object.assign(predicates, {
+ defaultVisitor,
+ convertValue,
+ isVisitable
+ });
+ function build2(value, path) {
+ if (utils$1.isUndefined(value)) return;
+ if (stack2.indexOf(value) !== -1) {
+ throw Error("Circular reference detected in " + path.join("."));
+ }
+ stack2.push(value);
+ utils$1.forEach(value, function each(el, key) {
+ const result = !(utils$1.isUndefined(el) || el === null) && visitor.call(
+ formData,
+ el,
+ utils$1.isString(key) ? key.trim() : key,
+ path,
+ exposedHelpers
+ );
+ if (result === true) {
+ build2(el, path ? path.concat(key) : [key]);
+ }
+ });
+ stack2.pop();
+ }
+ if (!utils$1.isObject(obj)) {
+ throw new TypeError("data must be an object");
+ }
+ build2(obj);
+ return formData;
+}
+function encode$1(str) {
+ const charMap = {
+ "!": "%21",
+ "'": "%27",
+ "(": "%28",
+ ")": "%29",
+ "~": "%7E",
+ "%20": "+",
+ "%00": "\0"
+ };
+ return encodeURIComponent(str).replace(/[!'()~]|%20|%00/g, function replacer2(match) {
+ return charMap[match];
+ });
+}
+function AxiosURLSearchParams(params, options) {
+ this._pairs = [];
+ params && toFormData(params, this, options);
+}
+const prototype = AxiosURLSearchParams.prototype;
+prototype.append = function append(name2, value) {
+ this._pairs.push([name2, value]);
+};
+prototype.toString = function toString(encoder) {
+ const _encode = encoder ? function(value) {
+ return encoder.call(this, value, encode$1);
+ } : encode$1;
+ return this._pairs.map(function each(pair) {
+ return _encode(pair[0]) + "=" + _encode(pair[1]);
+ }, "").join("&");
+};
+function encode(val) {
+ return encodeURIComponent(val).replace(/%3A/gi, ":").replace(/%24/g, "$").replace(/%2C/gi, ",").replace(/%20/g, "+").replace(/%5B/gi, "[").replace(/%5D/gi, "]");
+}
+function buildURL(url, params, options) {
+ if (!params) {
+ return url;
+ }
+ const _encode = options && options.encode || encode;
+ if (utils$1.isFunction(options)) {
+ options = {
+ serialize: options
+ };
+ }
+ const serializeFn = options && options.serialize;
+ let serializedParams;
+ if (serializeFn) {
+ serializedParams = serializeFn(params, options);
+ } else {
+ serializedParams = utils$1.isURLSearchParams(params) ? params.toString() : new AxiosURLSearchParams(params, options).toString(_encode);
+ }
+ if (serializedParams) {
+ const hashmarkIndex = url.indexOf("#");
+ if (hashmarkIndex !== -1) {
+ url = url.slice(0, hashmarkIndex);
+ }
+ url += (url.indexOf("?") === -1 ? "?" : "&") + serializedParams;
+ }
+ return url;
+}
+class InterceptorManager {
+ constructor() {
+ this.handlers = [];
+ }
+ /**
+ * Add a new interceptor to the stack
+ *
+ * @param {Function} fulfilled The function to handle `then` for a `Promise`
+ * @param {Function} rejected The function to handle `reject` for a `Promise`
+ *
+ * @return {Number} An ID used to remove interceptor later
+ */
+ use(fulfilled, rejected, options) {
+ this.handlers.push({
+ fulfilled,
+ rejected,
+ synchronous: options ? options.synchronous : false,
+ runWhen: options ? options.runWhen : null
+ });
+ return this.handlers.length - 1;
+ }
+ /**
+ * Remove an interceptor from the stack
+ *
+ * @param {Number} id The ID that was returned by `use`
+ *
+ * @returns {Boolean} `true` if the interceptor was removed, `false` otherwise
+ */
+ eject(id) {
+ if (this.handlers[id]) {
+ this.handlers[id] = null;
+ }
+ }
+ /**
+ * Clear all interceptors from the stack
+ *
+ * @returns {void}
+ */
+ clear() {
+ if (this.handlers) {
+ this.handlers = [];
+ }
+ }
+ /**
+ * Iterate over all the registered interceptors
+ *
+ * This method is particularly useful for skipping over any
+ * interceptors that may have become `null` calling `eject`.
+ *
+ * @param {Function} fn The function to call for each interceptor
+ *
+ * @returns {void}
+ */
+ forEach(fn) {
+ utils$1.forEach(this.handlers, function forEachHandler(h2) {
+ if (h2 !== null) {
+ fn(h2);
+ }
+ });
+ }
+}
+const transitionalDefaults = {
+ silentJSONParsing: true,
+ forcedJSONParsing: true,
+ clarifyTimeoutError: false
+};
+const URLSearchParams$1 = typeof URLSearchParams !== "undefined" ? URLSearchParams : AxiosURLSearchParams;
+const FormData$1 = typeof FormData !== "undefined" ? FormData : null;
+const Blob$1 = typeof Blob !== "undefined" ? Blob : null;
+const platform$1 = {
+ isBrowser: true,
+ classes: {
+ URLSearchParams: URLSearchParams$1,
+ FormData: FormData$1,
+ Blob: Blob$1
+ },
+ protocols: ["http", "https", "file", "blob", "url", "data"]
+};
+const hasBrowserEnv = typeof window !== "undefined" && typeof document !== "undefined";
+const _navigator = typeof navigator === "object" && navigator || void 0;
+const hasStandardBrowserEnv = hasBrowserEnv && (!_navigator || ["ReactNative", "NativeScript", "NS"].indexOf(_navigator.product) < 0);
+const hasStandardBrowserWebWorkerEnv = (() => {
+ return typeof WorkerGlobalScope !== "undefined" && // eslint-disable-next-line no-undef
+ self instanceof WorkerGlobalScope && typeof self.importScripts === "function";
+})();
+const origin = hasBrowserEnv && window.location.href || "http://localhost";
+const utils = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
+ __proto__: null,
+ hasBrowserEnv,
+ hasStandardBrowserEnv,
+ hasStandardBrowserWebWorkerEnv,
+ navigator: _navigator,
+ origin
+}, Symbol.toStringTag, { value: "Module" }));
+const platform = {
+ ...utils,
+ ...platform$1
+};
+function toURLEncodedForm(data, options) {
+ return toFormData(data, new platform.classes.URLSearchParams(), Object.assign({
+ visitor: function(value, key, path, helpers) {
+ if (platform.isNode && utils$1.isBuffer(value)) {
+ this.append(key, value.toString("base64"));
+ return false;
+ }
+ return helpers.defaultVisitor.apply(this, arguments);
+ }
+ }, options));
+}
+function parsePropPath(name2) {
+ return utils$1.matchAll(/\w+|\[(\w*)]/g, name2).map((match) => {
+ return match[0] === "[]" ? "" : match[1] || match[0];
+ });
+}
+function arrayToObject(arr) {
+ const obj = {};
+ const keys = Object.keys(arr);
+ let i;
+ const len = keys.length;
+ let key;
+ for (i = 0; i < len; i++) {
+ key = keys[i];
+ obj[key] = arr[key];
+ }
+ return obj;
+}
+function formDataToJSON(formData) {
+ function buildPath(path, value, target, index) {
+ let name2 = path[index++];
+ if (name2 === "__proto__") return true;
+ const isNumericKey = Number.isFinite(+name2);
+ const isLast = index >= path.length;
+ name2 = !name2 && utils$1.isArray(target) ? target.length : name2;
+ if (isLast) {
+ if (utils$1.hasOwnProp(target, name2)) {
+ target[name2] = [target[name2], value];
+ } else {
+ target[name2] = value;
+ }
+ return !isNumericKey;
+ }
+ if (!target[name2] || !utils$1.isObject(target[name2])) {
+ target[name2] = [];
+ }
+ const result = buildPath(path, value, target[name2], index);
+ if (result && utils$1.isArray(target[name2])) {
+ target[name2] = arrayToObject(target[name2]);
+ }
+ return !isNumericKey;
+ }
+ if (utils$1.isFormData(formData) && utils$1.isFunction(formData.entries)) {
+ const obj = {};
+ utils$1.forEachEntry(formData, (name2, value) => {
+ buildPath(parsePropPath(name2), value, obj, 0);
+ });
+ return obj;
+ }
+ return null;
+}
+function stringifySafely(rawValue, parser, encoder) {
+ if (utils$1.isString(rawValue)) {
+ try {
+ (parser || JSON.parse)(rawValue);
+ return utils$1.trim(rawValue);
+ } catch (e) {
+ if (e.name !== "SyntaxError") {
+ throw e;
+ }
+ }
+ }
+ return (0, JSON.stringify)(rawValue);
+}
+const defaults = {
+ transitional: transitionalDefaults,
+ adapter: ["xhr", "http", "fetch"],
+ transformRequest: [function transformRequest(data, headers) {
+ const contentType = headers.getContentType() || "";
+ const hasJSONContentType = contentType.indexOf("application/json") > -1;
+ const isObjectPayload = utils$1.isObject(data);
+ if (isObjectPayload && utils$1.isHTMLForm(data)) {
+ data = new FormData(data);
+ }
+ const isFormData2 = utils$1.isFormData(data);
+ if (isFormData2) {
+ return hasJSONContentType ? JSON.stringify(formDataToJSON(data)) : data;
+ }
+ if (utils$1.isArrayBuffer(data) || utils$1.isBuffer(data) || utils$1.isStream(data) || utils$1.isFile(data) || utils$1.isBlob(data) || utils$1.isReadableStream(data)) {
+ return data;
+ }
+ if (utils$1.isArrayBufferView(data)) {
+ return data.buffer;
+ }
+ if (utils$1.isURLSearchParams(data)) {
+ headers.setContentType("application/x-www-form-urlencoded;charset=utf-8", false);
+ return data.toString();
+ }
+ let isFileList2;
+ if (isObjectPayload) {
+ if (contentType.indexOf("application/x-www-form-urlencoded") > -1) {
+ return toURLEncodedForm(data, this.formSerializer).toString();
+ }
+ if ((isFileList2 = utils$1.isFileList(data)) || contentType.indexOf("multipart/form-data") > -1) {
+ const _FormData = this.env && this.env.FormData;
+ return toFormData(
+ isFileList2 ? { "files[]": data } : data,
+ _FormData && new _FormData(),
+ this.formSerializer
+ );
+ }
+ }
+ if (isObjectPayload || hasJSONContentType) {
+ headers.setContentType("application/json", false);
+ return stringifySafely(data);
+ }
+ return data;
+ }],
+ transformResponse: [function transformResponse(data) {
+ const transitional2 = this.transitional || defaults.transitional;
+ const forcedJSONParsing = transitional2 && transitional2.forcedJSONParsing;
+ const JSONRequested = this.responseType === "json";
+ if (utils$1.isResponse(data) || utils$1.isReadableStream(data)) {
+ return data;
+ }
+ if (data && utils$1.isString(data) && (forcedJSONParsing && !this.responseType || JSONRequested)) {
+ const silentJSONParsing = transitional2 && transitional2.silentJSONParsing;
+ const strictJSONParsing = !silentJSONParsing && JSONRequested;
+ try {
+ return JSON.parse(data);
+ } catch (e) {
+ if (strictJSONParsing) {
+ if (e.name === "SyntaxError") {
+ throw AxiosError.from(e, AxiosError.ERR_BAD_RESPONSE, this, null, this.response);
+ }
+ throw e;
+ }
+ }
+ }
+ return data;
+ }],
+ /**
+ * A timeout in milliseconds to abort a request. If set to 0 (default) a
+ * timeout is not created.
+ */
+ timeout: 0,
+ xsrfCookieName: "XSRF-TOKEN",
+ xsrfHeaderName: "X-XSRF-TOKEN",
+ maxContentLength: -1,
+ maxBodyLength: -1,
+ env: {
+ FormData: platform.classes.FormData,
+ Blob: platform.classes.Blob
+ },
+ validateStatus: function validateStatus(status) {
+ return status >= 200 && status < 300;
+ },
+ headers: {
+ common: {
+ "Accept": "application/json, text/plain, */*",
+ "Content-Type": void 0
+ }
+ }
+};
+utils$1.forEach(["delete", "get", "head", "post", "put", "patch"], (method) => {
+ defaults.headers[method] = {};
+});
+const ignoreDuplicateOf = utils$1.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"
+]);
+const parseHeaders = (rawHeaders) => {
+ const parsed = {};
+ let key;
+ let val;
+ let i;
+ rawHeaders && rawHeaders.split("\n").forEach(function parser(line) {
+ i = line.indexOf(":");
+ key = line.substring(0, i).trim().toLowerCase();
+ val = line.substring(i + 1).trim();
+ if (!key || parsed[key] && ignoreDuplicateOf[key]) {
+ return;
+ }
+ if (key === "set-cookie") {
+ if (parsed[key]) {
+ parsed[key].push(val);
+ } else {
+ parsed[key] = [val];
+ }
+ } else {
+ parsed[key] = parsed[key] ? parsed[key] + ", " + val : val;
+ }
+ });
+ return parsed;
+};
+const $internals = Symbol("internals");
+function normalizeHeader(header) {
+ return header && String(header).trim().toLowerCase();
+}
+function normalizeValue(value) {
+ if (value === false || value == null) {
+ return value;
+ }
+ return utils$1.isArray(value) ? value.map(normalizeValue) : String(value);
+}
+function parseTokens(str) {
+ const tokens = /* @__PURE__ */ Object.create(null);
+ const tokensRE = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
+ let match;
+ while (match = tokensRE.exec(str)) {
+ tokens[match[1]] = match[2];
+ }
+ return tokens;
+}
+const isValidHeaderName = (str) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(str.trim());
+function matchHeaderValue(context, value, header, filter2, isHeaderNameFilter) {
+ if (utils$1.isFunction(filter2)) {
+ return filter2.call(this, value, header);
+ }
+ if (isHeaderNameFilter) {
+ value = header;
+ }
+ if (!utils$1.isString(value)) return;
+ if (utils$1.isString(filter2)) {
+ return value.indexOf(filter2) !== -1;
+ }
+ if (utils$1.isRegExp(filter2)) {
+ return filter2.test(value);
+ }
+}
+function formatHeader(header) {
+ return header.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (w, char, str) => {
+ return char.toUpperCase() + str;
+ });
+}
+function buildAccessors(obj, header) {
+ const accessorName = utils$1.toCamelCase(" " + header);
+ ["get", "set", "has"].forEach((methodName) => {
+ Object.defineProperty(obj, methodName + accessorName, {
+ value: function(arg1, arg2, arg3) {
+ return this[methodName].call(this, header, arg1, arg2, arg3);
+ },
+ configurable: true
+ });
+ });
+}
+class AxiosHeaders {
+ constructor(headers) {
+ headers && this.set(headers);
+ }
+ set(header, valueOrRewrite, rewrite) {
+ const self2 = this;
+ function setHeader(_value, _header, _rewrite) {
+ const lHeader = normalizeHeader(_header);
+ if (!lHeader) {
+ throw new Error("header name must be a non-empty string");
+ }
+ const key = utils$1.findKey(self2, lHeader);
+ if (!key || self2[key] === void 0 || _rewrite === true || _rewrite === void 0 && self2[key] !== false) {
+ self2[key || _header] = normalizeValue(_value);
+ }
+ }
+ const setHeaders = (headers, _rewrite) => utils$1.forEach(headers, (_value, _header) => setHeader(_value, _header, _rewrite));
+ if (utils$1.isPlainObject(header) || header instanceof this.constructor) {
+ setHeaders(header, valueOrRewrite);
+ } else if (utils$1.isString(header) && (header = header.trim()) && !isValidHeaderName(header)) {
+ setHeaders(parseHeaders(header), valueOrRewrite);
+ } else if (utils$1.isHeaders(header)) {
+ for (const [key, value] of header.entries()) {
+ setHeader(value, key, rewrite);
+ }
+ } else {
+ header != null && setHeader(valueOrRewrite, header, rewrite);
+ }
+ return this;
+ }
+ get(header, parser) {
+ header = normalizeHeader(header);
+ if (header) {
+ const key = utils$1.findKey(this, header);
+ if (key) {
+ const value = this[key];
+ if (!parser) {
+ return value;
+ }
+ if (parser === true) {
+ return parseTokens(value);
+ }
+ if (utils$1.isFunction(parser)) {
+ return parser.call(this, value, key);
+ }
+ if (utils$1.isRegExp(parser)) {
+ return parser.exec(value);
+ }
+ throw new TypeError("parser must be boolean|regexp|function");
+ }
+ }
+ }
+ has(header, matcher) {
+ header = normalizeHeader(header);
+ if (header) {
+ const key = utils$1.findKey(this, header);
+ return !!(key && this[key] !== void 0 && (!matcher || matchHeaderValue(this, this[key], key, matcher)));
+ }
+ return false;
+ }
+ delete(header, matcher) {
+ const self2 = this;
+ let deleted = false;
+ function deleteHeader(_header) {
+ _header = normalizeHeader(_header);
+ if (_header) {
+ const key = utils$1.findKey(self2, _header);
+ if (key && (!matcher || matchHeaderValue(self2, self2[key], key, matcher))) {
+ delete self2[key];
+ deleted = true;
+ }
+ }
+ }
+ if (utils$1.isArray(header)) {
+ header.forEach(deleteHeader);
+ } else {
+ deleteHeader(header);
+ }
+ return deleted;
+ }
+ clear(matcher) {
+ const keys = Object.keys(this);
+ let i = keys.length;
+ let deleted = false;
+ while (i--) {
+ const key = keys[i];
+ if (!matcher || matchHeaderValue(this, this[key], key, matcher, true)) {
+ delete this[key];
+ deleted = true;
+ }
+ }
+ return deleted;
+ }
+ normalize(format) {
+ const self2 = this;
+ const headers = {};
+ utils$1.forEach(this, (value, header) => {
+ const key = utils$1.findKey(headers, header);
+ if (key) {
+ self2[key] = normalizeValue(value);
+ delete self2[header];
+ return;
+ }
+ const normalized = format ? formatHeader(header) : String(header).trim();
+ if (normalized !== header) {
+ delete self2[header];
+ }
+ self2[normalized] = normalizeValue(value);
+ headers[normalized] = true;
+ });
+ return this;
+ }
+ concat(...targets) {
+ return this.constructor.concat(this, ...targets);
+ }
+ toJSON(asStrings) {
+ const obj = /* @__PURE__ */ Object.create(null);
+ utils$1.forEach(this, (value, header) => {
+ value != null && value !== false && (obj[header] = asStrings && utils$1.isArray(value) ? value.join(", ") : value);
+ });
+ return obj;
+ }
+ [Symbol.iterator]() {
+ return Object.entries(this.toJSON())[Symbol.iterator]();
+ }
+ toString() {
+ return Object.entries(this.toJSON()).map(([header, value]) => header + ": " + value).join("\n");
+ }
+ get [Symbol.toStringTag]() {
+ return "AxiosHeaders";
+ }
+ static from(thing) {
+ return thing instanceof this ? thing : new this(thing);
+ }
+ static concat(first, ...targets) {
+ const computed2 = new this(first);
+ targets.forEach((target) => computed2.set(target));
+ return computed2;
+ }
+ static accessor(header) {
+ const internals = this[$internals] = this[$internals] = {
+ accessors: {}
+ };
+ const accessors = internals.accessors;
+ const prototype2 = this.prototype;
+ function defineAccessor(_header) {
+ const lHeader = normalizeHeader(_header);
+ if (!accessors[lHeader]) {
+ buildAccessors(prototype2, _header);
+ accessors[lHeader] = true;
+ }
+ }
+ utils$1.isArray(header) ? header.forEach(defineAccessor) : defineAccessor(header);
+ return this;
+ }
+}
+AxiosHeaders.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
+utils$1.reduceDescriptors(AxiosHeaders.prototype, ({ value }, key) => {
+ let mapped = key[0].toUpperCase() + key.slice(1);
+ return {
+ get: () => value,
+ set(headerValue) {
+ this[mapped] = headerValue;
+ }
+ };
+});
+utils$1.freezeMethods(AxiosHeaders);
+function transformData(fns, response) {
+ const config2 = this || defaults;
+ const context = response || config2;
+ const headers = AxiosHeaders.from(context.headers);
+ let data = context.data;
+ utils$1.forEach(fns, function transform(fn) {
+ data = fn.call(config2, data, headers.normalize(), response ? response.status : void 0);
+ });
+ headers.normalize();
+ return data;
+}
+function isCancel(value) {
+ return !!(value && value.__CANCEL__);
+}
+function CanceledError(message, config2, request2) {
+ AxiosError.call(this, message == null ? "canceled" : message, AxiosError.ERR_CANCELED, config2, request2);
+ this.name = "CanceledError";
+}
+utils$1.inherits(CanceledError, AxiosError, {
+ __CANCEL__: true
+});
+function settle(resolve2, reject, response) {
+ const validateStatus2 = response.config.validateStatus;
+ if (!response.status || !validateStatus2 || validateStatus2(response.status)) {
+ resolve2(response);
+ } else {
+ reject(new AxiosError(
+ "Request failed with status code " + response.status,
+ [AxiosError.ERR_BAD_REQUEST, AxiosError.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
+ response.config,
+ response.request,
+ response
+ ));
+ }
+}
+function parseProtocol(url) {
+ const match = /^([-+\w]{1,25})(:?\/\/|:)/.exec(url);
+ return match && match[1] || "";
+}
+function speedometer(samplesCount, min) {
+ samplesCount = samplesCount || 10;
+ const bytes = new Array(samplesCount);
+ const timestamps = new Array(samplesCount);
+ let head = 0;
+ let tail = 0;
+ let firstSampleTS;
+ min = min !== void 0 ? min : 1e3;
+ return function push(chunkLength) {
+ const now2 = Date.now();
+ const startedAt = timestamps[tail];
+ if (!firstSampleTS) {
+ firstSampleTS = now2;
+ }
+ bytes[head] = chunkLength;
+ timestamps[head] = now2;
+ let i = tail;
+ let bytesCount = 0;
+ while (i !== head) {
+ bytesCount += bytes[i++];
+ i = i % samplesCount;
+ }
+ head = (head + 1) % samplesCount;
+ if (head === tail) {
+ tail = (tail + 1) % samplesCount;
+ }
+ if (now2 - firstSampleTS < min) {
+ return;
+ }
+ const passed = startedAt && now2 - startedAt;
+ return passed ? Math.round(bytesCount * 1e3 / passed) : void 0;
+ };
+}
+function throttle(fn, freq) {
+ let timestamp = 0;
+ let threshold = 1e3 / freq;
+ let lastArgs;
+ let timer;
+ const invoke = (args, now2 = Date.now()) => {
+ timestamp = now2;
+ lastArgs = null;
+ if (timer) {
+ clearTimeout(timer);
+ timer = null;
+ }
+ fn.apply(null, args);
+ };
+ const throttled = (...args) => {
+ const now2 = Date.now();
+ const passed = now2 - timestamp;
+ if (passed >= threshold) {
+ invoke(args, now2);
+ } else {
+ lastArgs = args;
+ if (!timer) {
+ timer = setTimeout(() => {
+ timer = null;
+ invoke(lastArgs);
+ }, threshold - passed);
+ }
+ }
+ };
+ const flush = () => lastArgs && invoke(lastArgs);
+ return [throttled, flush];
+}
+const progressEventReducer = (listener, isDownloadStream, freq = 3) => {
+ let bytesNotified = 0;
+ const _speedometer = speedometer(50, 250);
+ return throttle((e) => {
+ const loaded = e.loaded;
+ const total = e.lengthComputable ? e.total : void 0;
+ const progressBytes = loaded - bytesNotified;
+ const rate = _speedometer(progressBytes);
+ const inRange = loaded <= total;
+ bytesNotified = loaded;
+ const data = {
+ loaded,
+ total,
+ progress: total ? loaded / total : void 0,
+ bytes: progressBytes,
+ rate: rate ? rate : void 0,
+ estimated: rate && total && inRange ? (total - loaded) / rate : void 0,
+ event: e,
+ lengthComputable: total != null,
+ [isDownloadStream ? "download" : "upload"]: true
+ };
+ listener(data);
+ }, freq);
+};
+const progressEventDecorator = (total, throttled) => {
+ const lengthComputable = total != null;
+ return [(loaded) => throttled[0]({
+ lengthComputable,
+ total,
+ loaded
+ }), throttled[1]];
+};
+const asyncDecorator = (fn) => (...args) => utils$1.asap(() => fn(...args));
+const isURLSameOrigin = platform.hasStandardBrowserEnv ? /* @__PURE__ */ ((origin2, isMSIE) => (url) => {
+ url = new URL(url, platform.origin);
+ return origin2.protocol === url.protocol && origin2.host === url.host && (isMSIE || origin2.port === url.port);
+})(
+ new URL(platform.origin),
+ platform.navigator && /(msie|trident)/i.test(platform.navigator.userAgent)
+) : () => true;
+const cookies = platform.hasStandardBrowserEnv ? (
+ // Standard browser envs support document.cookie
+ {
+ write(name2, value, expires, path, domain, secure) {
+ const cookie = [name2 + "=" + encodeURIComponent(value)];
+ utils$1.isNumber(expires) && cookie.push("expires=" + new Date(expires).toGMTString());
+ utils$1.isString(path) && cookie.push("path=" + path);
+ utils$1.isString(domain) && cookie.push("domain=" + domain);
+ secure === true && cookie.push("secure");
+ document.cookie = cookie.join("; ");
+ },
+ read(name2) {
+ const match = document.cookie.match(new RegExp("(^|;\\s*)(" + name2 + ")=([^;]*)"));
+ return match ? decodeURIComponent(match[3]) : null;
+ },
+ remove(name2) {
+ this.write(name2, "", Date.now() - 864e5);
+ }
+ }
+) : (
+ // Non-standard browser env (web workers, react-native) lack needed support.
+ {
+ write() {
+ },
+ read() {
+ return null;
+ },
+ remove() {
+ }
+ }
+);
+function isAbsoluteURL(url) {
+ return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(url);
+}
+function combineURLs(baseURL2, relativeURL) {
+ return relativeURL ? baseURL2.replace(/\/?\/$/, "") + "/" + relativeURL.replace(/^\/+/, "") : baseURL2;
+}
+function buildFullPath(baseURL2, requestedURL) {
+ if (baseURL2 && !isAbsoluteURL(requestedURL)) {
+ return combineURLs(baseURL2, requestedURL);
+ }
+ return requestedURL;
+}
+const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing } : thing;
+function mergeConfig(config1, config2) {
+ config2 = config2 || {};
+ const config3 = {};
+ function getMergedValue(target, source, prop, caseless) {
+ if (utils$1.isPlainObject(target) && utils$1.isPlainObject(source)) {
+ return utils$1.merge.call({ caseless }, target, source);
+ } else if (utils$1.isPlainObject(source)) {
+ return utils$1.merge({}, source);
+ } else if (utils$1.isArray(source)) {
+ return source.slice();
+ }
+ return source;
+ }
+ function mergeDeepProperties(a, b, prop, caseless) {
+ if (!utils$1.isUndefined(b)) {
+ return getMergedValue(a, b, prop, caseless);
+ } else if (!utils$1.isUndefined(a)) {
+ return getMergedValue(void 0, a, prop, caseless);
+ }
+ }
+ function valueFromConfig2(a, b) {
+ if (!utils$1.isUndefined(b)) {
+ return getMergedValue(void 0, b);
+ }
+ }
+ function defaultToConfig2(a, b) {
+ if (!utils$1.isUndefined(b)) {
+ return getMergedValue(void 0, b);
+ } else if (!utils$1.isUndefined(a)) {
+ return getMergedValue(void 0, a);
+ }
+ }
+ function mergeDirectKeys(a, b, prop) {
+ if (prop in config2) {
+ return getMergedValue(a, b);
+ } else if (prop in config1) {
+ return getMergedValue(void 0, a);
+ }
+ }
+ const mergeMap = {
+ url: valueFromConfig2,
+ method: valueFromConfig2,
+ data: valueFromConfig2,
+ baseURL: defaultToConfig2,
+ transformRequest: defaultToConfig2,
+ transformResponse: defaultToConfig2,
+ paramsSerializer: defaultToConfig2,
+ timeout: defaultToConfig2,
+ timeoutMessage: defaultToConfig2,
+ withCredentials: defaultToConfig2,
+ withXSRFToken: defaultToConfig2,
+ adapter: defaultToConfig2,
+ responseType: defaultToConfig2,
+ xsrfCookieName: defaultToConfig2,
+ xsrfHeaderName: defaultToConfig2,
+ onUploadProgress: defaultToConfig2,
+ onDownloadProgress: defaultToConfig2,
+ decompress: defaultToConfig2,
+ maxContentLength: defaultToConfig2,
+ maxBodyLength: defaultToConfig2,
+ beforeRedirect: defaultToConfig2,
+ transport: defaultToConfig2,
+ httpAgent: defaultToConfig2,
+ httpsAgent: defaultToConfig2,
+ cancelToken: defaultToConfig2,
+ socketPath: defaultToConfig2,
+ responseEncoding: defaultToConfig2,
+ validateStatus: mergeDirectKeys,
+ headers: (a, b, prop) => mergeDeepProperties(headersToObject(a), headersToObject(b), prop, true)
+ };
+ utils$1.forEach(Object.keys(Object.assign({}, config1, config2)), function computeConfigValue(prop) {
+ const merge2 = mergeMap[prop] || mergeDeepProperties;
+ const configValue = merge2(config1[prop], config2[prop], prop);
+ utils$1.isUndefined(configValue) && merge2 !== mergeDirectKeys || (config3[prop] = configValue);
+ });
+ return config3;
+}
+const resolveConfig = (config2) => {
+ const newConfig = mergeConfig({}, config2);
+ let { data, withXSRFToken, xsrfHeaderName, xsrfCookieName, headers, auth } = newConfig;
+ newConfig.headers = headers = AxiosHeaders.from(headers);
+ newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url), config2.params, config2.paramsSerializer);
+ if (auth) {
+ headers.set(
+ "Authorization",
+ "Basic " + btoa((auth.username || "") + ":" + (auth.password ? unescape(encodeURIComponent(auth.password)) : ""))
+ );
+ }
+ let contentType;
+ if (utils$1.isFormData(data)) {
+ if (platform.hasStandardBrowserEnv || platform.hasStandardBrowserWebWorkerEnv) {
+ headers.setContentType(void 0);
+ } else if ((contentType = headers.getContentType()) !== false) {
+ const [type, ...tokens] = contentType ? contentType.split(";").map((token) => token.trim()).filter(Boolean) : [];
+ headers.setContentType([type || "multipart/form-data", ...tokens].join("; "));
+ }
+ }
+ if (platform.hasStandardBrowserEnv) {
+ withXSRFToken && utils$1.isFunction(withXSRFToken) && (withXSRFToken = withXSRFToken(newConfig));
+ if (withXSRFToken || withXSRFToken !== false && isURLSameOrigin(newConfig.url)) {
+ const xsrfValue = xsrfHeaderName && xsrfCookieName && cookies.read(xsrfCookieName);
+ if (xsrfValue) {
+ headers.set(xsrfHeaderName, xsrfValue);
+ }
+ }
+ }
+ return newConfig;
+};
+const isXHRAdapterSupported = typeof XMLHttpRequest !== "undefined";
+const xhrAdapter = isXHRAdapterSupported && function(config2) {
+ return new Promise(function dispatchXhrRequest(resolve2, reject) {
+ const _config = resolveConfig(config2);
+ let requestData = _config.data;
+ const requestHeaders = AxiosHeaders.from(_config.headers).normalize();
+ let { responseType, onUploadProgress, onDownloadProgress } = _config;
+ let onCanceled;
+ let uploadThrottled, downloadThrottled;
+ let flushUpload, flushDownload;
+ function done() {
+ flushUpload && flushUpload();
+ flushDownload && flushDownload();
+ _config.cancelToken && _config.cancelToken.unsubscribe(onCanceled);
+ _config.signal && _config.signal.removeEventListener("abort", onCanceled);
+ }
+ let request2 = new XMLHttpRequest();
+ request2.open(_config.method.toUpperCase(), _config.url, true);
+ request2.timeout = _config.timeout;
+ function onloadend() {
+ if (!request2) {
+ return;
+ }
+ const responseHeaders = AxiosHeaders.from(
+ "getAllResponseHeaders" in request2 && request2.getAllResponseHeaders()
+ );
+ const responseData = !responseType || responseType === "text" || responseType === "json" ? request2.responseText : request2.response;
+ const response = {
+ data: responseData,
+ status: request2.status,
+ statusText: request2.statusText,
+ headers: responseHeaders,
+ config: config2,
+ request: request2
+ };
+ settle(function _resolve(value) {
+ resolve2(value);
+ done();
+ }, function _reject(err) {
+ reject(err);
+ done();
+ }, response);
+ request2 = null;
+ }
+ if ("onloadend" in request2) {
+ request2.onloadend = onloadend;
+ } else {
+ request2.onreadystatechange = function handleLoad() {
+ if (!request2 || request2.readyState !== 4) {
+ return;
+ }
+ if (request2.status === 0 && !(request2.responseURL && request2.responseURL.indexOf("file:") === 0)) {
+ return;
+ }
+ setTimeout(onloadend);
+ };
+ }
+ request2.onabort = function handleAbort() {
+ if (!request2) {
+ return;
+ }
+ reject(new AxiosError("Request aborted", AxiosError.ECONNABORTED, config2, request2));
+ request2 = null;
+ };
+ request2.onerror = function handleError2() {
+ reject(new AxiosError("Network Error", AxiosError.ERR_NETWORK, config2, request2));
+ request2 = null;
+ };
+ request2.ontimeout = function handleTimeout() {
+ let timeoutErrorMessage = _config.timeout ? "timeout of " + _config.timeout + "ms exceeded" : "timeout exceeded";
+ const transitional2 = _config.transitional || transitionalDefaults;
+ if (_config.timeoutErrorMessage) {
+ timeoutErrorMessage = _config.timeoutErrorMessage;
+ }
+ reject(new AxiosError(
+ timeoutErrorMessage,
+ transitional2.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED,
+ config2,
+ request2
+ ));
+ request2 = null;
+ };
+ requestData === void 0 && requestHeaders.setContentType(null);
+ if ("setRequestHeader" in request2) {
+ utils$1.forEach(requestHeaders.toJSON(), function setRequestHeader(val, key) {
+ request2.setRequestHeader(key, val);
+ });
+ }
+ if (!utils$1.isUndefined(_config.withCredentials)) {
+ request2.withCredentials = !!_config.withCredentials;
+ }
+ if (responseType && responseType !== "json") {
+ request2.responseType = _config.responseType;
+ }
+ if (onDownloadProgress) {
+ [downloadThrottled, flushDownload] = progressEventReducer(onDownloadProgress, true);
+ request2.addEventListener("progress", downloadThrottled);
+ }
+ if (onUploadProgress && request2.upload) {
+ [uploadThrottled, flushUpload] = progressEventReducer(onUploadProgress);
+ request2.upload.addEventListener("progress", uploadThrottled);
+ request2.upload.addEventListener("loadend", flushUpload);
+ }
+ if (_config.cancelToken || _config.signal) {
+ onCanceled = (cancel) => {
+ if (!request2) {
+ return;
+ }
+ reject(!cancel || cancel.type ? new CanceledError(null, config2, request2) : cancel);
+ request2.abort();
+ request2 = null;
+ };
+ _config.cancelToken && _config.cancelToken.subscribe(onCanceled);
+ if (_config.signal) {
+ _config.signal.aborted ? onCanceled() : _config.signal.addEventListener("abort", onCanceled);
+ }
+ }
+ const protocol = parseProtocol(_config.url);
+ if (protocol && platform.protocols.indexOf(protocol) === -1) {
+ reject(new AxiosError("Unsupported protocol " + protocol + ":", AxiosError.ERR_BAD_REQUEST, config2));
+ return;
+ }
+ request2.send(requestData || null);
+ });
+};
+const composeSignals = (signals, timeout) => {
+ const { length } = signals = signals ? signals.filter(Boolean) : [];
+ if (timeout || length) {
+ let controller = new AbortController();
+ let aborted;
+ const onabort = function(reason) {
+ if (!aborted) {
+ aborted = true;
+ unsubscribe();
+ const err = reason instanceof Error ? reason : this.reason;
+ controller.abort(err instanceof AxiosError ? err : new CanceledError(err instanceof Error ? err.message : err));
+ }
+ };
+ let timer = timeout && setTimeout(() => {
+ timer = null;
+ onabort(new AxiosError(`timeout ${timeout} of ms exceeded`, AxiosError.ETIMEDOUT));
+ }, timeout);
+ const unsubscribe = () => {
+ if (signals) {
+ timer && clearTimeout(timer);
+ timer = null;
+ signals.forEach((signal2) => {
+ signal2.unsubscribe ? signal2.unsubscribe(onabort) : signal2.removeEventListener("abort", onabort);
+ });
+ signals = null;
+ }
+ };
+ signals.forEach((signal2) => signal2.addEventListener("abort", onabort));
+ const { signal } = controller;
+ signal.unsubscribe = () => utils$1.asap(unsubscribe);
+ return signal;
+ }
+};
+const streamChunk = function* (chunk, chunkSize) {
+ let len = chunk.byteLength;
+ if (len < chunkSize) {
+ yield chunk;
+ return;
+ }
+ let pos = 0;
+ let end;
+ while (pos < len) {
+ end = pos + chunkSize;
+ yield chunk.slice(pos, end);
+ pos = end;
+ }
+};
+const readBytes = async function* (iterable, chunkSize) {
+ for await (const chunk of readStream(iterable)) {
+ yield* streamChunk(chunk, chunkSize);
+ }
+};
+const readStream = async function* (stream) {
+ if (stream[Symbol.asyncIterator]) {
+ yield* stream;
+ return;
+ }
+ const reader = stream.getReader();
+ try {
+ for (; ; ) {
+ const { done, value } = await reader.read();
+ if (done) {
+ break;
+ }
+ yield value;
+ }
+ } finally {
+ await reader.cancel();
+ }
+};
+const trackStream = (stream, chunkSize, onProgress, onFinish) => {
+ const iterator2 = readBytes(stream, chunkSize);
+ let bytes = 0;
+ let done;
+ let _onFinish = (e) => {
+ if (!done) {
+ done = true;
+ onFinish && onFinish(e);
+ }
+ };
+ return new ReadableStream({
+ async pull(controller) {
+ try {
+ const { done: done2, value } = await iterator2.next();
+ if (done2) {
+ _onFinish();
+ controller.close();
+ return;
+ }
+ let len = value.byteLength;
+ if (onProgress) {
+ let loadedBytes = bytes += len;
+ onProgress(loadedBytes);
+ }
+ controller.enqueue(new Uint8Array(value));
+ } catch (err) {
+ _onFinish(err);
+ throw err;
+ }
+ },
+ cancel(reason) {
+ _onFinish(reason);
+ return iterator2.return();
+ }
+ }, {
+ highWaterMark: 2
+ });
+};
+const isFetchSupported = typeof fetch === "function" && typeof Request === "function" && typeof Response === "function";
+const isReadableStreamSupported = isFetchSupported && typeof ReadableStream === "function";
+const encodeText = isFetchSupported && (typeof TextEncoder === "function" ? /* @__PURE__ */ ((encoder) => (str) => encoder.encode(str))(new TextEncoder()) : async (str) => new Uint8Array(await new Response(str).arrayBuffer()));
+const test = (fn, ...args) => {
+ try {
+ return !!fn(...args);
+ } catch (e) {
+ return false;
+ }
+};
+const supportsRequestStream = isReadableStreamSupported && test(() => {
+ let duplexAccessed = false;
+ const hasContentType = new Request(platform.origin, {
+ body: new ReadableStream(),
+ method: "POST",
+ get duplex() {
+ duplexAccessed = true;
+ return "half";
+ }
+ }).headers.has("Content-Type");
+ return duplexAccessed && !hasContentType;
+});
+const DEFAULT_CHUNK_SIZE = 64 * 1024;
+const supportsResponseStream = isReadableStreamSupported && test(() => utils$1.isReadableStream(new Response("").body));
+const resolvers = {
+ stream: supportsResponseStream && ((res) => res.body)
+};
+isFetchSupported && ((res) => {
+ ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((type) => {
+ !resolvers[type] && (resolvers[type] = utils$1.isFunction(res[type]) ? (res2) => res2[type]() : (_, config2) => {
+ throw new AxiosError(`Response type '${type}' is not supported`, AxiosError.ERR_NOT_SUPPORT, config2);
+ });
+ });
+})(new Response());
+const getBodyLength = async (body) => {
+ if (body == null) {
+ return 0;
+ }
+ if (utils$1.isBlob(body)) {
+ return body.size;
+ }
+ if (utils$1.isSpecCompliantForm(body)) {
+ const _request = new Request(platform.origin, {
+ method: "POST",
+ body
+ });
+ return (await _request.arrayBuffer()).byteLength;
+ }
+ if (utils$1.isArrayBufferView(body) || utils$1.isArrayBuffer(body)) {
+ return body.byteLength;
+ }
+ if (utils$1.isURLSearchParams(body)) {
+ body = body + "";
+ }
+ if (utils$1.isString(body)) {
+ return (await encodeText(body)).byteLength;
+ }
+};
+const resolveBodyLength = async (headers, body) => {
+ const length = utils$1.toFiniteNumber(headers.getContentLength());
+ return length == null ? getBodyLength(body) : length;
+};
+const fetchAdapter = isFetchSupported && (async (config2) => {
+ let {
+ url,
+ method,
+ data,
+ signal,
+ cancelToken,
+ timeout,
+ onDownloadProgress,
+ onUploadProgress,
+ responseType,
+ headers,
+ withCredentials = "same-origin",
+ fetchOptions
+ } = resolveConfig(config2);
+ responseType = responseType ? (responseType + "").toLowerCase() : "text";
+ let composedSignal = composeSignals([signal, cancelToken && cancelToken.toAbortSignal()], timeout);
+ let request2;
+ const unsubscribe = composedSignal && composedSignal.unsubscribe && (() => {
+ composedSignal.unsubscribe();
+ });
+ let requestContentLength;
+ try {
+ if (onUploadProgress && supportsRequestStream && method !== "get" && method !== "head" && (requestContentLength = await resolveBodyLength(headers, data)) !== 0) {
+ let _request = new Request(url, {
+ method: "POST",
+ body: data,
+ duplex: "half"
+ });
+ let contentTypeHeader;
+ if (utils$1.isFormData(data) && (contentTypeHeader = _request.headers.get("content-type"))) {
+ headers.setContentType(contentTypeHeader);
+ }
+ if (_request.body) {
+ const [onProgress, flush] = progressEventDecorator(
+ requestContentLength,
+ progressEventReducer(asyncDecorator(onUploadProgress))
+ );
+ data = trackStream(_request.body, DEFAULT_CHUNK_SIZE, onProgress, flush);
+ }
+ }
+ if (!utils$1.isString(withCredentials)) {
+ withCredentials = withCredentials ? "include" : "omit";
+ }
+ const isCredentialsSupported = "credentials" in Request.prototype;
+ request2 = new Request(url, {
+ ...fetchOptions,
+ signal: composedSignal,
+ method: method.toUpperCase(),
+ headers: headers.normalize().toJSON(),
+ body: data,
+ duplex: "half",
+ credentials: isCredentialsSupported ? withCredentials : void 0
+ });
+ let response = await fetch(request2);
+ const isStreamResponse = supportsResponseStream && (responseType === "stream" || responseType === "response");
+ if (supportsResponseStream && (onDownloadProgress || isStreamResponse && unsubscribe)) {
+ const options = {};
+ ["status", "statusText", "headers"].forEach((prop) => {
+ options[prop] = response[prop];
+ });
+ const responseContentLength = utils$1.toFiniteNumber(response.headers.get("content-length"));
+ const [onProgress, flush] = onDownloadProgress && progressEventDecorator(
+ responseContentLength,
+ progressEventReducer(asyncDecorator(onDownloadProgress), true)
+ ) || [];
+ response = new Response(
+ trackStream(response.body, DEFAULT_CHUNK_SIZE, onProgress, () => {
+ flush && flush();
+ unsubscribe && unsubscribe();
+ }),
+ options
+ );
+ }
+ responseType = responseType || "text";
+ let responseData = await resolvers[utils$1.findKey(resolvers, responseType) || "text"](response, config2);
+ !isStreamResponse && unsubscribe && unsubscribe();
+ return await new Promise((resolve2, reject) => {
+ settle(resolve2, reject, {
+ data: responseData,
+ headers: AxiosHeaders.from(response.headers),
+ status: response.status,
+ statusText: response.statusText,
+ config: config2,
+ request: request2
+ });
+ });
+ } catch (err) {
+ unsubscribe && unsubscribe();
+ if (err && err.name === "TypeError" && /fetch/i.test(err.message)) {
+ throw Object.assign(
+ new AxiosError("Network Error", AxiosError.ERR_NETWORK, config2, request2),
+ {
+ cause: err.cause || err
+ }
+ );
+ }
+ throw AxiosError.from(err, err && err.code, config2, request2);
+ }
+});
+const knownAdapters = {
+ http: httpAdapter,
+ xhr: xhrAdapter,
+ fetch: fetchAdapter
+};
+utils$1.forEach(knownAdapters, (fn, value) => {
+ if (fn) {
+ try {
+ Object.defineProperty(fn, "name", { value });
+ } catch (e) {
+ }
+ Object.defineProperty(fn, "adapterName", { value });
+ }
+});
+const renderReason = (reason) => `- ${reason}`;
+const isResolvedHandle = (adapter) => utils$1.isFunction(adapter) || adapter === null || adapter === false;
+const adapters = {
+ getAdapter: (adapters2) => {
+ adapters2 = utils$1.isArray(adapters2) ? adapters2 : [adapters2];
+ const { length } = adapters2;
+ let nameOrAdapter;
+ let adapter;
+ const rejectedReasons = {};
+ for (let i = 0; i < length; i++) {
+ nameOrAdapter = adapters2[i];
+ let id;
+ adapter = nameOrAdapter;
+ if (!isResolvedHandle(nameOrAdapter)) {
+ adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
+ if (adapter === void 0) {
+ throw new AxiosError(`Unknown adapter '${id}'`);
+ }
+ }
+ if (adapter) {
+ break;
+ }
+ rejectedReasons[id || "#" + i] = adapter;
+ }
+ if (!adapter) {
+ const reasons = Object.entries(rejectedReasons).map(
+ ([id, state2]) => `adapter ${id} ` + (state2 === false ? "is not supported by the environment" : "is not available in the build")
+ );
+ let s = length ? reasons.length > 1 ? "since :\n" + reasons.map(renderReason).join("\n") : " " + renderReason(reasons[0]) : "as no adapter specified";
+ throw new AxiosError(
+ `There is no suitable adapter to dispatch the request ` + s,
+ "ERR_NOT_SUPPORT"
+ );
+ }
+ return adapter;
+ },
+ adapters: knownAdapters
+};
+function throwIfCancellationRequested(config2) {
+ if (config2.cancelToken) {
+ config2.cancelToken.throwIfRequested();
+ }
+ if (config2.signal && config2.signal.aborted) {
+ throw new CanceledError(null, config2);
+ }
+}
+function dispatchRequest(config2) {
+ throwIfCancellationRequested(config2);
+ config2.headers = AxiosHeaders.from(config2.headers);
+ config2.data = transformData.call(
+ config2,
+ config2.transformRequest
+ );
+ if (["post", "put", "patch"].indexOf(config2.method) !== -1) {
+ config2.headers.setContentType("application/x-www-form-urlencoded", false);
+ }
+ const adapter = adapters.getAdapter(config2.adapter || defaults.adapter);
+ return adapter(config2).then(function onAdapterResolution(response) {
+ throwIfCancellationRequested(config2);
+ response.data = transformData.call(
+ config2,
+ config2.transformResponse,
+ response
+ );
+ response.headers = AxiosHeaders.from(response.headers);
+ return response;
+ }, function onAdapterRejection(reason) {
+ if (!isCancel(reason)) {
+ throwIfCancellationRequested(config2);
+ if (reason && reason.response) {
+ reason.response.data = transformData.call(
+ config2,
+ config2.transformResponse,
+ reason.response
+ );
+ reason.response.headers = AxiosHeaders.from(reason.response.headers);
+ }
+ }
+ return Promise.reject(reason);
+ });
+}
+const VERSION = "1.7.9";
+const validators$1 = {};
+["object", "boolean", "number", "function", "string", "symbol"].forEach((type, i) => {
+ validators$1[type] = function validator2(thing) {
+ return typeof thing === type || "a" + (i < 1 ? "n " : " ") + type;
+ };
+});
+const deprecatedWarnings = {};
+validators$1.transitional = function transitional(validator2, version2, message) {
+ function formatMessage(opt, desc) {
+ return "[Axios v" + VERSION + "] Transitional option '" + opt + "'" + desc + (message ? ". " + message : "");
+ }
+ return (value, opt, opts) => {
+ if (validator2 === false) {
+ throw new AxiosError(
+ formatMessage(opt, " has been removed" + (version2 ? " in " + version2 : "")),
+ AxiosError.ERR_DEPRECATED
+ );
+ }
+ if (version2 && !deprecatedWarnings[opt]) {
+ deprecatedWarnings[opt] = true;
+ console.warn(
+ formatMessage(
+ opt,
+ " has been deprecated since v" + version2 + " and will be removed in the near future"
+ )
+ );
+ }
+ return validator2 ? validator2(value, opt, opts) : true;
+ };
+};
+validators$1.spelling = function spelling(correctSpelling) {
+ return (value, opt) => {
+ console.warn(`${opt} is likely a misspelling of ${correctSpelling}`);
+ return true;
+ };
+};
+function assertOptions(options, schema, allowUnknown) {
+ if (typeof options !== "object") {
+ throw new AxiosError("options must be an object", AxiosError.ERR_BAD_OPTION_VALUE);
+ }
+ const keys = Object.keys(options);
+ let i = keys.length;
+ while (i-- > 0) {
+ const opt = keys[i];
+ const validator2 = schema[opt];
+ if (validator2) {
+ const value = options[opt];
+ const result = value === void 0 || validator2(value, opt, options);
+ if (result !== true) {
+ throw new AxiosError("option " + opt + " must be " + result, AxiosError.ERR_BAD_OPTION_VALUE);
+ }
+ continue;
+ }
+ if (allowUnknown !== true) {
+ throw new AxiosError("Unknown option " + opt, AxiosError.ERR_BAD_OPTION);
+ }
+ }
+}
+const validator = {
+ assertOptions,
+ validators: validators$1
+};
+const validators = validator.validators;
+class Axios {
+ constructor(instanceConfig) {
+ this.defaults = instanceConfig;
+ this.interceptors = {
+ request: new InterceptorManager(),
+ response: new InterceptorManager()
+ };
+ }
+ /**
+ * Dispatch a request
+ *
+ * @param {String|Object} configOrUrl The config specific for this request (merged with this.defaults)
+ * @param {?Object} config
+ *
+ * @returns {Promise} The Promise to be fulfilled
+ */
+ async request(configOrUrl, config2) {
+ try {
+ return await this._request(configOrUrl, config2);
+ } catch (err) {
+ if (err instanceof Error) {
+ let dummy = {};
+ Error.captureStackTrace ? Error.captureStackTrace(dummy) : dummy = new Error();
+ const stack2 = dummy.stack ? dummy.stack.replace(/^.+\n/, "") : "";
+ try {
+ if (!err.stack) {
+ err.stack = stack2;
+ } else if (stack2 && !String(err.stack).endsWith(stack2.replace(/^.+\n.+\n/, ""))) {
+ err.stack += "\n" + stack2;
+ }
+ } catch (e) {
+ }
+ }
+ throw err;
+ }
+ }
+ _request(configOrUrl, config2) {
+ if (typeof configOrUrl === "string") {
+ config2 = config2 || {};
+ config2.url = configOrUrl;
+ } else {
+ config2 = configOrUrl || {};
+ }
+ config2 = mergeConfig(this.defaults, config2);
+ const { transitional: transitional2, paramsSerializer, headers } = config2;
+ if (transitional2 !== void 0) {
+ validator.assertOptions(transitional2, {
+ silentJSONParsing: validators.transitional(validators.boolean),
+ forcedJSONParsing: validators.transitional(validators.boolean),
+ clarifyTimeoutError: validators.transitional(validators.boolean)
+ }, false);
+ }
+ if (paramsSerializer != null) {
+ if (utils$1.isFunction(paramsSerializer)) {
+ config2.paramsSerializer = {
+ serialize: paramsSerializer
+ };
+ } else {
+ validator.assertOptions(paramsSerializer, {
+ encode: validators.function,
+ serialize: validators.function
+ }, true);
+ }
+ }
+ validator.assertOptions(config2, {
+ baseUrl: validators.spelling("baseURL"),
+ withXsrfToken: validators.spelling("withXSRFToken")
+ }, true);
+ config2.method = (config2.method || this.defaults.method || "get").toLowerCase();
+ let contextHeaders = headers && utils$1.merge(
+ headers.common,
+ headers[config2.method]
+ );
+ headers && utils$1.forEach(
+ ["delete", "get", "head", "post", "put", "patch", "common"],
+ (method) => {
+ delete headers[method];
+ }
+ );
+ config2.headers = AxiosHeaders.concat(contextHeaders, headers);
+ const requestInterceptorChain = [];
+ let synchronousRequestInterceptors = true;
+ this.interceptors.request.forEach(function unshiftRequestInterceptors(interceptor) {
+ if (typeof interceptor.runWhen === "function" && interceptor.runWhen(config2) === false) {
+ return;
+ }
+ synchronousRequestInterceptors = synchronousRequestInterceptors && interceptor.synchronous;
+ requestInterceptorChain.unshift(interceptor.fulfilled, interceptor.rejected);
+ });
+ const responseInterceptorChain = [];
+ this.interceptors.response.forEach(function pushResponseInterceptors(interceptor) {
+ responseInterceptorChain.push(interceptor.fulfilled, interceptor.rejected);
+ });
+ let promise;
+ let i = 0;
+ let len;
+ if (!synchronousRequestInterceptors) {
+ const chain = [dispatchRequest.bind(this), void 0];
+ chain.unshift.apply(chain, requestInterceptorChain);
+ chain.push.apply(chain, responseInterceptorChain);
+ len = chain.length;
+ promise = Promise.resolve(config2);
+ while (i < len) {
+ promise = promise.then(chain[i++], chain[i++]);
+ }
+ return promise;
+ }
+ len = requestInterceptorChain.length;
+ let newConfig = config2;
+ i = 0;
+ while (i < len) {
+ const onFulfilled = requestInterceptorChain[i++];
+ const onRejected = requestInterceptorChain[i++];
+ try {
+ newConfig = onFulfilled(newConfig);
+ } catch (error) {
+ onRejected.call(this, error);
+ break;
+ }
+ }
+ try {
+ promise = dispatchRequest.call(this, newConfig);
+ } catch (error) {
+ return Promise.reject(error);
+ }
+ i = 0;
+ len = responseInterceptorChain.length;
+ while (i < len) {
+ promise = promise.then(responseInterceptorChain[i++], responseInterceptorChain[i++]);
+ }
+ return promise;
+ }
+ getUri(config2) {
+ config2 = mergeConfig(this.defaults, config2);
+ const fullPath = buildFullPath(config2.baseURL, config2.url);
+ return buildURL(fullPath, config2.params, config2.paramsSerializer);
+ }
+}
+utils$1.forEach(["delete", "get", "head", "options"], function forEachMethodNoData(method) {
+ Axios.prototype[method] = function(url, config2) {
+ return this.request(mergeConfig(config2 || {}, {
+ method,
+ url,
+ data: (config2 || {}).data
+ }));
+ };
+});
+utils$1.forEach(["post", "put", "patch"], function forEachMethodWithData(method) {
+ function generateHTTPMethod(isForm) {
+ return function httpMethod(url, data, config2) {
+ return this.request(mergeConfig(config2 || {}, {
+ method,
+ headers: isForm ? {
+ "Content-Type": "multipart/form-data"
+ } : {},
+ url,
+ data
+ }));
+ };
+ }
+ Axios.prototype[method] = generateHTTPMethod();
+ Axios.prototype[method + "Form"] = generateHTTPMethod(true);
+});
+class CancelToken {
+ constructor(executor) {
+ if (typeof executor !== "function") {
+ throw new TypeError("executor must be a function.");
+ }
+ let resolvePromise;
+ this.promise = new Promise(function promiseExecutor(resolve2) {
+ resolvePromise = resolve2;
+ });
+ const token = this;
+ this.promise.then((cancel) => {
+ if (!token._listeners) return;
+ let i = token._listeners.length;
+ while (i-- > 0) {
+ token._listeners[i](cancel);
+ }
+ token._listeners = null;
+ });
+ this.promise.then = (onfulfilled) => {
+ let _resolve;
+ const promise = new Promise((resolve2) => {
+ token.subscribe(resolve2);
+ _resolve = resolve2;
+ }).then(onfulfilled);
+ promise.cancel = function reject() {
+ token.unsubscribe(_resolve);
+ };
+ return promise;
+ };
+ executor(function cancel(message, config2, request2) {
+ if (token.reason) {
+ return;
+ }
+ token.reason = new CanceledError(message, config2, request2);
+ resolvePromise(token.reason);
+ });
+ }
+ /**
+ * Throws a `CanceledError` if cancellation has been requested.
+ */
+ throwIfRequested() {
+ if (this.reason) {
+ throw this.reason;
+ }
+ }
+ /**
+ * Subscribe to the cancel signal
+ */
+ subscribe(listener) {
+ if (this.reason) {
+ listener(this.reason);
+ return;
+ }
+ if (this._listeners) {
+ this._listeners.push(listener);
+ } else {
+ this._listeners = [listener];
+ }
+ }
+ /**
+ * Unsubscribe from the cancel signal
+ */
+ unsubscribe(listener) {
+ if (!this._listeners) {
+ return;
+ }
+ const index = this._listeners.indexOf(listener);
+ if (index !== -1) {
+ this._listeners.splice(index, 1);
+ }
+ }
+ toAbortSignal() {
+ const controller = new AbortController();
+ const abort = (err) => {
+ controller.abort(err);
+ };
+ this.subscribe(abort);
+ controller.signal.unsubscribe = () => this.unsubscribe(abort);
+ return controller.signal;
+ }
+ /**
+ * Returns an object that contains a new `CancelToken` and a function that, when called,
+ * cancels the `CancelToken`.
+ */
+ static source() {
+ let cancel;
+ const token = new CancelToken(function executor(c2) {
+ cancel = c2;
+ });
+ return {
+ token,
+ cancel
+ };
+ }
+}
+function spread(callback) {
+ return function wrap(arr) {
+ return callback.apply(null, arr);
+ };
+}
+function isAxiosError(payload) {
+ return utils$1.isObject(payload) && payload.isAxiosError === true;
+}
+const HttpStatusCode = {
+ 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(HttpStatusCode).forEach(([key, value]) => {
+ HttpStatusCode[value] = key;
+});
+function createInstance(defaultConfig) {
+ const context = new Axios(defaultConfig);
+ const instance = bind(Axios.prototype.request, context);
+ utils$1.extend(instance, Axios.prototype, context, { allOwnKeys: true });
+ utils$1.extend(instance, context, null, { allOwnKeys: true });
+ instance.create = function create(instanceConfig) {
+ return createInstance(mergeConfig(defaultConfig, instanceConfig));
+ };
+ return instance;
+}
+const axios = createInstance(defaults);
+axios.Axios = Axios;
+axios.CanceledError = CanceledError;
+axios.CancelToken = CancelToken;
+axios.isCancel = isCancel;
+axios.VERSION = VERSION;
+axios.toFormData = toFormData;
+axios.AxiosError = AxiosError;
+axios.Cancel = axios.CanceledError;
+axios.all = function all(promises) {
+ return Promise.all(promises);
+};
+axios.spread = spread;
+axios.isAxiosError = isAxiosError;
+axios.mergeConfig = mergeConfig;
+axios.AxiosHeaders = AxiosHeaders;
+axios.formToJSON = (thing) => formDataToJSON(utils$1.isHTMLForm(thing) ? new FormData(thing) : thing);
+axios.getAdapter = adapters.getAdapter;
+axios.HttpStatusCode = HttpStatusCode;
+axios.default = axios;
+const name = "AlgerMusicPlayer";
+const version = "2.6.0";
+const description = "Alger Music Player";
+const author = "Alger ";
+const main = "./out/main/index.js";
+const homepage = "https://github.com/algerkong/AlgerMusicPlayer";
+const scripts = {
+ format: "prettier --write .",
+ lint: "eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts,.vue --fix",
+ "typecheck:node": "tsc --noEmit -p tsconfig.node.json --composite false",
+ "typecheck:web": "vue-tsc --noEmit -p tsconfig.web.json --composite false",
+ typecheck: "npm run typecheck:node && npm run typecheck:web",
+ start: "electron-vite preview",
+ dev: "electron-vite dev",
+ build: "npm run typecheck && electron-vite build",
+ postinstall: "electron-builder install-app-deps",
+ "build:unpack": "npm run build && electron-builder --dir",
+ "build:win": "npm run build && electron-builder --win",
+ "build:mac": "npm run build && electron-builder --mac",
+ "build:linux": "npm run build && electron-builder --linux"
+};
+const dependencies = {
+ "@electron-toolkit/preload": "^3.0.0",
+ "@electron-toolkit/utils": "^3.0.0",
+ "@unblockneteasemusic/server": "^0.27.8-patch.1",
+ "electron-store": "^8.1.0",
+ "electron-updater": "^6.1.7",
+ "netease-cloud-music-api-alger": "^4.25.0"
+};
+const devDependencies = {
+ marked: "^15.0.4",
+ "@electron-toolkit/eslint-config": "^1.0.2",
+ "@electron-toolkit/eslint-config-ts": "^2.0.0",
+ "@electron-toolkit/tsconfig": "^1.0.1",
+ "@rushstack/eslint-patch": "^1.10.3",
+ "@tailwindcss/postcss7-compat": "^2.2.4",
+ "@types/howler": "^2.2.12",
+ "@types/node": "^20.14.8",
+ "@typescript-eslint/eslint-plugin": "^7.0.0",
+ "@typescript-eslint/parser": "^7.0.0",
+ "@vitejs/plugin-vue": "^5.0.5",
+ "@vue/compiler-sfc": "^3.5.0",
+ "@vue/eslint-config-prettier": "^9.0.0",
+ "@vue/eslint-config-typescript": "^13.0.0",
+ "@vue/runtime-core": "^3.5.0",
+ "@vueuse/core": "^11.0.3",
+ "@vueuse/electron": "^11.0.3",
+ autoprefixer: "^10.4.20",
+ axios: "^1.7.7",
+ "cross-env": "^7.0.3",
+ electron: "^31.0.2",
+ "electron-builder": "^24.13.3",
+ "electron-vite": "^2.3.0",
+ eslint: "^8.57.0",
+ "eslint-config-airbnb-base": "^15.0.0",
+ "eslint-config-prettier": "^9.0.0",
+ "eslint-plugin-import": "^2.29.1",
+ "eslint-plugin-prettier": "^5.1.3",
+ "eslint-plugin-simple-import-sort": "^12.0.0",
+ "eslint-plugin-vue": "^9.26.0",
+ "eslint-plugin-vue-scoped-css": "^2.7.2",
+ howler: "^2.2.4",
+ lodash: "^4.17.21",
+ "naive-ui": "^2.39.0",
+ postcss: "^8.4.49",
+ prettier: "^3.3.2",
+ remixicon: "^4.2.0",
+ sass: "^1.82.0",
+ tailwindcss: "^3.4.15",
+ typescript: "^5.5.2",
+ "unplugin-auto-import": "^0.18.2",
+ "unplugin-vue-components": "^0.27.4",
+ vfonts: "^0.1.0",
+ vite: "^5.3.1",
+ "vite-plugin-compression": "^0.5.1",
+ "vite-plugin-vue-devtools": "7.4.0",
+ vue: "^3.4.30",
+ "vue-router": "^4.4.3",
+ "vue-tsc": "^2.0.22",
+ vuex: "^4.1.0"
+};
+const build = {
+ appId: "com.alger.music",
+ productName: "AlgerMusicPlayer",
+ mac: {
+ icon: "resources/icon.icns",
+ target: [
+ {
+ target: "dmg",
+ arch: [
+ "x64",
+ "arm64"
+ ]
+ },
+ {
+ target: "zip",
+ arch: [
+ "x64",
+ "arm64"
+ ]
+ }
+ ]
+ },
+ win: {
+ icon: "resources/favicon.ico",
+ target: [
+ "nsis",
+ "zip"
+ ]
+ },
+ linux: {
+ icon: "resources/icon.png",
+ target: [
+ "AppImage",
+ "deb"
+ ]
+ },
+ nsis: {
+ oneClick: false,
+ allowToChangeInstallationDirectory: true,
+ installerIcon: "resources/favicon.ico",
+ uninstallerIcon: "resources/favicon.ico"
+ }
+};
+const config = {
+ name,
+ version,
+ description,
+ author,
+ main,
+ homepage,
+ scripts,
+ dependencies,
+ devDependencies,
+ build
+};
+var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
+var howler = {};
+/*!
+ * howler.js v2.2.4
+ * howlerjs.com
+ *
+ * (c) 2013-2020, James Simpson of GoldFire Studios
+ * goldfirestudios.com
+ *
+ * MIT License
+ */
+(function(exports2) {
+ (function() {
+ var HowlerGlobal2 = function() {
+ this.init();
+ };
+ HowlerGlobal2.prototype = {
+ /**
+ * Initialize the global Howler object.
+ * @return {Howler}
+ */
+ init: function() {
+ var self2 = this || Howler2;
+ self2._counter = 1e3;
+ self2._html5AudioPool = [];
+ self2.html5PoolSize = 10;
+ self2._codecs = {};
+ self2._howls = [];
+ self2._muted = false;
+ self2._volume = 1;
+ self2._canPlayEvent = "canplaythrough";
+ self2._navigator = typeof window !== "undefined" && window.navigator ? window.navigator : null;
+ self2.masterGain = null;
+ self2.noAudio = false;
+ self2.usingWebAudio = true;
+ self2.autoSuspend = true;
+ self2.ctx = null;
+ self2.autoUnlock = true;
+ self2._setup();
+ return self2;
+ },
+ /**
+ * Get/set the global volume for all sounds.
+ * @param {Float} vol Volume from 0.0 to 1.0.
+ * @return {Howler/Float} Returns self or current volume.
+ */
+ volume: function(vol) {
+ var self2 = this || Howler2;
+ vol = parseFloat(vol);
+ if (!self2.ctx) {
+ setupAudioContext();
+ }
+ if (typeof vol !== "undefined" && vol >= 0 && vol <= 1) {
+ self2._volume = vol;
+ if (self2._muted) {
+ return self2;
+ }
+ if (self2.usingWebAudio) {
+ self2.masterGain.gain.setValueAtTime(vol, Howler2.ctx.currentTime);
+ }
+ for (var i = 0; i < self2._howls.length; i++) {
+ if (!self2._howls[i]._webAudio) {
+ var ids = self2._howls[i]._getSoundIds();
+ for (var j = 0; j < ids.length; j++) {
+ var sound = self2._howls[i]._soundById(ids[j]);
+ if (sound && sound._node) {
+ sound._node.volume = sound._volume * vol;
+ }
+ }
+ }
+ }
+ return self2;
+ }
+ return self2._volume;
+ },
+ /**
+ * Handle muting and unmuting globally.
+ * @param {Boolean} muted Is muted or not.
+ */
+ mute: function(muted) {
+ var self2 = this || Howler2;
+ if (!self2.ctx) {
+ setupAudioContext();
+ }
+ self2._muted = muted;
+ if (self2.usingWebAudio) {
+ self2.masterGain.gain.setValueAtTime(muted ? 0 : self2._volume, Howler2.ctx.currentTime);
+ }
+ for (var i = 0; i < self2._howls.length; i++) {
+ if (!self2._howls[i]._webAudio) {
+ var ids = self2._howls[i]._getSoundIds();
+ for (var j = 0; j < ids.length; j++) {
+ var sound = self2._howls[i]._soundById(ids[j]);
+ if (sound && sound._node) {
+ sound._node.muted = muted ? true : sound._muted;
+ }
+ }
+ }
+ }
+ return self2;
+ },
+ /**
+ * Handle stopping all sounds globally.
+ */
+ stop: function() {
+ var self2 = this || Howler2;
+ for (var i = 0; i < self2._howls.length; i++) {
+ self2._howls[i].stop();
+ }
+ return self2;
+ },
+ /**
+ * Unload and destroy all currently loaded Howl objects.
+ * @return {Howler}
+ */
+ unload: function() {
+ var self2 = this || Howler2;
+ for (var i = self2._howls.length - 1; i >= 0; i--) {
+ self2._howls[i].unload();
+ }
+ if (self2.usingWebAudio && self2.ctx && typeof self2.ctx.close !== "undefined") {
+ self2.ctx.close();
+ self2.ctx = null;
+ setupAudioContext();
+ }
+ return self2;
+ },
+ /**
+ * Check for codec support of specific extension.
+ * @param {String} ext Audio file extention.
+ * @return {Boolean}
+ */
+ codecs: function(ext) {
+ return (this || Howler2)._codecs[ext.replace(/^x-/, "")];
+ },
+ /**
+ * Setup various state values for global tracking.
+ * @return {Howler}
+ */
+ _setup: function() {
+ var self2 = this || Howler2;
+ self2.state = self2.ctx ? self2.ctx.state || "suspended" : "suspended";
+ self2._autoSuspend();
+ if (!self2.usingWebAudio) {
+ if (typeof Audio !== "undefined") {
+ try {
+ var test2 = new Audio();
+ if (typeof test2.oncanplaythrough === "undefined") {
+ self2._canPlayEvent = "canplay";
+ }
+ } catch (e) {
+ self2.noAudio = true;
+ }
+ } else {
+ self2.noAudio = true;
+ }
+ }
+ try {
+ var test2 = new Audio();
+ if (test2.muted) {
+ self2.noAudio = true;
+ }
+ } catch (e) {
+ }
+ if (!self2.noAudio) {
+ self2._setupCodecs();
+ }
+ return self2;
+ },
+ /**
+ * Check for browser support for various codecs and cache the results.
+ * @return {Howler}
+ */
+ _setupCodecs: function() {
+ var self2 = this || Howler2;
+ var audioTest = null;
+ try {
+ audioTest = typeof Audio !== "undefined" ? new Audio() : null;
+ } catch (err) {
+ return self2;
+ }
+ if (!audioTest || typeof audioTest.canPlayType !== "function") {
+ return self2;
+ }
+ var mpegTest = audioTest.canPlayType("audio/mpeg;").replace(/^no$/, "");
+ var ua = self2._navigator ? self2._navigator.userAgent : "";
+ var checkOpera = ua.match(/OPR\/(\d+)/g);
+ var isOldOpera = checkOpera && parseInt(checkOpera[0].split("/")[1], 10) < 33;
+ var checkSafari = ua.indexOf("Safari") !== -1 && ua.indexOf("Chrome") === -1;
+ var safariVersion = ua.match(/Version\/(.*?) /);
+ var isOldSafari = checkSafari && safariVersion && parseInt(safariVersion[1], 10) < 15;
+ self2._codecs = {
+ mp3: !!(!isOldOpera && (mpegTest || audioTest.canPlayType("audio/mp3;").replace(/^no$/, ""))),
+ mpeg: !!mpegTest,
+ opus: !!audioTest.canPlayType('audio/ogg; codecs="opus"').replace(/^no$/, ""),
+ ogg: !!audioTest.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/, ""),
+ oga: !!audioTest.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/, ""),
+ wav: !!(audioTest.canPlayType('audio/wav; codecs="1"') || audioTest.canPlayType("audio/wav")).replace(/^no$/, ""),
+ aac: !!audioTest.canPlayType("audio/aac;").replace(/^no$/, ""),
+ caf: !!audioTest.canPlayType("audio/x-caf;").replace(/^no$/, ""),
+ m4a: !!(audioTest.canPlayType("audio/x-m4a;") || audioTest.canPlayType("audio/m4a;") || audioTest.canPlayType("audio/aac;")).replace(/^no$/, ""),
+ m4b: !!(audioTest.canPlayType("audio/x-m4b;") || audioTest.canPlayType("audio/m4b;") || audioTest.canPlayType("audio/aac;")).replace(/^no$/, ""),
+ mp4: !!(audioTest.canPlayType("audio/x-mp4;") || audioTest.canPlayType("audio/mp4;") || audioTest.canPlayType("audio/aac;")).replace(/^no$/, ""),
+ weba: !!(!isOldSafari && audioTest.canPlayType('audio/webm; codecs="vorbis"').replace(/^no$/, "")),
+ webm: !!(!isOldSafari && audioTest.canPlayType('audio/webm; codecs="vorbis"').replace(/^no$/, "")),
+ dolby: !!audioTest.canPlayType('audio/mp4; codecs="ec-3"').replace(/^no$/, ""),
+ flac: !!(audioTest.canPlayType("audio/x-flac;") || audioTest.canPlayType("audio/flac;")).replace(/^no$/, "")
+ };
+ return self2;
+ },
+ /**
+ * Some browsers/devices will only allow audio to be played after a user interaction.
+ * Attempt to automatically unlock audio on the first user interaction.
+ * Concept from: http://paulbakaus.com/tutorials/html5/web-audio-on-ios/
+ * @return {Howler}
+ */
+ _unlockAudio: function() {
+ var self2 = this || Howler2;
+ if (self2._audioUnlocked || !self2.ctx) {
+ return;
+ }
+ self2._audioUnlocked = false;
+ self2.autoUnlock = false;
+ if (!self2._mobileUnloaded && self2.ctx.sampleRate !== 44100) {
+ self2._mobileUnloaded = true;
+ self2.unload();
+ }
+ self2._scratchBuffer = self2.ctx.createBuffer(1, 1, 22050);
+ var unlock = function(e) {
+ while (self2._html5AudioPool.length < self2.html5PoolSize) {
+ try {
+ var audioNode = new Audio();
+ audioNode._unlocked = true;
+ self2._releaseHtml5Audio(audioNode);
+ } catch (e2) {
+ self2.noAudio = true;
+ break;
+ }
+ }
+ for (var i = 0; i < self2._howls.length; i++) {
+ if (!self2._howls[i]._webAudio) {
+ var ids = self2._howls[i]._getSoundIds();
+ for (var j = 0; j < ids.length; j++) {
+ var sound = self2._howls[i]._soundById(ids[j]);
+ if (sound && sound._node && !sound._node._unlocked) {
+ sound._node._unlocked = true;
+ sound._node.load();
+ }
+ }
+ }
+ }
+ self2._autoResume();
+ var source = self2.ctx.createBufferSource();
+ source.buffer = self2._scratchBuffer;
+ source.connect(self2.ctx.destination);
+ if (typeof source.start === "undefined") {
+ source.noteOn(0);
+ } else {
+ source.start(0);
+ }
+ if (typeof self2.ctx.resume === "function") {
+ self2.ctx.resume();
+ }
+ source.onended = function() {
+ source.disconnect(0);
+ self2._audioUnlocked = true;
+ document.removeEventListener("touchstart", unlock, true);
+ document.removeEventListener("touchend", unlock, true);
+ document.removeEventListener("click", unlock, true);
+ document.removeEventListener("keydown", unlock, true);
+ for (var i2 = 0; i2 < self2._howls.length; i2++) {
+ self2._howls[i2]._emit("unlock");
+ }
+ };
+ };
+ document.addEventListener("touchstart", unlock, true);
+ document.addEventListener("touchend", unlock, true);
+ document.addEventListener("click", unlock, true);
+ document.addEventListener("keydown", unlock, true);
+ return self2;
+ },
+ /**
+ * Get an unlocked HTML5 Audio object from the pool. If none are left,
+ * return a new Audio object and throw a warning.
+ * @return {Audio} HTML5 Audio object.
+ */
+ _obtainHtml5Audio: function() {
+ var self2 = this || Howler2;
+ if (self2._html5AudioPool.length) {
+ return self2._html5AudioPool.pop();
+ }
+ var testPlay = new Audio().play();
+ if (testPlay && typeof Promise !== "undefined" && (testPlay instanceof Promise || typeof testPlay.then === "function")) {
+ testPlay.catch(function() {
+ console.warn("HTML5 Audio pool exhausted, returning potentially locked audio object.");
+ });
+ }
+ return new Audio();
+ },
+ /**
+ * Return an activated HTML5 Audio object to the pool.
+ * @return {Howler}
+ */
+ _releaseHtml5Audio: function(audio) {
+ var self2 = this || Howler2;
+ if (audio._unlocked) {
+ self2._html5AudioPool.push(audio);
+ }
+ return self2;
+ },
+ /**
+ * Automatically suspend the Web Audio AudioContext after no sound has played for 30 seconds.
+ * This saves processing/energy and fixes various browser-specific bugs with audio getting stuck.
+ * @return {Howler}
+ */
+ _autoSuspend: function() {
+ var self2 = this;
+ if (!self2.autoSuspend || !self2.ctx || typeof self2.ctx.suspend === "undefined" || !Howler2.usingWebAudio) {
+ return;
+ }
+ for (var i = 0; i < self2._howls.length; i++) {
+ if (self2._howls[i]._webAudio) {
+ for (var j = 0; j < self2._howls[i]._sounds.length; j++) {
+ if (!self2._howls[i]._sounds[j]._paused) {
+ return self2;
+ }
+ }
+ }
+ }
+ if (self2._suspendTimer) {
+ clearTimeout(self2._suspendTimer);
+ }
+ self2._suspendTimer = setTimeout(function() {
+ if (!self2.autoSuspend) {
+ return;
+ }
+ self2._suspendTimer = null;
+ self2.state = "suspending";
+ var handleSuspension = function() {
+ self2.state = "suspended";
+ if (self2._resumeAfterSuspend) {
+ delete self2._resumeAfterSuspend;
+ self2._autoResume();
+ }
+ };
+ self2.ctx.suspend().then(handleSuspension, handleSuspension);
+ }, 3e4);
+ return self2;
+ },
+ /**
+ * Automatically resume the Web Audio AudioContext when a new sound is played.
+ * @return {Howler}
+ */
+ _autoResume: function() {
+ var self2 = this;
+ if (!self2.ctx || typeof self2.ctx.resume === "undefined" || !Howler2.usingWebAudio) {
+ return;
+ }
+ if (self2.state === "running" && self2.ctx.state !== "interrupted" && self2._suspendTimer) {
+ clearTimeout(self2._suspendTimer);
+ self2._suspendTimer = null;
+ } else if (self2.state === "suspended" || self2.state === "running" && self2.ctx.state === "interrupted") {
+ self2.ctx.resume().then(function() {
+ self2.state = "running";
+ for (var i = 0; i < self2._howls.length; i++) {
+ self2._howls[i]._emit("resume");
+ }
+ });
+ if (self2._suspendTimer) {
+ clearTimeout(self2._suspendTimer);
+ self2._suspendTimer = null;
+ }
+ } else if (self2.state === "suspending") {
+ self2._resumeAfterSuspend = true;
+ }
+ return self2;
+ }
+ };
+ var Howler2 = new HowlerGlobal2();
+ var Howl2 = function(o) {
+ var self2 = this;
+ if (!o.src || o.src.length === 0) {
+ console.error("An array of source files must be passed with any new Howl.");
+ return;
+ }
+ self2.init(o);
+ };
+ Howl2.prototype = {
+ /**
+ * Initialize a new Howl group object.
+ * @param {Object} o Passed in properties for this group.
+ * @return {Howl}
+ */
+ init: function(o) {
+ var self2 = this;
+ if (!Howler2.ctx) {
+ setupAudioContext();
+ }
+ self2._autoplay = o.autoplay || false;
+ self2._format = typeof o.format !== "string" ? o.format : [o.format];
+ self2._html5 = o.html5 || false;
+ self2._muted = o.mute || false;
+ self2._loop = o.loop || false;
+ self2._pool = o.pool || 5;
+ self2._preload = typeof o.preload === "boolean" || o.preload === "metadata" ? o.preload : true;
+ self2._rate = o.rate || 1;
+ self2._sprite = o.sprite || {};
+ self2._src = typeof o.src !== "string" ? o.src : [o.src];
+ self2._volume = o.volume !== void 0 ? o.volume : 1;
+ self2._xhr = {
+ method: o.xhr && o.xhr.method ? o.xhr.method : "GET",
+ headers: o.xhr && o.xhr.headers ? o.xhr.headers : null,
+ withCredentials: o.xhr && o.xhr.withCredentials ? o.xhr.withCredentials : false
+ };
+ self2._duration = 0;
+ self2._state = "unloaded";
+ self2._sounds = [];
+ self2._endTimers = {};
+ self2._queue = [];
+ self2._playLock = false;
+ self2._onend = o.onend ? [{ fn: o.onend }] : [];
+ self2._onfade = o.onfade ? [{ fn: o.onfade }] : [];
+ self2._onload = o.onload ? [{ fn: o.onload }] : [];
+ self2._onloaderror = o.onloaderror ? [{ fn: o.onloaderror }] : [];
+ self2._onplayerror = o.onplayerror ? [{ fn: o.onplayerror }] : [];
+ self2._onpause = o.onpause ? [{ fn: o.onpause }] : [];
+ self2._onplay = o.onplay ? [{ fn: o.onplay }] : [];
+ self2._onstop = o.onstop ? [{ fn: o.onstop }] : [];
+ self2._onmute = o.onmute ? [{ fn: o.onmute }] : [];
+ self2._onvolume = o.onvolume ? [{ fn: o.onvolume }] : [];
+ self2._onrate = o.onrate ? [{ fn: o.onrate }] : [];
+ self2._onseek = o.onseek ? [{ fn: o.onseek }] : [];
+ self2._onunlock = o.onunlock ? [{ fn: o.onunlock }] : [];
+ self2._onresume = [];
+ self2._webAudio = Howler2.usingWebAudio && !self2._html5;
+ if (typeof Howler2.ctx !== "undefined" && Howler2.ctx && Howler2.autoUnlock) {
+ Howler2._unlockAudio();
+ }
+ Howler2._howls.push(self2);
+ if (self2._autoplay) {
+ self2._queue.push({
+ event: "play",
+ action: function() {
+ self2.play();
+ }
+ });
+ }
+ if (self2._preload && self2._preload !== "none") {
+ self2.load();
+ }
+ return self2;
+ },
+ /**
+ * Load the audio file.
+ * @return {Howler}
+ */
+ load: function() {
+ var self2 = this;
+ var url = null;
+ if (Howler2.noAudio) {
+ self2._emit("loaderror", null, "No audio support.");
+ return;
+ }
+ if (typeof self2._src === "string") {
+ self2._src = [self2._src];
+ }
+ for (var i = 0; i < self2._src.length; i++) {
+ var ext, str;
+ if (self2._format && self2._format[i]) {
+ ext = self2._format[i];
+ } else {
+ str = self2._src[i];
+ if (typeof str !== "string") {
+ self2._emit("loaderror", null, "Non-string found in selected audio sources - ignoring.");
+ continue;
+ }
+ ext = /^data:audio\/([^;,]+);/i.exec(str);
+ if (!ext) {
+ ext = /\.([^.]+)$/.exec(str.split("?", 1)[0]);
+ }
+ if (ext) {
+ ext = ext[1].toLowerCase();
+ }
+ }
+ if (!ext) {
+ console.warn('No file extension was found. Consider using the "format" property or specify an extension.');
+ }
+ if (ext && Howler2.codecs(ext)) {
+ url = self2._src[i];
+ break;
+ }
+ }
+ if (!url) {
+ self2._emit("loaderror", null, "No codec support for selected audio sources.");
+ return;
+ }
+ self2._src = url;
+ self2._state = "loading";
+ if (window.location.protocol === "https:" && url.slice(0, 5) === "http:") {
+ self2._html5 = true;
+ self2._webAudio = false;
+ }
+ new Sound2(self2);
+ if (self2._webAudio) {
+ loadBuffer(self2);
+ }
+ return self2;
+ },
+ /**
+ * Play a sound or resume previous playback.
+ * @param {String/Number} sprite Sprite name for sprite playback or sound id to continue previous.
+ * @param {Boolean} internal Internal Use: true prevents event firing.
+ * @return {Number} Sound ID.
+ */
+ play: function(sprite, internal) {
+ var self2 = this;
+ var id = null;
+ if (typeof sprite === "number") {
+ id = sprite;
+ sprite = null;
+ } else if (typeof sprite === "string" && self2._state === "loaded" && !self2._sprite[sprite]) {
+ return null;
+ } else if (typeof sprite === "undefined") {
+ sprite = "__default";
+ if (!self2._playLock) {
+ var num = 0;
+ for (var i = 0; i < self2._sounds.length; i++) {
+ if (self2._sounds[i]._paused && !self2._sounds[i]._ended) {
+ num++;
+ id = self2._sounds[i]._id;
+ }
+ }
+ if (num === 1) {
+ sprite = null;
+ } else {
+ id = null;
+ }
+ }
+ }
+ var sound = id ? self2._soundById(id) : self2._inactiveSound();
+ if (!sound) {
+ return null;
+ }
+ if (id && !sprite) {
+ sprite = sound._sprite || "__default";
+ }
+ if (self2._state !== "loaded") {
+ sound._sprite = sprite;
+ sound._ended = false;
+ var soundId = sound._id;
+ self2._queue.push({
+ event: "play",
+ action: function() {
+ self2.play(soundId);
+ }
+ });
+ return soundId;
+ }
+ if (id && !sound._paused) {
+ if (!internal) {
+ self2._loadQueue("play");
+ }
+ return sound._id;
+ }
+ if (self2._webAudio) {
+ Howler2._autoResume();
+ }
+ var seek = Math.max(0, sound._seek > 0 ? sound._seek : self2._sprite[sprite][0] / 1e3);
+ var duration2 = Math.max(0, (self2._sprite[sprite][0] + self2._sprite[sprite][1]) / 1e3 - seek);
+ var timeout = duration2 * 1e3 / Math.abs(sound._rate);
+ var start = self2._sprite[sprite][0] / 1e3;
+ var stop = (self2._sprite[sprite][0] + self2._sprite[sprite][1]) / 1e3;
+ sound._sprite = sprite;
+ sound._ended = false;
+ var setParams = function() {
+ sound._paused = false;
+ sound._seek = seek;
+ sound._start = start;
+ sound._stop = stop;
+ sound._loop = !!(sound._loop || self2._sprite[sprite][2]);
+ };
+ if (seek >= stop) {
+ self2._ended(sound);
+ return;
+ }
+ var node = sound._node;
+ if (self2._webAudio) {
+ var playWebAudio = function() {
+ self2._playLock = false;
+ setParams();
+ self2._refreshBuffer(sound);
+ var vol = sound._muted || self2._muted ? 0 : sound._volume;
+ node.gain.setValueAtTime(vol, Howler2.ctx.currentTime);
+ sound._playStart = Howler2.ctx.currentTime;
+ if (typeof node.bufferSource.start === "undefined") {
+ sound._loop ? node.bufferSource.noteGrainOn(0, seek, 86400) : node.bufferSource.noteGrainOn(0, seek, duration2);
+ } else {
+ sound._loop ? node.bufferSource.start(0, seek, 86400) : node.bufferSource.start(0, seek, duration2);
+ }
+ if (timeout !== Infinity) {
+ self2._endTimers[sound._id] = setTimeout(self2._ended.bind(self2, sound), timeout);
+ }
+ if (!internal) {
+ setTimeout(function() {
+ self2._emit("play", sound._id);
+ self2._loadQueue();
+ }, 0);
+ }
+ };
+ if (Howler2.state === "running" && Howler2.ctx.state !== "interrupted") {
+ playWebAudio();
+ } else {
+ self2._playLock = true;
+ self2.once("resume", playWebAudio);
+ self2._clearTimer(sound._id);
+ }
+ } else {
+ var playHtml5 = function() {
+ node.currentTime = seek;
+ node.muted = sound._muted || self2._muted || Howler2._muted || node.muted;
+ node.volume = sound._volume * Howler2.volume();
+ node.playbackRate = sound._rate;
+ try {
+ var play = node.play();
+ if (play && typeof Promise !== "undefined" && (play instanceof Promise || typeof play.then === "function")) {
+ self2._playLock = true;
+ setParams();
+ play.then(function() {
+ self2._playLock = false;
+ node._unlocked = true;
+ if (!internal) {
+ self2._emit("play", sound._id);
+ } else {
+ self2._loadQueue();
+ }
+ }).catch(function() {
+ self2._playLock = false;
+ self2._emit("playerror", sound._id, "Playback was unable to start. This is most commonly an issue on mobile devices and Chrome where playback was not within a user interaction.");
+ sound._ended = true;
+ sound._paused = true;
+ });
+ } else if (!internal) {
+ self2._playLock = false;
+ setParams();
+ self2._emit("play", sound._id);
+ }
+ node.playbackRate = sound._rate;
+ if (node.paused) {
+ self2._emit("playerror", sound._id, "Playback was unable to start. This is most commonly an issue on mobile devices and Chrome where playback was not within a user interaction.");
+ return;
+ }
+ if (sprite !== "__default" || sound._loop) {
+ self2._endTimers[sound._id] = setTimeout(self2._ended.bind(self2, sound), timeout);
+ } else {
+ self2._endTimers[sound._id] = function() {
+ self2._ended(sound);
+ node.removeEventListener("ended", self2._endTimers[sound._id], false);
+ };
+ node.addEventListener("ended", self2._endTimers[sound._id], false);
+ }
+ } catch (err) {
+ self2._emit("playerror", sound._id, err);
+ }
+ };
+ if (node.src === "data:audio/wav;base64,UklGRigAAABXQVZFZm10IBIAAAABAAEARKwAAIhYAQACABAAAABkYXRhAgAAAAEA") {
+ node.src = self2._src;
+ node.load();
+ }
+ var loadedNoReadyState = window && window.ejecta || !node.readyState && Howler2._navigator.isCocoonJS;
+ if (node.readyState >= 3 || loadedNoReadyState) {
+ playHtml5();
+ } else {
+ self2._playLock = true;
+ self2._state = "loading";
+ var listener = function() {
+ self2._state = "loaded";
+ playHtml5();
+ node.removeEventListener(Howler2._canPlayEvent, listener, false);
+ };
+ node.addEventListener(Howler2._canPlayEvent, listener, false);
+ self2._clearTimer(sound._id);
+ }
+ }
+ return sound._id;
+ },
+ /**
+ * Pause playback and save current position.
+ * @param {Number} id The sound ID (empty to pause all in group).
+ * @return {Howl}
+ */
+ pause: function(id) {
+ var self2 = this;
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "pause",
+ action: function() {
+ self2.pause(id);
+ }
+ });
+ return self2;
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ self2._clearTimer(ids[i]);
+ var sound = self2._soundById(ids[i]);
+ if (sound && !sound._paused) {
+ sound._seek = self2.seek(ids[i]);
+ sound._rateSeek = 0;
+ sound._paused = true;
+ self2._stopFade(ids[i]);
+ if (sound._node) {
+ if (self2._webAudio) {
+ if (!sound._node.bufferSource) {
+ continue;
+ }
+ if (typeof sound._node.bufferSource.stop === "undefined") {
+ sound._node.bufferSource.noteOff(0);
+ } else {
+ sound._node.bufferSource.stop(0);
+ }
+ self2._cleanBuffer(sound._node);
+ } else if (!isNaN(sound._node.duration) || sound._node.duration === Infinity) {
+ sound._node.pause();
+ }
+ }
+ }
+ if (!arguments[1]) {
+ self2._emit("pause", sound ? sound._id : null);
+ }
+ }
+ return self2;
+ },
+ /**
+ * Stop playback and reset to start.
+ * @param {Number} id The sound ID (empty to stop all in group).
+ * @param {Boolean} internal Internal Use: true prevents event firing.
+ * @return {Howl}
+ */
+ stop: function(id, internal) {
+ var self2 = this;
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "stop",
+ action: function() {
+ self2.stop(id);
+ }
+ });
+ return self2;
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ self2._clearTimer(ids[i]);
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ sound._seek = sound._start || 0;
+ sound._rateSeek = 0;
+ sound._paused = true;
+ sound._ended = true;
+ self2._stopFade(ids[i]);
+ if (sound._node) {
+ if (self2._webAudio) {
+ if (sound._node.bufferSource) {
+ if (typeof sound._node.bufferSource.stop === "undefined") {
+ sound._node.bufferSource.noteOff(0);
+ } else {
+ sound._node.bufferSource.stop(0);
+ }
+ self2._cleanBuffer(sound._node);
+ }
+ } else if (!isNaN(sound._node.duration) || sound._node.duration === Infinity) {
+ sound._node.currentTime = sound._start || 0;
+ sound._node.pause();
+ if (sound._node.duration === Infinity) {
+ self2._clearSound(sound._node);
+ }
+ }
+ }
+ if (!internal) {
+ self2._emit("stop", sound._id);
+ }
+ }
+ }
+ return self2;
+ },
+ /**
+ * Mute/unmute a single sound or all sounds in this Howl group.
+ * @param {Boolean} muted Set to true to mute and false to unmute.
+ * @param {Number} id The sound ID to update (omit to mute/unmute all).
+ * @return {Howl}
+ */
+ mute: function(muted, id) {
+ var self2 = this;
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "mute",
+ action: function() {
+ self2.mute(muted, id);
+ }
+ });
+ return self2;
+ }
+ if (typeof id === "undefined") {
+ if (typeof muted === "boolean") {
+ self2._muted = muted;
+ } else {
+ return self2._muted;
+ }
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ sound._muted = muted;
+ if (sound._interval) {
+ self2._stopFade(sound._id);
+ }
+ if (self2._webAudio && sound._node) {
+ sound._node.gain.setValueAtTime(muted ? 0 : sound._volume, Howler2.ctx.currentTime);
+ } else if (sound._node) {
+ sound._node.muted = Howler2._muted ? true : muted;
+ }
+ self2._emit("mute", sound._id);
+ }
+ }
+ return self2;
+ },
+ /**
+ * Get/set the volume of this sound or of the Howl group. This method can optionally take 0, 1 or 2 arguments.
+ * volume() -> Returns the group's volume value.
+ * volume(id) -> Returns the sound id's current volume.
+ * volume(vol) -> Sets the volume of all sounds in this Howl group.
+ * volume(vol, id) -> Sets the volume of passed sound id.
+ * @return {Howl/Number} Returns self or current volume.
+ */
+ volume: function() {
+ var self2 = this;
+ var args = arguments;
+ var vol, id;
+ if (args.length === 0) {
+ return self2._volume;
+ } else if (args.length === 1 || args.length === 2 && typeof args[1] === "undefined") {
+ var ids = self2._getSoundIds();
+ var index = ids.indexOf(args[0]);
+ if (index >= 0) {
+ id = parseInt(args[0], 10);
+ } else {
+ vol = parseFloat(args[0]);
+ }
+ } else if (args.length >= 2) {
+ vol = parseFloat(args[0]);
+ id = parseInt(args[1], 10);
+ }
+ var sound;
+ if (typeof vol !== "undefined" && vol >= 0 && vol <= 1) {
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "volume",
+ action: function() {
+ self2.volume.apply(self2, args);
+ }
+ });
+ return self2;
+ }
+ if (typeof id === "undefined") {
+ self2._volume = vol;
+ }
+ id = self2._getSoundIds(id);
+ for (var i = 0; i < id.length; i++) {
+ sound = self2._soundById(id[i]);
+ if (sound) {
+ sound._volume = vol;
+ if (!args[2]) {
+ self2._stopFade(id[i]);
+ }
+ if (self2._webAudio && sound._node && !sound._muted) {
+ sound._node.gain.setValueAtTime(vol, Howler2.ctx.currentTime);
+ } else if (sound._node && !sound._muted) {
+ sound._node.volume = vol * Howler2.volume();
+ }
+ self2._emit("volume", sound._id);
+ }
+ }
+ } else {
+ sound = id ? self2._soundById(id) : self2._sounds[0];
+ return sound ? sound._volume : 0;
+ }
+ return self2;
+ },
+ /**
+ * Fade a currently playing sound between two volumes (if no id is passed, all sounds will fade).
+ * @param {Number} from The value to fade from (0.0 to 1.0).
+ * @param {Number} to The volume to fade to (0.0 to 1.0).
+ * @param {Number} len Time in milliseconds to fade.
+ * @param {Number} id The sound id (omit to fade all sounds).
+ * @return {Howl}
+ */
+ fade: function(from, to, len, id) {
+ var self2 = this;
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "fade",
+ action: function() {
+ self2.fade(from, to, len, id);
+ }
+ });
+ return self2;
+ }
+ from = Math.min(Math.max(0, parseFloat(from)), 1);
+ to = Math.min(Math.max(0, parseFloat(to)), 1);
+ len = parseFloat(len);
+ self2.volume(from, id);
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ if (!id) {
+ self2._stopFade(ids[i]);
+ }
+ if (self2._webAudio && !sound._muted) {
+ var currentTime = Howler2.ctx.currentTime;
+ var end = currentTime + len / 1e3;
+ sound._volume = from;
+ sound._node.gain.setValueAtTime(from, currentTime);
+ sound._node.gain.linearRampToValueAtTime(to, end);
+ }
+ self2._startFadeInterval(sound, from, to, len, ids[i], typeof id === "undefined");
+ }
+ }
+ return self2;
+ },
+ /**
+ * Starts the internal interval to fade a sound.
+ * @param {Object} sound Reference to sound to fade.
+ * @param {Number} from The value to fade from (0.0 to 1.0).
+ * @param {Number} to The volume to fade to (0.0 to 1.0).
+ * @param {Number} len Time in milliseconds to fade.
+ * @param {Number} id The sound id to fade.
+ * @param {Boolean} isGroup If true, set the volume on the group.
+ */
+ _startFadeInterval: function(sound, from, to, len, id, isGroup) {
+ var self2 = this;
+ var vol = from;
+ var diff = to - from;
+ var steps = Math.abs(diff / 0.01);
+ var stepLen = Math.max(4, steps > 0 ? len / steps : len);
+ var lastTick = Date.now();
+ sound._fadeTo = to;
+ sound._interval = setInterval(function() {
+ var tick = (Date.now() - lastTick) / len;
+ lastTick = Date.now();
+ vol += diff * tick;
+ vol = Math.round(vol * 100) / 100;
+ if (diff < 0) {
+ vol = Math.max(to, vol);
+ } else {
+ vol = Math.min(to, vol);
+ }
+ if (self2._webAudio) {
+ sound._volume = vol;
+ } else {
+ self2.volume(vol, sound._id, true);
+ }
+ if (isGroup) {
+ self2._volume = vol;
+ }
+ if (to < from && vol <= to || to > from && vol >= to) {
+ clearInterval(sound._interval);
+ sound._interval = null;
+ sound._fadeTo = null;
+ self2.volume(to, sound._id);
+ self2._emit("fade", sound._id);
+ }
+ }, stepLen);
+ },
+ /**
+ * Internal method that stops the currently playing fade when
+ * a new fade starts, volume is changed or the sound is stopped.
+ * @param {Number} id The sound id.
+ * @return {Howl}
+ */
+ _stopFade: function(id) {
+ var self2 = this;
+ var sound = self2._soundById(id);
+ if (sound && sound._interval) {
+ if (self2._webAudio) {
+ sound._node.gain.cancelScheduledValues(Howler2.ctx.currentTime);
+ }
+ clearInterval(sound._interval);
+ sound._interval = null;
+ self2.volume(sound._fadeTo, id);
+ sound._fadeTo = null;
+ self2._emit("fade", id);
+ }
+ return self2;
+ },
+ /**
+ * Get/set the loop parameter on a sound. This method can optionally take 0, 1 or 2 arguments.
+ * loop() -> Returns the group's loop value.
+ * loop(id) -> Returns the sound id's loop value.
+ * loop(loop) -> Sets the loop value for all sounds in this Howl group.
+ * loop(loop, id) -> Sets the loop value of passed sound id.
+ * @return {Howl/Boolean} Returns self or current loop value.
+ */
+ loop: function() {
+ var self2 = this;
+ var args = arguments;
+ var loop, id, sound;
+ if (args.length === 0) {
+ return self2._loop;
+ } else if (args.length === 1) {
+ if (typeof args[0] === "boolean") {
+ loop = args[0];
+ self2._loop = loop;
+ } else {
+ sound = self2._soundById(parseInt(args[0], 10));
+ return sound ? sound._loop : false;
+ }
+ } else if (args.length === 2) {
+ loop = args[0];
+ id = parseInt(args[1], 10);
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ sound = self2._soundById(ids[i]);
+ if (sound) {
+ sound._loop = loop;
+ if (self2._webAudio && sound._node && sound._node.bufferSource) {
+ sound._node.bufferSource.loop = loop;
+ if (loop) {
+ sound._node.bufferSource.loopStart = sound._start || 0;
+ sound._node.bufferSource.loopEnd = sound._stop;
+ if (self2.playing(ids[i])) {
+ self2.pause(ids[i], true);
+ self2.play(ids[i], true);
+ }
+ }
+ }
+ }
+ }
+ return self2;
+ },
+ /**
+ * Get/set the playback rate of a sound. This method can optionally take 0, 1 or 2 arguments.
+ * rate() -> Returns the first sound node's current playback rate.
+ * rate(id) -> Returns the sound id's current playback rate.
+ * rate(rate) -> Sets the playback rate of all sounds in this Howl group.
+ * rate(rate, id) -> Sets the playback rate of passed sound id.
+ * @return {Howl/Number} Returns self or the current playback rate.
+ */
+ rate: function() {
+ var self2 = this;
+ var args = arguments;
+ var rate, id;
+ if (args.length === 0) {
+ id = self2._sounds[0]._id;
+ } else if (args.length === 1) {
+ var ids = self2._getSoundIds();
+ var index = ids.indexOf(args[0]);
+ if (index >= 0) {
+ id = parseInt(args[0], 10);
+ } else {
+ rate = parseFloat(args[0]);
+ }
+ } else if (args.length === 2) {
+ rate = parseFloat(args[0]);
+ id = parseInt(args[1], 10);
+ }
+ var sound;
+ if (typeof rate === "number") {
+ if (self2._state !== "loaded" || self2._playLock) {
+ self2._queue.push({
+ event: "rate",
+ action: function() {
+ self2.rate.apply(self2, args);
+ }
+ });
+ return self2;
+ }
+ if (typeof id === "undefined") {
+ self2._rate = rate;
+ }
+ id = self2._getSoundIds(id);
+ for (var i = 0; i < id.length; i++) {
+ sound = self2._soundById(id[i]);
+ if (sound) {
+ if (self2.playing(id[i])) {
+ sound._rateSeek = self2.seek(id[i]);
+ sound._playStart = self2._webAudio ? Howler2.ctx.currentTime : sound._playStart;
+ }
+ sound._rate = rate;
+ if (self2._webAudio && sound._node && sound._node.bufferSource) {
+ sound._node.bufferSource.playbackRate.setValueAtTime(rate, Howler2.ctx.currentTime);
+ } else if (sound._node) {
+ sound._node.playbackRate = rate;
+ }
+ var seek = self2.seek(id[i]);
+ var duration2 = (self2._sprite[sound._sprite][0] + self2._sprite[sound._sprite][1]) / 1e3 - seek;
+ var timeout = duration2 * 1e3 / Math.abs(sound._rate);
+ if (self2._endTimers[id[i]] || !sound._paused) {
+ self2._clearTimer(id[i]);
+ self2._endTimers[id[i]] = setTimeout(self2._ended.bind(self2, sound), timeout);
+ }
+ self2._emit("rate", sound._id);
+ }
+ }
+ } else {
+ sound = self2._soundById(id);
+ return sound ? sound._rate : self2._rate;
+ }
+ return self2;
+ },
+ /**
+ * Get/set the seek position of a sound. This method can optionally take 0, 1 or 2 arguments.
+ * seek() -> Returns the first sound node's current seek position.
+ * seek(id) -> Returns the sound id's current seek position.
+ * seek(seek) -> Sets the seek position of the first sound node.
+ * seek(seek, id) -> Sets the seek position of passed sound id.
+ * @return {Howl/Number} Returns self or the current seek position.
+ */
+ seek: function() {
+ var self2 = this;
+ var args = arguments;
+ var seek, id;
+ if (args.length === 0) {
+ if (self2._sounds.length) {
+ id = self2._sounds[0]._id;
+ }
+ } else if (args.length === 1) {
+ var ids = self2._getSoundIds();
+ var index = ids.indexOf(args[0]);
+ if (index >= 0) {
+ id = parseInt(args[0], 10);
+ } else if (self2._sounds.length) {
+ id = self2._sounds[0]._id;
+ seek = parseFloat(args[0]);
+ }
+ } else if (args.length === 2) {
+ seek = parseFloat(args[0]);
+ id = parseInt(args[1], 10);
+ }
+ if (typeof id === "undefined") {
+ return 0;
+ }
+ if (typeof seek === "number" && (self2._state !== "loaded" || self2._playLock)) {
+ self2._queue.push({
+ event: "seek",
+ action: function() {
+ self2.seek.apply(self2, args);
+ }
+ });
+ return self2;
+ }
+ var sound = self2._soundById(id);
+ if (sound) {
+ if (typeof seek === "number" && seek >= 0) {
+ var playing = self2.playing(id);
+ if (playing) {
+ self2.pause(id, true);
+ }
+ sound._seek = seek;
+ sound._ended = false;
+ self2._clearTimer(id);
+ if (!self2._webAudio && sound._node && !isNaN(sound._node.duration)) {
+ sound._node.currentTime = seek;
+ }
+ var seekAndEmit = function() {
+ if (playing) {
+ self2.play(id, true);
+ }
+ self2._emit("seek", id);
+ };
+ if (playing && !self2._webAudio) {
+ var emitSeek = function() {
+ if (!self2._playLock) {
+ seekAndEmit();
+ } else {
+ setTimeout(emitSeek, 0);
+ }
+ };
+ setTimeout(emitSeek, 0);
+ } else {
+ seekAndEmit();
+ }
+ } else {
+ if (self2._webAudio) {
+ var realTime = self2.playing(id) ? Howler2.ctx.currentTime - sound._playStart : 0;
+ var rateSeek = sound._rateSeek ? sound._rateSeek - sound._seek : 0;
+ return sound._seek + (rateSeek + realTime * Math.abs(sound._rate));
+ } else {
+ return sound._node.currentTime;
+ }
+ }
+ }
+ return self2;
+ },
+ /**
+ * Check if a specific sound is currently playing or not (if id is provided), or check if at least one of the sounds in the group is playing or not.
+ * @param {Number} id The sound id to check. If none is passed, the whole sound group is checked.
+ * @return {Boolean} True if playing and false if not.
+ */
+ playing: function(id) {
+ var self2 = this;
+ if (typeof id === "number") {
+ var sound = self2._soundById(id);
+ return sound ? !sound._paused : false;
+ }
+ for (var i = 0; i < self2._sounds.length; i++) {
+ if (!self2._sounds[i]._paused) {
+ return true;
+ }
+ }
+ return false;
+ },
+ /**
+ * Get the duration of this sound. Passing a sound id will return the sprite duration.
+ * @param {Number} id The sound id to check. If none is passed, return full source duration.
+ * @return {Number} Audio duration in seconds.
+ */
+ duration: function(id) {
+ var self2 = this;
+ var duration2 = self2._duration;
+ var sound = self2._soundById(id);
+ if (sound) {
+ duration2 = self2._sprite[sound._sprite][1] / 1e3;
+ }
+ return duration2;
+ },
+ /**
+ * Returns the current loaded state of this Howl.
+ * @return {String} 'unloaded', 'loading', 'loaded'
+ */
+ state: function() {
+ return this._state;
+ },
+ /**
+ * Unload and destroy the current Howl object.
+ * This will immediately stop all sound instances attached to this group.
+ */
+ unload: function() {
+ var self2 = this;
+ var sounds = self2._sounds;
+ for (var i = 0; i < sounds.length; i++) {
+ if (!sounds[i]._paused) {
+ self2.stop(sounds[i]._id);
+ }
+ if (!self2._webAudio) {
+ self2._clearSound(sounds[i]._node);
+ sounds[i]._node.removeEventListener("error", sounds[i]._errorFn, false);
+ sounds[i]._node.removeEventListener(Howler2._canPlayEvent, sounds[i]._loadFn, false);
+ sounds[i]._node.removeEventListener("ended", sounds[i]._endFn, false);
+ Howler2._releaseHtml5Audio(sounds[i]._node);
+ }
+ delete sounds[i]._node;
+ self2._clearTimer(sounds[i]._id);
+ }
+ var index = Howler2._howls.indexOf(self2);
+ if (index >= 0) {
+ Howler2._howls.splice(index, 1);
+ }
+ var remCache = true;
+ for (i = 0; i < Howler2._howls.length; i++) {
+ if (Howler2._howls[i]._src === self2._src || self2._src.indexOf(Howler2._howls[i]._src) >= 0) {
+ remCache = false;
+ break;
+ }
+ }
+ if (remCache) {
+ delete cache2[self2._src];
+ }
+ Howler2.noAudio = false;
+ self2._state = "unloaded";
+ self2._sounds = [];
+ self2 = null;
+ return null;
+ },
+ /**
+ * Listen to a custom event.
+ * @param {String} event Event name.
+ * @param {Function} fn Listener to call.
+ * @param {Number} id (optional) Only listen to events for this sound.
+ * @param {Number} once (INTERNAL) Marks event to fire only once.
+ * @return {Howl}
+ */
+ on: function(event, fn, id, once) {
+ var self2 = this;
+ var events2 = self2["_on" + event];
+ if (typeof fn === "function") {
+ events2.push(once ? { id, fn, once } : { id, fn });
+ }
+ return self2;
+ },
+ /**
+ * Remove a custom event. Call without parameters to remove all events.
+ * @param {String} event Event name.
+ * @param {Function} fn Listener to remove. Leave empty to remove all.
+ * @param {Number} id (optional) Only remove events for this sound.
+ * @return {Howl}
+ */
+ off: function(event, fn, id) {
+ var self2 = this;
+ var events2 = self2["_on" + event];
+ var i = 0;
+ if (typeof fn === "number") {
+ id = fn;
+ fn = null;
+ }
+ if (fn || id) {
+ for (i = 0; i < events2.length; i++) {
+ var isId = id === events2[i].id;
+ if (fn === events2[i].fn && isId || !fn && isId) {
+ events2.splice(i, 1);
+ break;
+ }
+ }
+ } else if (event) {
+ self2["_on" + event] = [];
+ } else {
+ var keys = Object.keys(self2);
+ for (i = 0; i < keys.length; i++) {
+ if (keys[i].indexOf("_on") === 0 && Array.isArray(self2[keys[i]])) {
+ self2[keys[i]] = [];
+ }
+ }
+ }
+ return self2;
+ },
+ /**
+ * Listen to a custom event and remove it once fired.
+ * @param {String} event Event name.
+ * @param {Function} fn Listener to call.
+ * @param {Number} id (optional) Only listen to events for this sound.
+ * @return {Howl}
+ */
+ once: function(event, fn, id) {
+ var self2 = this;
+ self2.on(event, fn, id, 1);
+ return self2;
+ },
+ /**
+ * Emit all events of a specific type and pass the sound id.
+ * @param {String} event Event name.
+ * @param {Number} id Sound ID.
+ * @param {Number} msg Message to go with event.
+ * @return {Howl}
+ */
+ _emit: function(event, id, msg2) {
+ var self2 = this;
+ var events2 = self2["_on" + event];
+ for (var i = events2.length - 1; i >= 0; i--) {
+ if (!events2[i].id || events2[i].id === id || event === "load") {
+ setTimeout(function(fn) {
+ fn.call(this, id, msg2);
+ }.bind(self2, events2[i].fn), 0);
+ if (events2[i].once) {
+ self2.off(event, events2[i].fn, events2[i].id);
+ }
+ }
+ }
+ self2._loadQueue(event);
+ return self2;
+ },
+ /**
+ * Queue of actions initiated before the sound has loaded.
+ * These will be called in sequence, with the next only firing
+ * after the previous has finished executing (even if async like play).
+ * @return {Howl}
+ */
+ _loadQueue: function(event) {
+ var self2 = this;
+ if (self2._queue.length > 0) {
+ var task = self2._queue[0];
+ if (task.event === event) {
+ self2._queue.shift();
+ self2._loadQueue();
+ }
+ if (!event) {
+ task.action();
+ }
+ }
+ return self2;
+ },
+ /**
+ * Fired when playback ends at the end of the duration.
+ * @param {Sound} sound The sound object to work with.
+ * @return {Howl}
+ */
+ _ended: function(sound) {
+ var self2 = this;
+ var sprite = sound._sprite;
+ if (!self2._webAudio && sound._node && !sound._node.paused && !sound._node.ended && sound._node.currentTime < sound._stop) {
+ setTimeout(self2._ended.bind(self2, sound), 100);
+ return self2;
+ }
+ var loop = !!(sound._loop || self2._sprite[sprite][2]);
+ self2._emit("end", sound._id);
+ if (!self2._webAudio && loop) {
+ self2.stop(sound._id, true).play(sound._id);
+ }
+ if (self2._webAudio && loop) {
+ self2._emit("play", sound._id);
+ sound._seek = sound._start || 0;
+ sound._rateSeek = 0;
+ sound._playStart = Howler2.ctx.currentTime;
+ var timeout = (sound._stop - sound._start) * 1e3 / Math.abs(sound._rate);
+ self2._endTimers[sound._id] = setTimeout(self2._ended.bind(self2, sound), timeout);
+ }
+ if (self2._webAudio && !loop) {
+ sound._paused = true;
+ sound._ended = true;
+ sound._seek = sound._start || 0;
+ sound._rateSeek = 0;
+ self2._clearTimer(sound._id);
+ self2._cleanBuffer(sound._node);
+ Howler2._autoSuspend();
+ }
+ if (!self2._webAudio && !loop) {
+ self2.stop(sound._id, true);
+ }
+ return self2;
+ },
+ /**
+ * Clear the end timer for a sound playback.
+ * @param {Number} id The sound ID.
+ * @return {Howl}
+ */
+ _clearTimer: function(id) {
+ var self2 = this;
+ if (self2._endTimers[id]) {
+ if (typeof self2._endTimers[id] !== "function") {
+ clearTimeout(self2._endTimers[id]);
+ } else {
+ var sound = self2._soundById(id);
+ if (sound && sound._node) {
+ sound._node.removeEventListener("ended", self2._endTimers[id], false);
+ }
+ }
+ delete self2._endTimers[id];
+ }
+ return self2;
+ },
+ /**
+ * Return the sound identified by this ID, or return null.
+ * @param {Number} id Sound ID
+ * @return {Object} Sound object or null.
+ */
+ _soundById: function(id) {
+ var self2 = this;
+ for (var i = 0; i < self2._sounds.length; i++) {
+ if (id === self2._sounds[i]._id) {
+ return self2._sounds[i];
+ }
+ }
+ return null;
+ },
+ /**
+ * Return an inactive sound from the pool or create a new one.
+ * @return {Sound} Sound playback object.
+ */
+ _inactiveSound: function() {
+ var self2 = this;
+ self2._drain();
+ for (var i = 0; i < self2._sounds.length; i++) {
+ if (self2._sounds[i]._ended) {
+ return self2._sounds[i].reset();
+ }
+ }
+ return new Sound2(self2);
+ },
+ /**
+ * Drain excess inactive sounds from the pool.
+ */
+ _drain: function() {
+ var self2 = this;
+ var limit = self2._pool;
+ var cnt = 0;
+ var i = 0;
+ if (self2._sounds.length < limit) {
+ return;
+ }
+ for (i = 0; i < self2._sounds.length; i++) {
+ if (self2._sounds[i]._ended) {
+ cnt++;
+ }
+ }
+ for (i = self2._sounds.length - 1; i >= 0; i--) {
+ if (cnt <= limit) {
+ return;
+ }
+ if (self2._sounds[i]._ended) {
+ if (self2._webAudio && self2._sounds[i]._node) {
+ self2._sounds[i]._node.disconnect(0);
+ }
+ self2._sounds.splice(i, 1);
+ cnt--;
+ }
+ }
+ },
+ /**
+ * Get all ID's from the sounds pool.
+ * @param {Number} id Only return one ID if one is passed.
+ * @return {Array} Array of IDs.
+ */
+ _getSoundIds: function(id) {
+ var self2 = this;
+ if (typeof id === "undefined") {
+ var ids = [];
+ for (var i = 0; i < self2._sounds.length; i++) {
+ ids.push(self2._sounds[i]._id);
+ }
+ return ids;
+ } else {
+ return [id];
+ }
+ },
+ /**
+ * Load the sound back into the buffer source.
+ * @param {Sound} sound The sound object to work with.
+ * @return {Howl}
+ */
+ _refreshBuffer: function(sound) {
+ var self2 = this;
+ sound._node.bufferSource = Howler2.ctx.createBufferSource();
+ sound._node.bufferSource.buffer = cache2[self2._src];
+ if (sound._panner) {
+ sound._node.bufferSource.connect(sound._panner);
+ } else {
+ sound._node.bufferSource.connect(sound._node);
+ }
+ sound._node.bufferSource.loop = sound._loop;
+ if (sound._loop) {
+ sound._node.bufferSource.loopStart = sound._start || 0;
+ sound._node.bufferSource.loopEnd = sound._stop || 0;
+ }
+ sound._node.bufferSource.playbackRate.setValueAtTime(sound._rate, Howler2.ctx.currentTime);
+ return self2;
+ },
+ /**
+ * Prevent memory leaks by cleaning up the buffer source after playback.
+ * @param {Object} node Sound's audio node containing the buffer source.
+ * @return {Howl}
+ */
+ _cleanBuffer: function(node) {
+ var self2 = this;
+ var isIOS = Howler2._navigator && Howler2._navigator.vendor.indexOf("Apple") >= 0;
+ if (!node.bufferSource) {
+ return self2;
+ }
+ if (Howler2._scratchBuffer && node.bufferSource) {
+ node.bufferSource.onended = null;
+ node.bufferSource.disconnect(0);
+ if (isIOS) {
+ try {
+ node.bufferSource.buffer = Howler2._scratchBuffer;
+ } catch (e) {
+ }
+ }
+ }
+ node.bufferSource = null;
+ return self2;
+ },
+ /**
+ * Set the source to a 0-second silence to stop any downloading (except in IE).
+ * @param {Object} node Audio node to clear.
+ */
+ _clearSound: function(node) {
+ var checkIE = /MSIE |Trident\//.test(Howler2._navigator && Howler2._navigator.userAgent);
+ if (!checkIE) {
+ node.src = "data:audio/wav;base64,UklGRigAAABXQVZFZm10IBIAAAABAAEARKwAAIhYAQACABAAAABkYXRhAgAAAAEA";
+ }
+ }
+ };
+ var Sound2 = function(howl) {
+ this._parent = howl;
+ this.init();
+ };
+ Sound2.prototype = {
+ /**
+ * Initialize a new Sound object.
+ * @return {Sound}
+ */
+ init: function() {
+ var self2 = this;
+ var parent = self2._parent;
+ self2._muted = parent._muted;
+ self2._loop = parent._loop;
+ self2._volume = parent._volume;
+ self2._rate = parent._rate;
+ self2._seek = 0;
+ self2._paused = true;
+ self2._ended = true;
+ self2._sprite = "__default";
+ self2._id = ++Howler2._counter;
+ parent._sounds.push(self2);
+ self2.create();
+ return self2;
+ },
+ /**
+ * Create and setup a new sound object, whether HTML5 Audio or Web Audio.
+ * @return {Sound}
+ */
+ create: function() {
+ var self2 = this;
+ var parent = self2._parent;
+ var volume = Howler2._muted || self2._muted || self2._parent._muted ? 0 : self2._volume;
+ if (parent._webAudio) {
+ self2._node = typeof Howler2.ctx.createGain === "undefined" ? Howler2.ctx.createGainNode() : Howler2.ctx.createGain();
+ self2._node.gain.setValueAtTime(volume, Howler2.ctx.currentTime);
+ self2._node.paused = true;
+ self2._node.connect(Howler2.masterGain);
+ } else if (!Howler2.noAudio) {
+ self2._node = Howler2._obtainHtml5Audio();
+ self2._errorFn = self2._errorListener.bind(self2);
+ self2._node.addEventListener("error", self2._errorFn, false);
+ self2._loadFn = self2._loadListener.bind(self2);
+ self2._node.addEventListener(Howler2._canPlayEvent, self2._loadFn, false);
+ self2._endFn = self2._endListener.bind(self2);
+ self2._node.addEventListener("ended", self2._endFn, false);
+ self2._node.src = parent._src;
+ self2._node.preload = parent._preload === true ? "auto" : parent._preload;
+ self2._node.volume = volume * Howler2.volume();
+ self2._node.load();
+ }
+ return self2;
+ },
+ /**
+ * Reset the parameters of this sound to the original state (for recycle).
+ * @return {Sound}
+ */
+ reset: function() {
+ var self2 = this;
+ var parent = self2._parent;
+ self2._muted = parent._muted;
+ self2._loop = parent._loop;
+ self2._volume = parent._volume;
+ self2._rate = parent._rate;
+ self2._seek = 0;
+ self2._rateSeek = 0;
+ self2._paused = true;
+ self2._ended = true;
+ self2._sprite = "__default";
+ self2._id = ++Howler2._counter;
+ return self2;
+ },
+ /**
+ * HTML5 Audio error listener callback.
+ */
+ _errorListener: function() {
+ var self2 = this;
+ self2._parent._emit("loaderror", self2._id, self2._node.error ? self2._node.error.code : 0);
+ self2._node.removeEventListener("error", self2._errorFn, false);
+ },
+ /**
+ * HTML5 Audio canplaythrough listener callback.
+ */
+ _loadListener: function() {
+ var self2 = this;
+ var parent = self2._parent;
+ parent._duration = Math.ceil(self2._node.duration * 10) / 10;
+ if (Object.keys(parent._sprite).length === 0) {
+ parent._sprite = { __default: [0, parent._duration * 1e3] };
+ }
+ if (parent._state !== "loaded") {
+ parent._state = "loaded";
+ parent._emit("load");
+ parent._loadQueue();
+ }
+ self2._node.removeEventListener(Howler2._canPlayEvent, self2._loadFn, false);
+ },
+ /**
+ * HTML5 Audio ended listener callback.
+ */
+ _endListener: function() {
+ var self2 = this;
+ var parent = self2._parent;
+ if (parent._duration === Infinity) {
+ parent._duration = Math.ceil(self2._node.duration * 10) / 10;
+ if (parent._sprite.__default[1] === Infinity) {
+ parent._sprite.__default[1] = parent._duration * 1e3;
+ }
+ parent._ended(self2);
+ }
+ self2._node.removeEventListener("ended", self2._endFn, false);
+ }
+ };
+ var cache2 = {};
+ var loadBuffer = function(self2) {
+ var url = self2._src;
+ if (cache2[url]) {
+ self2._duration = cache2[url].duration;
+ loadSound(self2);
+ return;
+ }
+ if (/^data:[^;]+;base64,/.test(url)) {
+ var data = atob(url.split(",")[1]);
+ var dataView = new Uint8Array(data.length);
+ for (var i = 0; i < data.length; ++i) {
+ dataView[i] = data.charCodeAt(i);
+ }
+ decodeAudioData(dataView.buffer, self2);
+ } else {
+ var xhr = new XMLHttpRequest();
+ xhr.open(self2._xhr.method, url, true);
+ xhr.withCredentials = self2._xhr.withCredentials;
+ xhr.responseType = "arraybuffer";
+ if (self2._xhr.headers) {
+ Object.keys(self2._xhr.headers).forEach(function(key) {
+ xhr.setRequestHeader(key, self2._xhr.headers[key]);
+ });
+ }
+ xhr.onload = function() {
+ var code = (xhr.status + "")[0];
+ if (code !== "0" && code !== "2" && code !== "3") {
+ self2._emit("loaderror", null, "Failed loading audio file with status: " + xhr.status + ".");
+ return;
+ }
+ decodeAudioData(xhr.response, self2);
+ };
+ xhr.onerror = function() {
+ if (self2._webAudio) {
+ self2._html5 = true;
+ self2._webAudio = false;
+ self2._sounds = [];
+ delete cache2[url];
+ self2.load();
+ }
+ };
+ safeXhrSend(xhr);
+ }
+ };
+ var safeXhrSend = function(xhr) {
+ try {
+ xhr.send();
+ } catch (e) {
+ xhr.onerror();
+ }
+ };
+ var decodeAudioData = function(arraybuffer, self2) {
+ var error = function() {
+ self2._emit("loaderror", null, "Decoding audio data failed.");
+ };
+ var success = function(buffer) {
+ if (buffer && self2._sounds.length > 0) {
+ cache2[self2._src] = buffer;
+ loadSound(self2, buffer);
+ } else {
+ error();
+ }
+ };
+ if (typeof Promise !== "undefined" && Howler2.ctx.decodeAudioData.length === 1) {
+ Howler2.ctx.decodeAudioData(arraybuffer).then(success).catch(error);
+ } else {
+ Howler2.ctx.decodeAudioData(arraybuffer, success, error);
+ }
+ };
+ var loadSound = function(self2, buffer) {
+ if (buffer && !self2._duration) {
+ self2._duration = buffer.duration;
+ }
+ if (Object.keys(self2._sprite).length === 0) {
+ self2._sprite = { __default: [0, self2._duration * 1e3] };
+ }
+ if (self2._state !== "loaded") {
+ self2._state = "loaded";
+ self2._emit("load");
+ self2._loadQueue();
+ }
+ };
+ var setupAudioContext = function() {
+ if (!Howler2.usingWebAudio) {
+ return;
+ }
+ try {
+ if (typeof AudioContext !== "undefined") {
+ Howler2.ctx = new AudioContext();
+ } else if (typeof webkitAudioContext !== "undefined") {
+ Howler2.ctx = new webkitAudioContext();
+ } else {
+ Howler2.usingWebAudio = false;
+ }
+ } catch (e) {
+ Howler2.usingWebAudio = false;
+ }
+ if (!Howler2.ctx) {
+ Howler2.usingWebAudio = false;
+ }
+ var iOS = /iP(hone|od|ad)/.test(Howler2._navigator && Howler2._navigator.platform);
+ var appVersion = Howler2._navigator && Howler2._navigator.appVersion.match(/OS (\d+)_(\d+)_?(\d+)?/);
+ var version2 = appVersion ? parseInt(appVersion[1], 10) : null;
+ if (iOS && version2 && version2 < 9) {
+ var safari = /safari/.test(Howler2._navigator && Howler2._navigator.userAgent.toLowerCase());
+ if (Howler2._navigator && !safari) {
+ Howler2.usingWebAudio = false;
+ }
+ }
+ if (Howler2.usingWebAudio) {
+ Howler2.masterGain = typeof Howler2.ctx.createGain === "undefined" ? Howler2.ctx.createGainNode() : Howler2.ctx.createGain();
+ Howler2.masterGain.gain.setValueAtTime(Howler2._muted ? 0 : Howler2._volume, Howler2.ctx.currentTime);
+ Howler2.masterGain.connect(Howler2.ctx.destination);
+ }
+ Howler2._setup();
+ };
+ {
+ exports2.Howler = Howler2;
+ exports2.Howl = Howl2;
+ }
+ if (typeof commonjsGlobal !== "undefined") {
+ commonjsGlobal.HowlerGlobal = HowlerGlobal2;
+ commonjsGlobal.Howler = Howler2;
+ commonjsGlobal.Howl = Howl2;
+ commonjsGlobal.Sound = Sound2;
+ } else if (typeof window !== "undefined") {
+ window.HowlerGlobal = HowlerGlobal2;
+ window.Howler = Howler2;
+ window.Howl = Howl2;
+ window.Sound = Sound2;
+ }
+ })();
+ /*!
+ * Spatial Plugin - Adds support for stereo and 3D audio where Web Audio is supported.
+ *
+ * howler.js v2.2.4
+ * howlerjs.com
+ *
+ * (c) 2013-2020, James Simpson of GoldFire Studios
+ * goldfirestudios.com
+ *
+ * MIT License
+ */
+ (function() {
+ HowlerGlobal.prototype._pos = [0, 0, 0];
+ HowlerGlobal.prototype._orientation = [0, 0, -1, 0, 1, 0];
+ HowlerGlobal.prototype.stereo = function(pan) {
+ var self2 = this;
+ if (!self2.ctx || !self2.ctx.listener) {
+ return self2;
+ }
+ for (var i = self2._howls.length - 1; i >= 0; i--) {
+ self2._howls[i].stereo(pan);
+ }
+ return self2;
+ };
+ HowlerGlobal.prototype.pos = function(x, y, z) {
+ var self2 = this;
+ if (!self2.ctx || !self2.ctx.listener) {
+ return self2;
+ }
+ y = typeof y !== "number" ? self2._pos[1] : y;
+ z = typeof z !== "number" ? self2._pos[2] : z;
+ if (typeof x === "number") {
+ self2._pos = [x, y, z];
+ if (typeof self2.ctx.listener.positionX !== "undefined") {
+ self2.ctx.listener.positionX.setTargetAtTime(self2._pos[0], Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.positionY.setTargetAtTime(self2._pos[1], Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.positionZ.setTargetAtTime(self2._pos[2], Howler.ctx.currentTime, 0.1);
+ } else {
+ self2.ctx.listener.setPosition(self2._pos[0], self2._pos[1], self2._pos[2]);
+ }
+ } else {
+ return self2._pos;
+ }
+ return self2;
+ };
+ HowlerGlobal.prototype.orientation = function(x, y, z, xUp, yUp, zUp) {
+ var self2 = this;
+ if (!self2.ctx || !self2.ctx.listener) {
+ return self2;
+ }
+ var or = self2._orientation;
+ y = typeof y !== "number" ? or[1] : y;
+ z = typeof z !== "number" ? or[2] : z;
+ xUp = typeof xUp !== "number" ? or[3] : xUp;
+ yUp = typeof yUp !== "number" ? or[4] : yUp;
+ zUp = typeof zUp !== "number" ? or[5] : zUp;
+ if (typeof x === "number") {
+ self2._orientation = [x, y, z, xUp, yUp, zUp];
+ if (typeof self2.ctx.listener.forwardX !== "undefined") {
+ self2.ctx.listener.forwardX.setTargetAtTime(x, Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.forwardY.setTargetAtTime(y, Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.forwardZ.setTargetAtTime(z, Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.upX.setTargetAtTime(xUp, Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.upY.setTargetAtTime(yUp, Howler.ctx.currentTime, 0.1);
+ self2.ctx.listener.upZ.setTargetAtTime(zUp, Howler.ctx.currentTime, 0.1);
+ } else {
+ self2.ctx.listener.setOrientation(x, y, z, xUp, yUp, zUp);
+ }
+ } else {
+ return or;
+ }
+ return self2;
+ };
+ Howl.prototype.init = /* @__PURE__ */ function(_super) {
+ return function(o) {
+ var self2 = this;
+ self2._orientation = o.orientation || [1, 0, 0];
+ self2._stereo = o.stereo || null;
+ self2._pos = o.pos || null;
+ self2._pannerAttr = {
+ coneInnerAngle: typeof o.coneInnerAngle !== "undefined" ? o.coneInnerAngle : 360,
+ coneOuterAngle: typeof o.coneOuterAngle !== "undefined" ? o.coneOuterAngle : 360,
+ coneOuterGain: typeof o.coneOuterGain !== "undefined" ? o.coneOuterGain : 0,
+ distanceModel: typeof o.distanceModel !== "undefined" ? o.distanceModel : "inverse",
+ maxDistance: typeof o.maxDistance !== "undefined" ? o.maxDistance : 1e4,
+ panningModel: typeof o.panningModel !== "undefined" ? o.panningModel : "HRTF",
+ refDistance: typeof o.refDistance !== "undefined" ? o.refDistance : 1,
+ rolloffFactor: typeof o.rolloffFactor !== "undefined" ? o.rolloffFactor : 1
+ };
+ self2._onstereo = o.onstereo ? [{ fn: o.onstereo }] : [];
+ self2._onpos = o.onpos ? [{ fn: o.onpos }] : [];
+ self2._onorientation = o.onorientation ? [{ fn: o.onorientation }] : [];
+ return _super.call(this, o);
+ };
+ }(Howl.prototype.init);
+ Howl.prototype.stereo = function(pan, id) {
+ var self2 = this;
+ if (!self2._webAudio) {
+ return self2;
+ }
+ if (self2._state !== "loaded") {
+ self2._queue.push({
+ event: "stereo",
+ action: function() {
+ self2.stereo(pan, id);
+ }
+ });
+ return self2;
+ }
+ var pannerType = typeof Howler.ctx.createStereoPanner === "undefined" ? "spatial" : "stereo";
+ if (typeof id === "undefined") {
+ if (typeof pan === "number") {
+ self2._stereo = pan;
+ self2._pos = [pan, 0, 0];
+ } else {
+ return self2._stereo;
+ }
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ if (typeof pan === "number") {
+ sound._stereo = pan;
+ sound._pos = [pan, 0, 0];
+ if (sound._node) {
+ sound._pannerAttr.panningModel = "equalpower";
+ if (!sound._panner || !sound._panner.pan) {
+ setupPanner(sound, pannerType);
+ }
+ if (pannerType === "spatial") {
+ if (typeof sound._panner.positionX !== "undefined") {
+ sound._panner.positionX.setValueAtTime(pan, Howler.ctx.currentTime);
+ sound._panner.positionY.setValueAtTime(0, Howler.ctx.currentTime);
+ sound._panner.positionZ.setValueAtTime(0, Howler.ctx.currentTime);
+ } else {
+ sound._panner.setPosition(pan, 0, 0);
+ }
+ } else {
+ sound._panner.pan.setValueAtTime(pan, Howler.ctx.currentTime);
+ }
+ }
+ self2._emit("stereo", sound._id);
+ } else {
+ return sound._stereo;
+ }
+ }
+ }
+ return self2;
+ };
+ Howl.prototype.pos = function(x, y, z, id) {
+ var self2 = this;
+ if (!self2._webAudio) {
+ return self2;
+ }
+ if (self2._state !== "loaded") {
+ self2._queue.push({
+ event: "pos",
+ action: function() {
+ self2.pos(x, y, z, id);
+ }
+ });
+ return self2;
+ }
+ y = typeof y !== "number" ? 0 : y;
+ z = typeof z !== "number" ? -0.5 : z;
+ if (typeof id === "undefined") {
+ if (typeof x === "number") {
+ self2._pos = [x, y, z];
+ } else {
+ return self2._pos;
+ }
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ if (typeof x === "number") {
+ sound._pos = [x, y, z];
+ if (sound._node) {
+ if (!sound._panner || sound._panner.pan) {
+ setupPanner(sound, "spatial");
+ }
+ if (typeof sound._panner.positionX !== "undefined") {
+ sound._panner.positionX.setValueAtTime(x, Howler.ctx.currentTime);
+ sound._panner.positionY.setValueAtTime(y, Howler.ctx.currentTime);
+ sound._panner.positionZ.setValueAtTime(z, Howler.ctx.currentTime);
+ } else {
+ sound._panner.setPosition(x, y, z);
+ }
+ }
+ self2._emit("pos", sound._id);
+ } else {
+ return sound._pos;
+ }
+ }
+ }
+ return self2;
+ };
+ Howl.prototype.orientation = function(x, y, z, id) {
+ var self2 = this;
+ if (!self2._webAudio) {
+ return self2;
+ }
+ if (self2._state !== "loaded") {
+ self2._queue.push({
+ event: "orientation",
+ action: function() {
+ self2.orientation(x, y, z, id);
+ }
+ });
+ return self2;
+ }
+ y = typeof y !== "number" ? self2._orientation[1] : y;
+ z = typeof z !== "number" ? self2._orientation[2] : z;
+ if (typeof id === "undefined") {
+ if (typeof x === "number") {
+ self2._orientation = [x, y, z];
+ } else {
+ return self2._orientation;
+ }
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ var sound = self2._soundById(ids[i]);
+ if (sound) {
+ if (typeof x === "number") {
+ sound._orientation = [x, y, z];
+ if (sound._node) {
+ if (!sound._panner) {
+ if (!sound._pos) {
+ sound._pos = self2._pos || [0, 0, -0.5];
+ }
+ setupPanner(sound, "spatial");
+ }
+ if (typeof sound._panner.orientationX !== "undefined") {
+ sound._panner.orientationX.setValueAtTime(x, Howler.ctx.currentTime);
+ sound._panner.orientationY.setValueAtTime(y, Howler.ctx.currentTime);
+ sound._panner.orientationZ.setValueAtTime(z, Howler.ctx.currentTime);
+ } else {
+ sound._panner.setOrientation(x, y, z);
+ }
+ }
+ self2._emit("orientation", sound._id);
+ } else {
+ return sound._orientation;
+ }
+ }
+ }
+ return self2;
+ };
+ Howl.prototype.pannerAttr = function() {
+ var self2 = this;
+ var args = arguments;
+ var o, id, sound;
+ if (!self2._webAudio) {
+ return self2;
+ }
+ if (args.length === 0) {
+ return self2._pannerAttr;
+ } else if (args.length === 1) {
+ if (typeof args[0] === "object") {
+ o = args[0];
+ if (typeof id === "undefined") {
+ if (!o.pannerAttr) {
+ o.pannerAttr = {
+ coneInnerAngle: o.coneInnerAngle,
+ coneOuterAngle: o.coneOuterAngle,
+ coneOuterGain: o.coneOuterGain,
+ distanceModel: o.distanceModel,
+ maxDistance: o.maxDistance,
+ refDistance: o.refDistance,
+ rolloffFactor: o.rolloffFactor,
+ panningModel: o.panningModel
+ };
+ }
+ self2._pannerAttr = {
+ coneInnerAngle: typeof o.pannerAttr.coneInnerAngle !== "undefined" ? o.pannerAttr.coneInnerAngle : self2._coneInnerAngle,
+ coneOuterAngle: typeof o.pannerAttr.coneOuterAngle !== "undefined" ? o.pannerAttr.coneOuterAngle : self2._coneOuterAngle,
+ coneOuterGain: typeof o.pannerAttr.coneOuterGain !== "undefined" ? o.pannerAttr.coneOuterGain : self2._coneOuterGain,
+ distanceModel: typeof o.pannerAttr.distanceModel !== "undefined" ? o.pannerAttr.distanceModel : self2._distanceModel,
+ maxDistance: typeof o.pannerAttr.maxDistance !== "undefined" ? o.pannerAttr.maxDistance : self2._maxDistance,
+ refDistance: typeof o.pannerAttr.refDistance !== "undefined" ? o.pannerAttr.refDistance : self2._refDistance,
+ rolloffFactor: typeof o.pannerAttr.rolloffFactor !== "undefined" ? o.pannerAttr.rolloffFactor : self2._rolloffFactor,
+ panningModel: typeof o.pannerAttr.panningModel !== "undefined" ? o.pannerAttr.panningModel : self2._panningModel
+ };
+ }
+ } else {
+ sound = self2._soundById(parseInt(args[0], 10));
+ return sound ? sound._pannerAttr : self2._pannerAttr;
+ }
+ } else if (args.length === 2) {
+ o = args[0];
+ id = parseInt(args[1], 10);
+ }
+ var ids = self2._getSoundIds(id);
+ for (var i = 0; i < ids.length; i++) {
+ sound = self2._soundById(ids[i]);
+ if (sound) {
+ var pa = sound._pannerAttr;
+ pa = {
+ coneInnerAngle: typeof o.coneInnerAngle !== "undefined" ? o.coneInnerAngle : pa.coneInnerAngle,
+ coneOuterAngle: typeof o.coneOuterAngle !== "undefined" ? o.coneOuterAngle : pa.coneOuterAngle,
+ coneOuterGain: typeof o.coneOuterGain !== "undefined" ? o.coneOuterGain : pa.coneOuterGain,
+ distanceModel: typeof o.distanceModel !== "undefined" ? o.distanceModel : pa.distanceModel,
+ maxDistance: typeof o.maxDistance !== "undefined" ? o.maxDistance : pa.maxDistance,
+ refDistance: typeof o.refDistance !== "undefined" ? o.refDistance : pa.refDistance,
+ rolloffFactor: typeof o.rolloffFactor !== "undefined" ? o.rolloffFactor : pa.rolloffFactor,
+ panningModel: typeof o.panningModel !== "undefined" ? o.panningModel : pa.panningModel
+ };
+ var panner = sound._panner;
+ if (!panner) {
+ if (!sound._pos) {
+ sound._pos = self2._pos || [0, 0, -0.5];
+ }
+ setupPanner(sound, "spatial");
+ panner = sound._panner;
+ }
+ panner.coneInnerAngle = pa.coneInnerAngle;
+ panner.coneOuterAngle = pa.coneOuterAngle;
+ panner.coneOuterGain = pa.coneOuterGain;
+ panner.distanceModel = pa.distanceModel;
+ panner.maxDistance = pa.maxDistance;
+ panner.refDistance = pa.refDistance;
+ panner.rolloffFactor = pa.rolloffFactor;
+ panner.panningModel = pa.panningModel;
+ }
+ }
+ return self2;
+ };
+ Sound.prototype.init = /* @__PURE__ */ function(_super) {
+ return function() {
+ var self2 = this;
+ var parent = self2._parent;
+ self2._orientation = parent._orientation;
+ self2._stereo = parent._stereo;
+ self2._pos = parent._pos;
+ self2._pannerAttr = parent._pannerAttr;
+ _super.call(this);
+ if (self2._stereo) {
+ parent.stereo(self2._stereo);
+ } else if (self2._pos) {
+ parent.pos(self2._pos[0], self2._pos[1], self2._pos[2], self2._id);
+ }
+ };
+ }(Sound.prototype.init);
+ Sound.prototype.reset = /* @__PURE__ */ function(_super) {
+ return function() {
+ var self2 = this;
+ var parent = self2._parent;
+ self2._orientation = parent._orientation;
+ self2._stereo = parent._stereo;
+ self2._pos = parent._pos;
+ self2._pannerAttr = parent._pannerAttr;
+ if (self2._stereo) {
+ parent.stereo(self2._stereo);
+ } else if (self2._pos) {
+ parent.pos(self2._pos[0], self2._pos[1], self2._pos[2], self2._id);
+ } else if (self2._panner) {
+ self2._panner.disconnect(0);
+ self2._panner = void 0;
+ parent._refreshBuffer(self2);
+ }
+ return _super.call(this);
+ };
+ }(Sound.prototype.reset);
+ var setupPanner = function(sound, type) {
+ type = type || "spatial";
+ if (type === "spatial") {
+ sound._panner = Howler.ctx.createPanner();
+ sound._panner.coneInnerAngle = sound._pannerAttr.coneInnerAngle;
+ sound._panner.coneOuterAngle = sound._pannerAttr.coneOuterAngle;
+ sound._panner.coneOuterGain = sound._pannerAttr.coneOuterGain;
+ sound._panner.distanceModel = sound._pannerAttr.distanceModel;
+ sound._panner.maxDistance = sound._pannerAttr.maxDistance;
+ sound._panner.refDistance = sound._pannerAttr.refDistance;
+ sound._panner.rolloffFactor = sound._pannerAttr.rolloffFactor;
+ sound._panner.panningModel = sound._pannerAttr.panningModel;
+ if (typeof sound._panner.positionX !== "undefined") {
+ sound._panner.positionX.setValueAtTime(sound._pos[0], Howler.ctx.currentTime);
+ sound._panner.positionY.setValueAtTime(sound._pos[1], Howler.ctx.currentTime);
+ sound._panner.positionZ.setValueAtTime(sound._pos[2], Howler.ctx.currentTime);
+ } else {
+ sound._panner.setPosition(sound._pos[0], sound._pos[1], sound._pos[2]);
+ }
+ if (typeof sound._panner.orientationX !== "undefined") {
+ sound._panner.orientationX.setValueAtTime(sound._orientation[0], Howler.ctx.currentTime);
+ sound._panner.orientationY.setValueAtTime(sound._orientation[1], Howler.ctx.currentTime);
+ sound._panner.orientationZ.setValueAtTime(sound._orientation[2], Howler.ctx.currentTime);
+ } else {
+ sound._panner.setOrientation(sound._orientation[0], sound._orientation[1], sound._orientation[2]);
+ }
+ } else {
+ sound._panner = Howler.ctx.createStereoPanner();
+ sound._panner.pan.setValueAtTime(sound._stereo, Howler.ctx.currentTime);
+ }
+ sound._panner.connect(sound._node);
+ if (!sound._paused) {
+ sound._parent.pause(sound._id, true).play(sound._id, true);
+ }
+ };
+ })();
+})(howler);
+const setData = window.electron.ipcRenderer.sendSync("get-store-value", "set");
+const baseURL$1 = window.electron ? `http://127.0.0.1:${setData.musicApiPort}` : "http://110.42.251.190:9898";
+const request$1 = axios.create({
+ baseURL: baseURL$1,
+ timeout: 5e3
+});
+const MAX_RETRIES = 3;
+const RETRY_DELAY = 500;
+request$1.interceptors.request.use(
+ (config2) => {
+ config2.retryCount = 0;
+ if (config2.method === "get") {
+ config2.params = {
+ ...config2.params,
+ timestamp: Date.now()
+ };
+ const token = localStorage.getItem("token");
+ if (token) {
+ config2.params.cookie = token;
+ }
+ }
+ return config2;
+ },
+ (error) => {
+ return Promise.reject(error);
+ }
+);
+request$1.interceptors.response.use(
+ (response) => {
+ return response;
+ },
+ async (error) => {
+ const config2 = error.config;
+ if (!config2 || !config2.retryCount) {
+ config2.retryCount = 0;
+ }
+ if (config2.retryCount < MAX_RETRIES) {
+ config2.retryCount++;
+ await new Promise((resolve2) => setTimeout(resolve2, RETRY_DELAY));
+ return request$1(config2);
+ }
+ return Promise.reject(error);
+ }
+);
+const baseURL = `${"http://110.42.251.190:4100"}`;
+const request = axios.create({
+ baseURL,
+ timeout: 1e4
+});
+request.interceptors.request.use(
+ (config2) => {
+ return config2;
+ },
+ (error) => {
+ return Promise.reject(error);
+ }
+);
+const getMusicUrl = (id) => {
+ return request$1.get("/song/url", { params: { id } });
+};
+const getMusicDetail = (ids) => {
+ return request$1.get("/song/detail", { params: { ids: ids.join(",") } });
+};
+const getMusicLrc = (id) => {
+ return request$1.get("/lyric", { params: { id } });
+};
+const getParsingMusicUrl = (id) => {
+ if (isElectron) {
+ return window.api.unblockMusic(id);
+ }
+ return request.get("/music", { params: { id } });
+};
+function tryOnScopeDispose(fn) {
+ if (getCurrentScope()) {
+ onScopeDispose(fn);
+ return true;
+ }
+ return false;
+}
+function toValue(r) {
+ return typeof r === "function" ? r() : unref(r);
+}
+const isClient = typeof window !== "undefined" && typeof document !== "undefined";
+typeof WorkerGlobalScope !== "undefined" && globalThis instanceof WorkerGlobalScope;
+const toString2 = Object.prototype.toString;
+const isObject = (val) => toString2.call(val) === "[object Object]";
+const noop = () => {
+};
+function createFilterWrapper(filter2, fn) {
+ function wrapper(...args) {
+ return new Promise((resolve2, reject) => {
+ Promise.resolve(filter2(() => fn.apply(this, args), { fn, thisArg: this, args })).then(resolve2).catch(reject);
+ });
+ }
+ return wrapper;
+}
+const bypassFilter = (invoke2) => {
+ return invoke2();
+};
+function debounceFilter(ms, options = {}) {
+ let timer;
+ let maxTimer;
+ let lastRejector = noop;
+ const _clearTimeout = (timer2) => {
+ clearTimeout(timer2);
+ lastRejector();
+ lastRejector = noop;
+ };
+ const filter2 = (invoke2) => {
+ const duration2 = toValue(ms);
+ const maxDuration = toValue(options.maxWait);
+ if (timer)
+ _clearTimeout(timer);
+ if (duration2 <= 0 || maxDuration !== void 0 && maxDuration <= 0) {
+ if (maxTimer) {
+ _clearTimeout(maxTimer);
+ maxTimer = null;
+ }
+ return Promise.resolve(invoke2());
+ }
+ return new Promise((resolve2, reject) => {
+ lastRejector = options.rejectOnCancel ? reject : resolve2;
+ if (maxDuration && !maxTimer) {
+ maxTimer = setTimeout(() => {
+ if (timer)
+ _clearTimeout(timer);
+ maxTimer = null;
+ resolve2(invoke2());
+ }, maxDuration);
+ }
+ timer = setTimeout(() => {
+ if (maxTimer)
+ _clearTimeout(maxTimer);
+ maxTimer = null;
+ resolve2(invoke2());
+ }, duration2);
+ });
+ };
+ return filter2;
+}
+function throttleFilter(...args) {
+ let lastExec = 0;
+ let timer;
+ let isLeading = true;
+ let lastRejector = noop;
+ let lastValue;
+ let ms;
+ let trailing;
+ let leading;
+ let rejectOnCancel;
+ if (!isRef(args[0]) && typeof args[0] === "object")
+ ({ delay: ms, trailing = true, leading = true, rejectOnCancel = false } = args[0]);
+ else
+ [ms, trailing = true, leading = true, rejectOnCancel = false] = args;
+ const clear = () => {
+ if (timer) {
+ clearTimeout(timer);
+ timer = void 0;
+ lastRejector();
+ lastRejector = noop;
+ }
+ };
+ const filter2 = (_invoke) => {
+ const duration2 = toValue(ms);
+ const elapsed = Date.now() - lastExec;
+ const invoke2 = () => {
+ return lastValue = _invoke();
+ };
+ clear();
+ if (duration2 <= 0) {
+ lastExec = Date.now();
+ return invoke2();
+ }
+ if (elapsed > duration2 && (leading || !isLeading)) {
+ lastExec = Date.now();
+ invoke2();
+ } else if (trailing) {
+ lastValue = new Promise((resolve2, reject) => {
+ lastRejector = rejectOnCancel ? reject : resolve2;
+ timer = setTimeout(() => {
+ lastExec = Date.now();
+ isLeading = true;
+ resolve2(invoke2());
+ clear();
+ }, Math.max(0, duration2 - elapsed));
+ });
+ }
+ if (!leading && !timer)
+ timer = setTimeout(() => isLeading = true, duration2);
+ isLeading = false;
+ return lastValue;
+ };
+ return filter2;
+}
+function pausableFilter(extendFilter = bypassFilter) {
+ const isActive = ref(true);
+ function pause() {
+ isActive.value = false;
+ }
+ function resume() {
+ isActive.value = true;
+ }
+ const eventFilter = (...args) => {
+ if (isActive.value)
+ extendFilter(...args);
+ };
+ return { isActive: readonly(isActive), pause, resume, eventFilter };
+}
+function getLifeCycleTarget(target) {
+ return getCurrentInstance();
+}
+function useDebounceFn(fn, ms = 200, options = {}) {
+ return createFilterWrapper(
+ debounceFilter(ms, options),
+ fn
+ );
+}
+function useThrottleFn(fn, ms = 200, trailing = false, leading = true, rejectOnCancel = false) {
+ return createFilterWrapper(
+ throttleFilter(ms, trailing, leading, rejectOnCancel),
+ fn
+ );
+}
+function watchWithFilter(source, cb, options = {}) {
+ const {
+ eventFilter = bypassFilter,
+ ...watchOptions
+ } = options;
+ return watch(
+ source,
+ createFilterWrapper(
+ eventFilter,
+ cb
+ ),
+ watchOptions
+ );
+}
+function watchPausable(source, cb, options = {}) {
+ const {
+ eventFilter: filter2,
+ ...watchOptions
+ } = options;
+ const { eventFilter, pause, resume, isActive } = pausableFilter(filter2);
+ const stop = watchWithFilter(
+ source,
+ cb,
+ {
+ ...watchOptions,
+ eventFilter
+ }
+ );
+ return { stop, pause, resume, isActive };
+}
+function tryOnMounted(fn, sync = true, target) {
+ const instance = getLifeCycleTarget();
+ if (instance)
+ onMounted(fn, target);
+ else if (sync)
+ fn();
+ else
+ nextTick(fn);
+}
+const REGEX_PARSE = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[T\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/i;
+const REGEX_FORMAT = /[YMDHhms]o|\[([^\]]+)\]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a{1,2}|A{1,2}|m{1,2}|s{1,2}|Z{1,2}|SSS/g;
+function defaultMeridiem(hours, minutes, isLowercase, hasPeriod) {
+ let m = hours < 12 ? "AM" : "PM";
+ if (hasPeriod)
+ m = m.split("").reduce((acc, curr) => acc += `${curr}.`, "");
+ return isLowercase ? m.toLowerCase() : m;
+}
+function formatOrdinal(num) {
+ const suffixes = ["th", "st", "nd", "rd"];
+ const v = num % 100;
+ return num + (suffixes[(v - 20) % 10] || suffixes[v] || suffixes[0]);
+}
+function formatDate(date, formatStr, options = {}) {
+ var _a;
+ const years = date.getFullYear();
+ const month = date.getMonth();
+ const days = date.getDate();
+ const hours = date.getHours();
+ const minutes = date.getMinutes();
+ const seconds = date.getSeconds();
+ const milliseconds = date.getMilliseconds();
+ const day = date.getDay();
+ const meridiem = (_a = options.customMeridiem) != null ? _a : defaultMeridiem;
+ const matches2 = {
+ Yo: () => formatOrdinal(years),
+ YY: () => String(years).slice(-2),
+ YYYY: () => years,
+ M: () => month + 1,
+ Mo: () => formatOrdinal(month + 1),
+ MM: () => `${month + 1}`.padStart(2, "0"),
+ MMM: () => date.toLocaleDateString(toValue(options.locales), { month: "short" }),
+ MMMM: () => date.toLocaleDateString(toValue(options.locales), { month: "long" }),
+ D: () => String(days),
+ Do: () => formatOrdinal(days),
+ DD: () => `${days}`.padStart(2, "0"),
+ H: () => String(hours),
+ Ho: () => formatOrdinal(hours),
+ HH: () => `${hours}`.padStart(2, "0"),
+ h: () => `${hours % 12 || 12}`.padStart(1, "0"),
+ ho: () => formatOrdinal(hours % 12 || 12),
+ hh: () => `${hours % 12 || 12}`.padStart(2, "0"),
+ m: () => String(minutes),
+ mo: () => formatOrdinal(minutes),
+ mm: () => `${minutes}`.padStart(2, "0"),
+ s: () => String(seconds),
+ so: () => formatOrdinal(seconds),
+ ss: () => `${seconds}`.padStart(2, "0"),
+ SSS: () => `${milliseconds}`.padStart(3, "0"),
+ d: () => day,
+ dd: () => date.toLocaleDateString(toValue(options.locales), { weekday: "narrow" }),
+ ddd: () => date.toLocaleDateString(toValue(options.locales), { weekday: "short" }),
+ dddd: () => date.toLocaleDateString(toValue(options.locales), { weekday: "long" }),
+ A: () => meridiem(hours, minutes),
+ AA: () => meridiem(hours, minutes, false, true),
+ a: () => meridiem(hours, minutes, true),
+ aa: () => meridiem(hours, minutes, true, true)
+ };
+ return formatStr.replace(REGEX_FORMAT, (match, $1) => {
+ var _a2, _b;
+ return (_b = $1 != null ? $1 : (_a2 = matches2[match]) == null ? void 0 : _a2.call(matches2)) != null ? _b : match;
+ });
+}
+function normalizeDate(date) {
+ if (date === null)
+ return new Date(Number.NaN);
+ if (date === void 0)
+ return /* @__PURE__ */ new Date();
+ if (date instanceof Date)
+ return new Date(date);
+ if (typeof date === "string" && !/Z$/i.test(date)) {
+ const d = date.match(REGEX_PARSE);
+ if (d) {
+ const m = d[2] - 1 || 0;
+ const ms = (d[7] || "0").substring(0, 3);
+ return new Date(d[1], m, d[3] || 1, d[4] || 0, d[5] || 0, d[6] || 0, ms);
+ }
+ }
+ return new Date(date);
+}
+function useDateFormat(date, formatStr = "HH:mm:ss", options = {}) {
+ return computed(() => formatDate(normalizeDate(toValue(date)), toValue(formatStr), options));
+}
+const defaultWindow = isClient ? window : void 0;
+function unrefElement(elRef) {
+ var _a;
+ const plain = toValue(elRef);
+ return (_a = plain == null ? void 0 : plain.$el) != null ? _a : plain;
+}
+function useEventListener(...args) {
+ let target;
+ let events2;
+ let listeners;
+ let options;
+ if (typeof args[0] === "string" || Array.isArray(args[0])) {
+ [events2, listeners, options] = args;
+ target = defaultWindow;
+ } else {
+ [target, events2, listeners, options] = args;
+ }
+ if (!target)
+ return noop;
+ if (!Array.isArray(events2))
+ events2 = [events2];
+ if (!Array.isArray(listeners))
+ listeners = [listeners];
+ const cleanups = [];
+ const cleanup = () => {
+ cleanups.forEach((fn) => fn());
+ cleanups.length = 0;
+ };
+ const register2 = (el, event, listener, options2) => {
+ el.addEventListener(event, listener, options2);
+ return () => el.removeEventListener(event, listener, options2);
+ };
+ const stopWatch = watch(
+ () => [unrefElement(target), toValue(options)],
+ ([el, options2]) => {
+ cleanup();
+ if (!el)
+ return;
+ const optionsClone = isObject(options2) ? { ...options2 } : options2;
+ cleanups.push(
+ ...events2.flatMap((event) => {
+ return listeners.map((listener) => register2(el, event, listener, optionsClone));
+ })
+ );
+ },
+ { immediate: true, flush: "post" }
+ );
+ const stop = () => {
+ stopWatch();
+ cleanup();
+ };
+ tryOnScopeDispose(stop);
+ return stop;
+}
+const _global = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
+const globalKey = "__vueuse_ssr_handlers__";
+const handlers = /* @__PURE__ */ getHandlers();
+function getHandlers() {
+ if (!(globalKey in _global))
+ _global[globalKey] = _global[globalKey] || {};
+ return _global[globalKey];
+}
+function getSSRHandler(key, fallback) {
+ return handlers[key] || fallback;
+}
+function guessSerializerType(rawInit) {
+ return rawInit == null ? "any" : rawInit instanceof Set ? "set" : rawInit instanceof Map ? "map" : rawInit instanceof Date ? "date" : typeof rawInit === "boolean" ? "boolean" : typeof rawInit === "string" ? "string" : typeof rawInit === "object" ? "object" : !Number.isNaN(rawInit) ? "number" : "any";
+}
+const StorageSerializers = {
+ boolean: {
+ read: (v) => v === "true",
+ write: (v) => String(v)
+ },
+ object: {
+ read: (v) => JSON.parse(v),
+ write: (v) => JSON.stringify(v)
+ },
+ number: {
+ read: (v) => Number.parseFloat(v),
+ write: (v) => String(v)
+ },
+ any: {
+ read: (v) => v,
+ write: (v) => String(v)
+ },
+ string: {
+ read: (v) => v,
+ write: (v) => String(v)
+ },
+ map: {
+ read: (v) => new Map(JSON.parse(v)),
+ write: (v) => JSON.stringify(Array.from(v.entries()))
+ },
+ set: {
+ read: (v) => new Set(JSON.parse(v)),
+ write: (v) => JSON.stringify(Array.from(v))
+ },
+ date: {
+ read: (v) => new Date(v),
+ write: (v) => v.toISOString()
+ }
+};
+const customStorageEventName = "vueuse-storage";
+function useStorage(key, defaults2, storage, options = {}) {
+ var _a;
+ const {
+ flush = "pre",
+ deep = true,
+ listenToStorageChanges = true,
+ writeDefaults = true,
+ mergeDefaults = false,
+ shallow,
+ window: window2 = defaultWindow,
+ eventFilter,
+ onError = (e) => {
+ console.error(e);
+ },
+ initOnMounted
+ } = options;
+ const data = (shallow ? shallowRef : ref)(typeof defaults2 === "function" ? defaults2() : defaults2);
+ if (!storage) {
+ try {
+ storage = getSSRHandler("getDefaultStorage", () => {
+ var _a2;
+ return (_a2 = defaultWindow) == null ? void 0 : _a2.localStorage;
+ })();
+ } catch (e) {
+ onError(e);
+ }
+ }
+ if (!storage)
+ return data;
+ const rawInit = toValue(defaults2);
+ const type = guessSerializerType(rawInit);
+ const serializer = (_a = options.serializer) != null ? _a : StorageSerializers[type];
+ const { pause: pauseWatch, resume: resumeWatch } = watchPausable(
+ data,
+ () => write(data.value),
+ { flush, deep, eventFilter }
+ );
+ if (window2 && listenToStorageChanges) {
+ tryOnMounted(() => {
+ if (storage instanceof Storage)
+ useEventListener(window2, "storage", update3);
+ else
+ useEventListener(window2, customStorageEventName, updateFromCustomEvent);
+ if (initOnMounted)
+ update3();
+ });
+ }
+ if (!initOnMounted)
+ update3();
+ function dispatchWriteEvent(oldValue, newValue) {
+ if (window2) {
+ const payload = {
+ key,
+ oldValue,
+ newValue,
+ storageArea: storage
+ };
+ window2.dispatchEvent(storage instanceof Storage ? new StorageEvent("storage", payload) : new CustomEvent(customStorageEventName, {
+ detail: payload
+ }));
+ }
+ }
+ function write(v) {
+ try {
+ const oldValue = storage.getItem(key);
+ if (v == null) {
+ dispatchWriteEvent(oldValue, null);
+ storage.removeItem(key);
+ } else {
+ const serialized = serializer.write(v);
+ if (oldValue !== serialized) {
+ storage.setItem(key, serialized);
+ dispatchWriteEvent(oldValue, serialized);
+ }
+ }
+ } catch (e) {
+ onError(e);
+ }
+ }
+ function read(event) {
+ const rawValue = event ? event.newValue : storage.getItem(key);
+ if (rawValue == null) {
+ if (writeDefaults && rawInit != null)
+ storage.setItem(key, serializer.write(rawInit));
+ return rawInit;
+ } else if (!event && mergeDefaults) {
+ const value = serializer.read(rawValue);
+ if (typeof mergeDefaults === "function")
+ return mergeDefaults(value, rawInit);
+ else if (type === "object" && !Array.isArray(value))
+ return { ...rawInit, ...value };
+ return value;
+ } else if (typeof rawValue !== "string") {
+ return rawValue;
+ } else {
+ return serializer.read(rawValue);
+ }
+ }
+ function update3(event) {
+ if (event && event.storageArea !== storage)
+ return;
+ if (event && event.key == null) {
+ data.value = rawInit;
+ return;
+ }
+ if (event && event.key !== key)
+ return;
+ pauseWatch();
+ try {
+ if ((event == null ? void 0 : event.newValue) !== serializer.write(data.value))
+ data.value = read(event);
+ } catch (e) {
+ onError(e);
+ } finally {
+ if (event)
+ nextTick(resumeWatch);
+ else
+ resumeWatch();
+ }
+ }
+ function updateFromCustomEvent(event) {
+ update3(event.detail);
+ }
+ return data;
+}
+function useLocalStorage(key, initialValue, options = {}) {
+ const { window: window2 = defaultWindow } = options;
+ return useStorage(key, initialValue, window2 == null ? void 0 : window2.localStorage, options);
+}
+const useMusicHistory = () => {
+ const musicHistory2 = useLocalStorage("musicHistory", []);
+ const addMusic = (music) => {
+ const index = musicHistory2.value.findIndex((item) => item.id === music.id);
+ if (index !== -1) {
+ musicHistory2.value[index].count = (musicHistory2.value[index].count || 0) + 1;
+ musicHistory2.value.unshift(musicHistory2.value.splice(index, 1)[0]);
+ } else {
+ musicHistory2.value.unshift({ ...music, count: 1 });
+ }
+ };
+ const delMusic = (music) => {
+ const index = musicHistory2.value.findIndex((item) => item.id === music.id);
+ if (index !== -1) {
+ musicHistory2.value.splice(index, 1);
+ }
+ };
+ const musicList = ref(musicHistory2.value);
+ watch(
+ () => musicHistory2.value,
+ () => {
+ musicList.value = musicHistory2.value;
+ }
+ );
+ return {
+ musicHistory: musicHistory2,
+ musicList,
+ addMusic,
+ delMusic
+ };
+};
+class AudioService {
+ currentSound = null;
+ play(url) {
+ if (this.currentSound) {
+ this.currentSound.unload();
+ }
+ this.currentSound = null;
+ this.currentSound = new howler.Howl({
+ src: [url],
+ html5: true,
+ autoplay: true,
+ volume: localStorage.getItem("volume") ? parseFloat(localStorage.getItem("volume")) : 1
+ });
+ return this.currentSound;
+ }
+ getCurrentSound() {
+ return this.currentSound;
+ }
+ stop() {
+ if (this.currentSound) {
+ this.currentSound.stop();
+ this.currentSound.unload();
+ this.currentSound = null;
+ }
+ }
+ // 监听播放
+ onPlay(callback) {
+ if (this.currentSound) {
+ this.currentSound.on("play", callback);
+ }
+ }
+ // 监听暂停
+ onPause(callback) {
+ if (this.currentSound) {
+ this.currentSound.on("pause", callback);
+ }
+ }
+ // 监听结束
+ onEnd(callback) {
+ if (this.currentSound) {
+ this.currentSound.on("end", callback);
+ }
+ }
+}
+const audioService = new AudioService();
+const getImageLinearBackground = async (imageSrc) => {
+ try {
+ const primaryColor = await getImagePrimaryColor(imageSrc);
+ return {
+ backgroundColor: generateGradientBackground(primaryColor),
+ primaryColor
+ };
+ } catch (error) {
+ console.error("error", error);
+ return {
+ backgroundColor: "",
+ primaryColor: ""
+ };
+ }
+};
+const getImageBackground = async (img) => {
+ try {
+ const primaryColor = await getImageColor(img);
+ return {
+ backgroundColor: generateGradientBackground(primaryColor),
+ primaryColor
+ };
+ } catch (error) {
+ console.error("error", error);
+ return {
+ backgroundColor: "",
+ primaryColor: ""
+ };
+ }
+};
+const getImageColor = (img) => {
+ return new Promise((resolve2, reject) => {
+ const canvas = document.createElement("canvas");
+ const ctx2 = canvas.getContext("2d");
+ if (!ctx2) {
+ reject(new Error("无法获取canvas上下文"));
+ return;
+ }
+ canvas.width = img.width;
+ canvas.height = img.height;
+ ctx2.drawImage(img, 0, 0, canvas.width, canvas.height);
+ const imageData = ctx2.getImageData(0, 0, canvas.width, canvas.height);
+ const color = getAverageColor(imageData.data);
+ resolve2(`rgb(${color.join(",")})`);
+ });
+};
+const getImagePrimaryColor = (imageSrc) => {
+ return new Promise((resolve2, reject) => {
+ const img = new Image();
+ img.crossOrigin = "Anonymous";
+ img.src = imageSrc;
+ img.onload = () => {
+ const canvas = document.createElement("canvas");
+ const ctx2 = canvas.getContext("2d");
+ if (!ctx2) {
+ reject(new Error("无法获取canvas上下文"));
+ return;
+ }
+ canvas.width = img.width;
+ canvas.height = img.height;
+ ctx2.drawImage(img, 0, 0, canvas.width, canvas.height);
+ const imageData = ctx2.getImageData(0, 0, canvas.width, canvas.height);
+ const color = getAverageColor(imageData.data);
+ resolve2(`rgb(${color.join(",")})`);
+ };
+ img.onerror = () => reject(new Error("图片加载失败"));
+ });
+};
+const getAverageColor = (data) => {
+ let r = 0;
+ let g = 0;
+ let b = 0;
+ let count = 0;
+ for (let i = 0; i < data.length; i += 4) {
+ r += data[i];
+ g += data[i + 1];
+ b += data[i + 2];
+ count++;
+ }
+ return [Math.round(r / count), Math.round(g / count), Math.round(b / count)];
+};
+const generateGradientBackground = (color) => {
+ const [r, g, b] = color.match(/\d+/g)?.map(Number) || [0, 0, 0];
+ const [h2, s, l] = rgbToHsl(r, g, b);
+ const lightL = Math.min(l + 0.2, 0.95);
+ const darkL = Math.max(l - 0.3, 0.05);
+ const midL = (lightL + darkL) / 2;
+ const lightS = Math.min(s * 0.8, 1);
+ const darkS = Math.min(s * 1.2, 1);
+ const [lightR, lightG, lightB] = hslToRgb(h2, lightS, lightL);
+ const [midR, midG, midB] = hslToRgb(h2, s, midL);
+ const [darkR, darkG, darkB] = hslToRgb(h2, darkS, darkL);
+ const lightColor = `rgb(${lightR}, ${lightG}, ${lightB})`;
+ const midColor = `rgb(${midR}, ${midG}, ${midB})`;
+ const darkColor = `rgb(${darkR}, ${darkG}, ${darkB})`;
+ return `linear-gradient(to bottom, ${lightColor} 0%, ${midColor} 50%, ${darkColor} 100%)`;
+};
+function rgbToHsl(r, g, b) {
+ r /= 255;
+ g /= 255;
+ b /= 255;
+ const max = Math.max(r, g, b);
+ const min = Math.min(r, g, b);
+ let h2 = 0;
+ let s;
+ const l = (max + min) / 2;
+ if (max === min) {
+ h2 = s = 0;
+ } else {
+ const d = max - min;
+ s = l > 0.5 ? d / (2 - max - min) : d / (max + min);
+ switch (max) {
+ case r:
+ h2 = (g - b) / d + (g < b ? 6 : 0);
+ break;
+ case g:
+ h2 = (b - r) / d + 2;
+ break;
+ case b:
+ h2 = (r - g) / d + 4;
+ break;
+ }
+ h2 /= 6;
+ }
+ return [h2, s, l];
+}
+function hslToRgb(h2, s, l) {
+ let r;
+ let g;
+ let b;
+ if (s === 0) {
+ r = g = b = l;
+ } else {
+ const hue2rgb = (p22, q2, t) => {
+ if (t < 0) t += 1;
+ if (t > 1) t -= 1;
+ if (t < 1 / 6) return p22 + (q2 - p22) * 6 * t;
+ if (t < 1 / 2) return q2;
+ if (t < 2 / 3) return p22 + (q2 - p22) * (2 / 3 - t) * 6;
+ return p22;
+ };
+ const q = l < 0.5 ? l * (1 + s) : l + s - l * s;
+ const p2 = 2 * l - q;
+ r = hue2rgb(p2, q, h2 + 1 / 3);
+ g = hue2rgb(p2, q, h2);
+ b = hue2rgb(p2, q, h2 - 1 / 3);
+ }
+ return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)];
+}
+const calculateBrightness = (r, g, b) => {
+ return (0.299 * r + 0.587 * g + 0.114 * b) / 255;
+};
+const parseGradient = (gradientStr) => {
+ const matches2 = gradientStr.match(/rgb\((\d+),\s*(\d+),\s*(\d+)\)/g);
+ if (!matches2) return [];
+ return matches2.map((rgb) => {
+ const [r, g, b] = rgb.match(/\d+/g).map(Number);
+ return { r, g, b };
+ });
+};
+const interpolateRGB = (start, end, progress) => {
+ return Math.round(start + (end - start) * progress);
+};
+const createGradientString = (colors2, percentages = [0, 50, 100]) => {
+ return `linear-gradient(to bottom, ${colors2.map((color, i) => `rgb(${color.r}, ${color.g}, ${color.b}) ${percentages[i]}%`).join(", ")})`;
+};
+const getTextColors = (gradient = "") => {
+ const defaultColors = {
+ primary: "rgba(255, 255, 255, 0.54)",
+ active: "#ffffff",
+ theme: "light"
+ };
+ if (!gradient) return defaultColors;
+ const colors2 = parseGradient(gradient);
+ if (!colors2.length) return defaultColors;
+ const mainColor = colors2[1] || colors2[0];
+ const brightness = calculateBrightness(mainColor.r, mainColor.g, mainColor.b);
+ const isDark = brightness > 0.6;
+ return {
+ primary: isDark ? "rgba(0, 0, 0, 0.54)" : "rgba(255, 255, 255, 0.54)",
+ active: isDark ? "#000000" : "#ffffff",
+ theme: isDark ? "dark" : "light"
+ };
+};
+const getHoverBackgroundColor = (isDark) => {
+ return isDark ? "rgba(0, 0, 0, 0.08)" : "rgba(255, 255, 255, 0.08)";
+};
+const animateGradient = (oldGradient, newGradient, onUpdate, duration2 = 1e3) => {
+ const startColors = parseGradient(oldGradient);
+ const endColors = parseGradient(newGradient);
+ if (startColors.length !== endColors.length) return null;
+ const startTime = performance.now();
+ const animate = (currentTime) => {
+ const elapsed = currentTime - startTime;
+ const progress = Math.min(elapsed / duration2, 1);
+ const currentColors = startColors.map((startColor, i) => ({
+ r: interpolateRGB(startColor.r, endColors[i].r, progress),
+ g: interpolateRGB(startColor.g, endColors[i].g, progress),
+ b: interpolateRGB(startColor.b, endColors[i].b, progress)
+ }));
+ onUpdate(createGradientString(currentColors));
+ if (progress < 1) {
+ return requestAnimationFrame(animate);
+ }
+ return null;
+ };
+ return requestAnimationFrame(animate);
+};
+const musicHistory = useMusicHistory();
+const getSongUrl = async (id) => {
+ const { data } = await getMusicUrl(id);
+ let url = "";
+ try {
+ if (data.data[0].freeTrialInfo || !data.data[0].url) {
+ const res = await getParsingMusicUrl(id);
+ console.log("res", res);
+ url = res.data.data.url;
+ }
+ } catch (error) {
+ console.error("error", error);
+ }
+ url = url || data.data[0].url;
+ return getMusicProxyUrl(url);
+};
+const getSongDetail = async (playMusic) => {
+ playMusic.playLoading = true;
+ const playMusicUrl = await getSongUrl(playMusic.id);
+ const { backgroundColor, primaryColor } = playMusic.backgroundColor && playMusic.primaryColor ? playMusic : await getImageLinearBackground(getImgUrl(playMusic?.picUrl, "30y30"));
+ playMusic.playLoading = false;
+ return { ...playMusic, playMusicUrl, backgroundColor, primaryColor };
+};
+const useMusicListHook = () => {
+ const handlePlayMusic2 = async (state2, playMusic) => {
+ const updatedPlayMusic = await getSongDetail(playMusic);
+ state2.playMusic = updatedPlayMusic;
+ state2.playMusicUrl = updatedPlayMusic.playMusicUrl;
+ state2.play = true;
+ document.title = `${updatedPlayMusic.name} - ${updatedPlayMusic?.song?.artists?.reduce((prev, curr) => `${prev}${curr.name}/`, "")}`;
+ loadLrcAsync(state2, updatedPlayMusic.id);
+ musicHistory.addMusic(state2.playMusic);
+ const playListIndex = state2.playList.findIndex((item) => item.id === playMusic.id);
+ state2.playListIndex = playListIndex;
+ fetchSongs(state2, playListIndex + 1, playListIndex + 6);
+ };
+ const preloadNextSong = (nextSongUrl) => {
+ const sound = new howler.Howl({
+ src: [nextSongUrl],
+ html5: true,
+ preload: true,
+ autoplay: false
+ });
+ return sound;
+ };
+ const fetchSongs = async (state2, startIndex, endIndex) => {
+ const songs = state2.playList.slice(
+ Math.max(0, startIndex),
+ Math.min(endIndex, state2.playList.length)
+ );
+ const detailedSongs = await Promise.all(
+ songs.map(async (song) => {
+ if (!song.playMusicUrl) {
+ return await getSongDetail(song);
+ }
+ return song;
+ })
+ );
+ const nextSong = detailedSongs[0];
+ if (!(nextSong.lyric && nextSong.lyric.lrcTimeArray.length > 0)) {
+ nextSong.lyric = await loadLrc(nextSong.id);
+ }
+ detailedSongs.forEach((song, index) => {
+ state2.playList[startIndex + index] = song;
+ });
+ preloadNextSong(nextSong.playMusicUrl);
+ };
+ const nextPlay2 = async (state2) => {
+ if (state2.playList.length === 0) {
+ state2.play = true;
+ return;
+ }
+ const playListIndex = (state2.playListIndex + 1) % state2.playList.length;
+ await handlePlayMusic2(state2, state2.playList[playListIndex]);
+ };
+ const prevPlay2 = async (state2) => {
+ if (state2.playList.length === 0) {
+ state2.play = true;
+ return;
+ }
+ const playListIndex = (state2.playListIndex - 1 + state2.playList.length) % state2.playList.length;
+ await handlePlayMusic2(state2, state2.playList[playListIndex]);
+ await fetchSongs(state2, playListIndex - 5, playListIndex);
+ };
+ const parseTime = (timeString) => {
+ const [minutes, seconds] = timeString.split(":");
+ return Number(minutes) * 60 + Number(seconds);
+ };
+ const parseLyricLine = (lyricLine) => {
+ const TIME_REGEX = /(\d{2}:\d{2}(\.\d*)?)/g;
+ const LRC_REGEX = /(\[(\d{2}):(\d{2})(\.(\d*))?\])/g;
+ const timeText = lyricLine.match(TIME_REGEX)?.[0] || "";
+ const time2 = parseTime(timeText);
+ const text = lyricLine.replace(LRC_REGEX, "").trim();
+ return { time: time2, text };
+ };
+ const parseLyrics = (lyricsString) => {
+ const lines = lyricsString.split("\n");
+ const lyrics = [];
+ const times = [];
+ lines.forEach((line) => {
+ const { time: time2, text } = parseLyricLine(line);
+ times.push(time2);
+ lyrics.push({ text, trText: "" });
+ });
+ return { lyrics, times };
+ };
+ const loadLrc = async (playMusicId) => {
+ try {
+ const { data } = await getMusicLrc(playMusicId);
+ const { lyrics, times } = parseLyrics(data.lrc.lyric);
+ const tlyric = {};
+ if (data.tlyric.lyric) {
+ const { lyrics: tLyrics, times: tTimes } = parseLyrics(data.tlyric.lyric);
+ tLyrics.forEach((lyric, index) => {
+ tlyric[tTimes[index].toString()] = lyric.text;
+ });
+ }
+ lyrics.forEach((item, index) => {
+ item.trText = item.text ? tlyric[times[index].toString()] || "" : "";
+ });
+ return {
+ lrcTimeArray: times,
+ lrcArray: lyrics
+ };
+ } catch (err) {
+ console.error("Error loading lyrics:", err);
+ return {
+ lrcTimeArray: [],
+ lrcArray: []
+ };
+ }
+ };
+ const loadLrcAsync = async (state2, playMusicId) => {
+ if (state2.playMusic.lyric && state2.playMusic.lyric.lrcTimeArray.length > 0) {
+ return;
+ }
+ const lyrics = await loadLrc(playMusicId);
+ state2.playMusic.lyric = lyrics;
+ };
+ const play = () => {
+ audioService.getCurrentSound()?.play();
+ };
+ const pause = () => {
+ audioService.getCurrentSound()?.pause();
+ };
+ return {
+ handlePlayMusic: handlePlayMusic2,
+ nextPlay: nextPlay2,
+ prevPlay: prevPlay2,
+ play,
+ pause
+ };
+};
+const layoutRouter = [
+ {
+ path: "/",
+ name: "home",
+ meta: {
+ title: "首页",
+ icon: "icon-Home",
+ keepAlive: true,
+ isMobile: true
+ },
+ component: () => __vitePreload(() => import("./index-DSilVM87.js"), true ? __vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14]) : void 0, import.meta.url)
+ },
+ {
+ path: "/search",
+ name: "search",
+ meta: {
+ title: "搜索",
+ noScroll: true,
+ icon: "icon-Search",
+ keepAlive: true,
+ isMobile: true
+ },
+ component: () => __vitePreload(() => import("./index-C-VCusx9.js"), true ? __vite__mapDeps([15,1,3,4,5,6,7,2,8,9,10,11,16,17,18,19,20,21]) : void 0, import.meta.url)
+ },
+ {
+ path: "/list",
+ name: "list",
+ meta: {
+ title: "歌单",
+ icon: "icon-Paper",
+ keepAlive: true,
+ isMobile: true
+ },
+ component: () => __vitePreload(() => import("./index-Bc5fdT5j.js"), true ? __vite__mapDeps([22,1,2,3,4,5,6,7,8,9,10,11,23]) : void 0, import.meta.url)
+ },
+ {
+ path: "/mv",
+ name: "mv",
+ meta: {
+ title: "MV",
+ icon: "icon-recordfill",
+ keepAlive: true,
+ isMobile: true
+ },
+ component: () => __vitePreload(() => import("./index-SvIREzLs.js"), true ? __vite__mapDeps([24,16,17,4,5,18,8,6,19,25]) : void 0, import.meta.url)
+ },
+ // {
+ // path: '/history',
+ // name: 'history',
+ // meta: {
+ // title: '历史',
+ // icon: 'icon-a-TicketStar',
+ // keepAlive: true,
+ // },
+ // component: () => import('@/views/history/index.vue'),
+ // },
+ {
+ path: "/history",
+ name: "history",
+ component: () => __vitePreload(() => import("./index-DhLgZEXT.js"), true ? __vite__mapDeps([26,12,3,4,5,6,7,13,27]) : void 0, import.meta.url),
+ meta: {
+ title: "收藏历史",
+ icon: "icon-a-TicketStar",
+ keepAlive: true
+ }
+ },
+ {
+ path: "/user",
+ name: "user",
+ meta: {
+ title: "用户",
+ icon: "icon-Profile",
+ keepAlive: true,
+ noScroll: true,
+ isMobile: true
+ },
+ component: () => __vitePreload(() => import("./index-BPmJoRDi.js"), true ? __vite__mapDeps([28,2,3,4,5,6,7,8,9,10,11,29]) : void 0, import.meta.url)
+ },
+ {
+ path: "/set",
+ name: "set",
+ meta: {
+ title: "设置",
+ icon: "ri-settings-3-fill",
+ keepAlive: true,
+ noScroll: true
+ },
+ component: () => __vitePreload(() => import("./index-RCxsGzpS.js"), true ? __vite__mapDeps([30,31,5,10,18,32]) : void 0, import.meta.url)
+ }
+];
+const applyTheme = (theme) => {
+ if (theme === "dark") {
+ document.documentElement.classList.add("dark");
+ } else {
+ document.documentElement.classList.remove("dark");
+ }
+ localStorage.setItem("theme", theme);
+};
+const getCurrentTheme = () => {
+ return localStorage.getItem("theme") || "light";
+};
+const defaultSettings = {
+ isProxy: false,
+ noAnimate: false,
+ animationSpeed: 1,
+ author: "Alger",
+ authorUrl: "https://github.com/algerkong"
+};
+function getLocalStorageItem(key, defaultValue) {
+ const item = localStorage.getItem(key);
+ return item ? JSON.parse(item) : defaultValue;
+}
+const state = {
+ menus: layoutRouter,
+ play: false,
+ isPlay: false,
+ playMusic: {},
+ playMusicUrl: "",
+ user: getLocalStorageItem("user", null),
+ playList: [],
+ playListIndex: 0,
+ setData: defaultSettings,
+ lyric: {},
+ isMobile: false,
+ searchValue: "",
+ searchType: 1,
+ favoriteList: getLocalStorageItem("favoriteList", []),
+ playMode: getLocalStorageItem("playMode", 0),
+ theme: getCurrentTheme()
+};
+const { handlePlayMusic, nextPlay, prevPlay } = useMusicListHook();
+const mutations = {
+ setMenus(state2, menus) {
+ state2.menus = menus;
+ },
+ async setPlay(state2, playMusic) {
+ await handlePlayMusic(state2, playMusic);
+ },
+ setIsPlay(state2, isPlay) {
+ state2.isPlay = isPlay;
+ },
+ setPlayMusic(state2, play) {
+ state2.play = play;
+ },
+ setPlayList(state2, playList) {
+ state2.playListIndex = playList.findIndex((item) => item.id === state2.playMusic.id);
+ state2.playList = playList;
+ },
+ async nextPlay(state2) {
+ await nextPlay(state2);
+ },
+ async prevPlay(state2) {
+ await prevPlay(state2);
+ },
+ setSetData(state2, setData2) {
+ state2.setData = setData2;
+ if (isElectron) {
+ window.electron.ipcRenderer.send("set-store-value", "set", JSON.parse(JSON.stringify(setData2)));
+ } else {
+ localStorage.setItem("appSettings", JSON.stringify(setData2));
+ }
+ },
+ addToFavorite(state2, songId) {
+ if (!state2.favoriteList.includes(songId)) {
+ state2.favoriteList = [songId, ...state2.favoriteList];
+ localStorage.setItem("favoriteList", JSON.stringify(state2.favoriteList));
+ }
+ },
+ removeFromFavorite(state2, songId) {
+ state2.favoriteList = state2.favoriteList.filter((id) => id !== songId);
+ localStorage.setItem("favoriteList", JSON.stringify(state2.favoriteList));
+ },
+ togglePlayMode(state2) {
+ state2.playMode = (state2.playMode + 1) % 3;
+ localStorage.setItem("playMode", JSON.stringify(state2.playMode));
+ },
+ toggleTheme(state2) {
+ state2.theme = state2.theme === "dark" ? "light" : "dark";
+ applyTheme(state2.theme);
+ }
+};
+const actions = {
+ initializeSettings({ commit: commit2 }) {
+ if (isElectron) {
+ const setData2 = window.electron.ipcRenderer.sendSync("get-store-value", "set");
+ commit2("setSetData", setData2 || defaultSettings);
+ } else {
+ const savedSettings = localStorage.getItem("appSettings");
+ if (savedSettings) {
+ commit2("setSetData", {
+ ...defaultSettings,
+ ...JSON.parse(savedSettings)
+ });
+ } else {
+ commit2("setSetData", defaultSettings);
+ }
+ }
+ },
+ initializeTheme({ state: state2 }) {
+ applyTheme(state2.theme);
+ }
+};
+const store = createStore({
+ state,
+ mutations,
+ actions
+});
+const setBackgroundImg = (url) => {
+ return `background-image:url(${url})`;
+};
+const setAnimationClass = (type) => {
+ if (store.state.setData && store.state.setData.noAnimate) {
+ return "";
+ }
+ const speed = store.state.setData?.animationSpeed || 1;
+ let speedClass = "";
+ if (speed <= 0.3) speedClass = "animate__slower";
+ else if (speed <= 0.8) speedClass = "animate__slow";
+ else if (speed >= 2.5) speedClass = "animate__faster";
+ else if (speed >= 1.5) speedClass = "animate__fast";
+ return `animate__animated ${type}${speedClass ? ` ${speedClass}` : ""}`;
+};
+const setAnimationDelay = (index = 6, time2 = 50) => {
+ const speed = store.state.setData?.animationSpeed || 1;
+ return `animation-delay:${index * time2 / (speed * 2)}ms`;
+};
+const secondToMinute = (s) => {
+ if (!s) {
+ return "00:00";
+ }
+ const minute = Math.floor(s / 60);
+ const second = Math.floor(s % 60);
+ const minuteStr = minute > 9 ? minute.toString() : `0${minute.toString()}`;
+ const secondStr = second > 9 ? second.toString() : `0${second.toString()}`;
+ return `${minuteStr}:${secondStr}`;
+};
+const units = [
+ { value: 1e8, symbol: "亿" },
+ { value: 1e4, symbol: "万" }
+];
+const formatNumber = (num) => {
+ num = Number(num);
+ for (let i = 0; i < units.length; i++) {
+ if (num >= units[i].value) {
+ return `${(num / units[i].value).toFixed(1)}${units[i].symbol}`;
+ }
+ }
+ return num.toString();
+};
+const windowData = window;
+const getIsMc = () => {
+ if (!windowData.electron) {
+ return false;
+ }
+ const setData2 = window.electron.ipcRenderer.sendSync("get-store-value", "set");
+ if (setData2.isProxy) {
+ return true;
+ }
+ return false;
+};
+const ProxyUrl = "http://110.42.251.190:9898";
+const getMusicProxyUrl = (url) => {
+ if (!getIsMc()) {
+ return url;
+ }
+ const PUrl = url.split("").join("+");
+ return `${ProxyUrl}/mc?url=${PUrl}`;
+};
+const getImgUrl = (url, size2 = "") => {
+ const bdUrl = "https://image.baidu.com/search/down?url=";
+ const imgUrl = `${url}?param=${size2}`;
+ if (!getIsMc()) {
+ return imgUrl;
+ }
+ return `${bdUrl}${encodeURIComponent(imgUrl)}`;
+};
+const isMobile = computed(() => {
+ const flag = navigator.userAgent.match(
+ /(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i
+ );
+ store.state.isMobile = !!flag;
+ if (flag) document.documentElement.classList.add("mobile");
+ return !!flag;
+});
+const isElectron = window.electron !== void 0;
+const checkUpdate = async () => {
+ try {
+ const response = await axios.get("https://api.github.com/repos/algerkong/AlgerMusicPlayer/releases/latest");
+ const latestVersion = response.data.tag_name.replace("v", "");
+ const currentVersion = config.version;
+ console.log(latestVersion, currentVersion);
+ const latest = latestVersion.split(".").map(Number);
+ const current = currentVersion.split(".").map(Number);
+ let hasUpdate = false;
+ for (let i = 0; i < 3; i++) {
+ if (latest[i] > current[i]) {
+ hasUpdate = true;
+ break;
+ } else if (latest[i] < current[i]) {
+ break;
+ }
+ }
+ return {
+ hasUpdate,
+ latestVersion,
+ currentVersion,
+ releaseInfo: response.data
+ };
+ } catch (error) {
+ console.error("检查更新失败:", error);
+ return {
+ hasUpdate: false,
+ latestVersion: "",
+ currentVersion: config.version,
+ releaseInfo: null
+ };
+ }
+};
+const _hoisted_1$3 = { class: "modal-content" };
+const _hoisted_2$3 = { class: "modal-header" };
+const _hoisted_3$2 = { class: "app-info" };
+const _hoisted_4$2 = { class: "app-name" };
+const _hoisted_5$1 = { class: "modal-actions" };
+const _sfc_main$5 = /* @__PURE__ */ defineComponent({
+ __name: "InstallAppModal",
+ setup(__props) {
+ const showModal = ref(false);
+ const noPrompt = ref(false);
+ const closeModal = () => {
+ showModal.value = false;
+ if (noPrompt.value) {
+ localStorage.setItem("installPromptDismissed", "true");
+ }
+ };
+ onMounted(() => {
+ if (isElectron || isMobile.value) {
+ return;
+ }
+ const isDismissed = localStorage.getItem("installPromptDismissed") === "true";
+ if (isDismissed) {
+ return;
+ }
+ showModal.value = true;
+ });
+ const handleInstall = async () => {
+ const { userAgent } = navigator;
+ console.log("userAgent", userAgent);
+ const isMac = userAgent.includes("Mac");
+ const isWindows = userAgent.includes("Win");
+ const isARM = userAgent.includes("ARM") || userAgent.includes("arm") || userAgent.includes("OS X");
+ const isX64 = userAgent.includes("x86_64") || userAgent.includes("Win64") || userAgent.includes("WOW64");
+ const isX86 = !isX64 && (userAgent.includes("i686") || userAgent.includes("i386") || userAgent.includes("Win32"));
+ const getDownloadUrl = (os, arch) => {
+ const version2 = config.version;
+ const setup = os !== "mac" ? "Setup_" : "";
+ return `https://gh.llkk.cc/https://github.com/algerkong/AlgerMusicPlayer/releases/download/${version2}/AlgerMusic_${version2}_${setup}${arch}.${os === "mac" ? "dmg" : "exe"}`;
+ };
+ const osType = isMac ? "mac" : isWindows ? "windows" : null;
+ const archType = isARM ? "arm64" : isX64 ? "x64" : isX86 ? "x86" : null;
+ const downloadUrl = osType && archType ? getDownloadUrl(osType, archType) : null;
+ window.open(downloadUrl || "https://github.com/algerkong/AlgerMusicPlayer/releases", "_blank");
+ };
+ return (_ctx, _cache) => {
+ const _component_n_checkbox = __unplugin_components_0$2;
+ const _component_n_button = Button;
+ const _component_n_modal = __unplugin_components_3;
+ return openBlock(), createBlock(_component_n_modal, {
+ show: showModal.value,
+ "onUpdate:show": _cache[1] || (_cache[1] = ($event) => showModal.value = $event),
+ preset: "dialog",
+ "show-icon": false,
+ "mask-closable": true,
+ class: "install-app-modal"
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1$3, [
+ createBaseVNode("div", _hoisted_2$3, [
+ _cache[4] || (_cache[4] = createBaseVNode("div", { class: "app-icon" }, [
+ createBaseVNode("img", {
+ src: _imports_0,
+ alt: "App Icon"
+ })
+ ], -1)),
+ createBaseVNode("div", _hoisted_3$2, [
+ createBaseVNode("h2", _hoisted_4$2, "Alger Music Player " + toDisplayString(unref(config).version), 1),
+ _cache[3] || (_cache[3] = createBaseVNode("p", { class: "app-desc mb-2" }, "在桌面安装应用,获得更好的体验", -1)),
+ createVNode(_component_n_checkbox, {
+ checked: noPrompt.value,
+ "onUpdate:checked": _cache[0] || (_cache[0] = ($event) => noPrompt.value = $event)
+ }, {
+ default: withCtx(() => _cache[2] || (_cache[2] = [
+ createTextVNode("不再提示")
+ ])),
+ _: 1
+ }, 8, ["checked"])
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_5$1, [
+ createVNode(_component_n_button, {
+ class: "cancel-btn",
+ onClick: closeModal
+ }, {
+ default: withCtx(() => _cache[5] || (_cache[5] = [
+ createTextVNode("暂不安装")
+ ])),
+ _: 1
+ }),
+ createVNode(_component_n_button, {
+ type: "primary",
+ class: "install-btn",
+ onClick: handleInstall
+ }, {
+ default: withCtx(() => _cache[6] || (_cache[6] = [
+ createTextVNode("立即安装")
+ ])),
+ _: 1
+ })
+ ]),
+ _cache[7] || (_cache[7] = createBaseVNode("div", { class: "modal-desc mt-4 text-center" }, [
+ createBaseVNode("p", { class: "text-xs text-gray-400" }, [
+ createTextVNode(" 下载遇到问题?去 "),
+ createBaseVNode("a", {
+ class: "text-green-500",
+ target: "_blank",
+ href: "https://github.com/algerkong/AlgerMusicPlayer/releases"
+ }, "GitHub"),
+ createTextVNode(" 下载最新版本 ")
+ ])
+ ], -1))
+ ])
+ ]),
+ _: 1
+ }, 8, ["show"]);
+ };
+ }
+});
+const _export_sfc = (sfc, props) => {
+ const target = sfc.__vccOpts || sfc;
+ for (const [key, val] of props) {
+ target[key] = val;
+ }
+ return target;
+};
+const InstallAppModal = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-40e226b5"]]);
+const _sfc_main$4 = /* @__PURE__ */ defineComponent({
+ __name: "PlayBottom",
+ props: {
+ height: {
+ type: String,
+ default: void 0
+ }
+ },
+ setup(__props) {
+ const store2 = useStore();
+ const isPlay = computed(() => store2.state.isPlay);
+ return (_ctx, _cache) => {
+ return unref(isPlay) ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: "bottom",
+ style: normalizeStyle({ height: __props.height })
+ }, null, 4)) : createCommentVNode("", true);
+ };
+ }
+});
+const PlayBottom = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-7497922f"]]);
+function _getDefaults() {
+ return {
+ async: false,
+ breaks: false,
+ extensions: null,
+ gfm: true,
+ hooks: null,
+ pedantic: false,
+ renderer: null,
+ silent: false,
+ tokenizer: null,
+ walkTokens: null
+ };
+}
+let _defaults = _getDefaults();
+function changeDefaults(newDefaults) {
+ _defaults = newDefaults;
+}
+const noopTest = { exec: () => null };
+function edit(regex, opt = "") {
+ let source = typeof regex === "string" ? regex : regex.source;
+ const obj = {
+ replace: (name2, val) => {
+ let valSource = typeof val === "string" ? val : val.source;
+ valSource = valSource.replace(other.caret, "$1");
+ source = source.replace(name2, valSource);
+ return obj;
+ },
+ getRegex: () => {
+ return new RegExp(source, opt);
+ }
+ };
+ return obj;
+}
+const other = {
+ codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
+ outputLinkReplace: /\\([\[\]])/g,
+ indentCodeCompensation: /^(\s+)(?:```)/,
+ beginningSpace: /^\s+/,
+ endingHash: /#$/,
+ startingSpaceChar: /^ /,
+ endingSpaceChar: / $/,
+ nonSpaceChar: /[^ ]/,
+ newLineCharGlobal: /\n/g,
+ tabCharGlobal: /\t/g,
+ multipleSpaceGlobal: /\s+/g,
+ blankLine: /^[ \t]*$/,
+ doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
+ blockquoteStart: /^ {0,3}>/,
+ blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
+ blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
+ listReplaceTabs: /^\t+/,
+ listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
+ listIsTask: /^\[[ xX]\] /,
+ listReplaceTask: /^\[[ xX]\] +/,
+ anyLine: /\n.*\n/,
+ hrefBrackets: /^<(.*)>$/,
+ tableDelimiter: /[:|]/,
+ tableAlignChars: /^\||\| *$/g,
+ tableRowBlankLine: /\n[ \t]*$/,
+ tableAlignRight: /^ *-+: *$/,
+ tableAlignCenter: /^ *:-+: *$/,
+ tableAlignLeft: /^ *:-+ *$/,
+ startATag: /^/i,
+ startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
+ endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
+ startAngleBracket: /^,
+ endAngleBracket: />$/,
+ pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
+ unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
+ escapeTest: /[&<>"']/,
+ escapeReplace: /[&<>"']/g,
+ escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
+ escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
+ unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,
+ caret: /(^|[^\[])\^/g,
+ percentDecode: /%25/g,
+ findPipe: /\|/g,
+ splitPipe: / \|/,
+ slashPipe: /\\\|/g,
+ carriageReturn: /\r\n|\r/g,
+ spaceLine: /^ +$/gm,
+ notSpaceStart: /^\S*/,
+ endingNewline: /\n$/,
+ listItemRegex: (bull) => new RegExp(`^( {0,3}${bull})((?:[ ][^\\n]*)?(?:\\n|$))`),
+ nextBulletRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),
+ hrRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),
+ fencesBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}(?:\`\`\`|~~~)`),
+ headingBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}#`),
+ htmlBeginRegex: (indent) => new RegExp(`^ {0,${Math.min(3, indent - 1)}}<(?:[a-z].*>|!--)`, "i")
+};
+const newline = /^(?:[ \t]*(?:\n|$))+/;
+const blockCode = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/;
+const fences = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/;
+const hr = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/;
+const heading = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/;
+const bullet = /(?:[*+-]|\d{1,9}[.)])/;
+const lheading = edit(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, bullet).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).getRegex();
+const _paragraph = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/;
+const blockText = /^[^\n]+/;
+const _blockLabel = /(?!\s*\])(?:\\.|[^\[\]\\])+/;
+const def = edit(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", _blockLabel).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex();
+const list = edit(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, bullet).getRegex();
+const _tag = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul";
+const _comment = /|$))/;
+const html = edit("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", _comment).replace("tag", _tag).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex();
+const paragraph = edit(_paragraph).replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex();
+const blockquote = edit(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", paragraph).getRegex();
+const blockNormal = {
+ blockquote,
+ code: blockCode,
+ def,
+ fences,
+ heading,
+ hr,
+ html,
+ lheading,
+ list,
+ newline,
+ paragraph,
+ table: noopTest,
+ text: blockText
+};
+const gfmTable = edit("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex();
+const blockGfm = {
+ ...blockNormal,
+ table: gfmTable,
+ paragraph: edit(_paragraph).replace("hr", hr).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", gfmTable).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", _tag).getRegex()
+};
+const blockPedantic = {
+ ...blockNormal,
+ html: edit(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?\\1> *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", _comment).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
+ def: /^ *\[([^\]]+)\]: *([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
+ heading: /^(#{1,6})(.*)(?:\n+|$)/,
+ fences: noopTest,
+ // fences not supported
+ lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
+ paragraph: edit(_paragraph).replace("hr", hr).replace("heading", " *#{1,6} *[^\n]").replace("lheading", lheading).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
+};
+const escape$1 = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/;
+const inlineCode = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/;
+const br = /^( {2,}|\\)\n(?!\s*$)/;
+const inlineText = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\]*?>/g;
+const emStrongLDelim = edit(/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, "u").replace(/punct/g, _punctuation).getRegex();
+const emStrongRDelimAst = edit("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", "gu").replace(/notPunctSpace/g, _notPunctuationOrSpace).replace(/punctSpace/g, _punctuationOrSpace).replace(/punct/g, _punctuation).getRegex();
+const emStrongRDelimUnd = edit("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, _notPunctuationOrSpace).replace(/punctSpace/g, _punctuationOrSpace).replace(/punct/g, _punctuation).getRegex();
+const anyPunctuation = edit(/\\(punct)/, "gu").replace(/punct/g, _punctuation).getRegex();
+const autolink = edit(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex();
+const _inlineComment = edit(_comment).replace("(?:-->|$)", "-->").getRegex();
+const tag = edit("^comment|^[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment", _inlineComment).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex();
+const _inlineLabel = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/;
+const link = edit(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label", _inlineLabel).replace("href", /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex();
+const reflink = edit(/^!?\[(label)\]\[(ref)\]/).replace("label", _inlineLabel).replace("ref", _blockLabel).getRegex();
+const nolink = edit(/^!?\[(ref)\](?:\[\])?/).replace("ref", _blockLabel).getRegex();
+const reflinkSearch = edit("reflink|nolink(?!\\()", "g").replace("reflink", reflink).replace("nolink", nolink).getRegex();
+const inlineNormal = {
+ _backpedal: noopTest,
+ // only used for GFM url
+ anyPunctuation,
+ autolink,
+ blockSkip,
+ br,
+ code: inlineCode,
+ del: noopTest,
+ emStrongLDelim,
+ emStrongRDelimAst,
+ emStrongRDelimUnd,
+ escape: escape$1,
+ link,
+ nolink,
+ punctuation,
+ reflink,
+ reflinkSearch,
+ tag,
+ text: inlineText,
+ url: noopTest
+};
+const inlinePedantic = {
+ ...inlineNormal,
+ link: edit(/^!?\[(label)\]\((.*?)\)/).replace("label", _inlineLabel).getRegex(),
+ reflink: edit(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", _inlineLabel).getRegex()
+};
+const inlineGfm = {
+ ...inlineNormal,
+ escape: edit(escape$1).replace("])", "~|])").getRegex(),
+ url: edit(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
+ _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
+ del: /^(~~?)(?=[^\s~])((?:\\.|[^\\])*?(?:\\.|[^\s~\\]))\1(?=[^~]|$)/,
+ text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\": ">",
+ '"': """,
+ "'": "'"
+};
+const getEscapeReplacement = (ch) => escapeReplacements[ch];
+function escape(html2, encode2) {
+ if (encode2) {
+ if (other.escapeTest.test(html2)) {
+ return html2.replace(other.escapeReplace, getEscapeReplacement);
+ }
+ } else {
+ if (other.escapeTestNoEncode.test(html2)) {
+ return html2.replace(other.escapeReplaceNoEncode, getEscapeReplacement);
+ }
+ }
+ return html2;
+}
+function cleanUrl(href) {
+ try {
+ href = encodeURI(href).replace(other.percentDecode, "%");
+ } catch {
+ return null;
+ }
+ return href;
+}
+function splitCells(tableRow, count) {
+ const row = tableRow.replace(other.findPipe, (match, offset, str) => {
+ let escaped = false;
+ let curr = offset;
+ while (--curr >= 0 && str[curr] === "\\")
+ escaped = !escaped;
+ if (escaped) {
+ return "|";
+ } else {
+ return " |";
+ }
+ }), cells = row.split(other.splitPipe);
+ let i = 0;
+ if (!cells[0].trim()) {
+ cells.shift();
+ }
+ if (cells.length > 0 && !cells.at(-1)?.trim()) {
+ cells.pop();
+ }
+ if (count) {
+ if (cells.length > count) {
+ cells.splice(count);
+ } else {
+ while (cells.length < count)
+ cells.push("");
+ }
+ }
+ for (; i < cells.length; i++) {
+ cells[i] = cells[i].trim().replace(other.slashPipe, "|");
+ }
+ return cells;
+}
+function rtrim(str, c2, invert) {
+ const l = str.length;
+ if (l === 0) {
+ return "";
+ }
+ let suffLen = 0;
+ while (suffLen < l) {
+ const currChar = str.charAt(l - suffLen - 1);
+ if (currChar === c2 && !invert) {
+ suffLen++;
+ } else {
+ break;
+ }
+ }
+ return str.slice(0, l - suffLen);
+}
+function findClosingBracket(str, b) {
+ if (str.indexOf(b[1]) === -1) {
+ return -1;
+ }
+ let level = 0;
+ for (let i = 0; i < str.length; i++) {
+ if (str[i] === "\\") {
+ i++;
+ } else if (str[i] === b[0]) {
+ level++;
+ } else if (str[i] === b[1]) {
+ level--;
+ if (level < 0) {
+ return i;
+ }
+ }
+ }
+ return -1;
+}
+function outputLink(cap, link2, raw, lexer, rules) {
+ const href = link2.href;
+ const title = link2.title || null;
+ const text = cap[1].replace(rules.other.outputLinkReplace, "$1");
+ if (cap[0].charAt(0) !== "!") {
+ lexer.state.inLink = true;
+ const token = {
+ type: "link",
+ raw,
+ href,
+ title,
+ text,
+ tokens: lexer.inlineTokens(text)
+ };
+ lexer.state.inLink = false;
+ return token;
+ }
+ return {
+ type: "image",
+ raw,
+ href,
+ title,
+ text
+ };
+}
+function indentCodeCompensation(raw, text, rules) {
+ const matchIndentToCode = raw.match(rules.other.indentCodeCompensation);
+ if (matchIndentToCode === null) {
+ return text;
+ }
+ const indentToCode = matchIndentToCode[1];
+ return text.split("\n").map((node) => {
+ const matchIndentInNode = node.match(rules.other.beginningSpace);
+ if (matchIndentInNode === null) {
+ return node;
+ }
+ const [indentInNode] = matchIndentInNode;
+ if (indentInNode.length >= indentToCode.length) {
+ return node.slice(indentToCode.length);
+ }
+ return node;
+ }).join("\n");
+}
+class _Tokenizer {
+ options;
+ rules;
+ // set by the lexer
+ lexer;
+ // set by the lexer
+ constructor(options) {
+ this.options = options || _defaults;
+ }
+ space(src) {
+ const cap = this.rules.block.newline.exec(src);
+ if (cap && cap[0].length > 0) {
+ return {
+ type: "space",
+ raw: cap[0]
+ };
+ }
+ }
+ code(src) {
+ const cap = this.rules.block.code.exec(src);
+ if (cap) {
+ const text = cap[0].replace(this.rules.other.codeRemoveIndent, "");
+ return {
+ type: "code",
+ raw: cap[0],
+ codeBlockStyle: "indented",
+ text: !this.options.pedantic ? rtrim(text, "\n") : text
+ };
+ }
+ }
+ fences(src) {
+ const cap = this.rules.block.fences.exec(src);
+ if (cap) {
+ const raw = cap[0];
+ const text = indentCodeCompensation(raw, cap[3] || "", this.rules);
+ return {
+ type: "code",
+ raw,
+ lang: cap[2] ? cap[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : cap[2],
+ text
+ };
+ }
+ }
+ heading(src) {
+ const cap = this.rules.block.heading.exec(src);
+ if (cap) {
+ let text = cap[2].trim();
+ if (this.rules.other.endingHash.test(text)) {
+ const trimmed = rtrim(text, "#");
+ if (this.options.pedantic) {
+ text = trimmed.trim();
+ } else if (!trimmed || this.rules.other.endingSpaceChar.test(trimmed)) {
+ text = trimmed.trim();
+ }
+ }
+ return {
+ type: "heading",
+ raw: cap[0],
+ depth: cap[1].length,
+ text,
+ tokens: this.lexer.inline(text)
+ };
+ }
+ }
+ hr(src) {
+ const cap = this.rules.block.hr.exec(src);
+ if (cap) {
+ return {
+ type: "hr",
+ raw: rtrim(cap[0], "\n")
+ };
+ }
+ }
+ blockquote(src) {
+ const cap = this.rules.block.blockquote.exec(src);
+ if (cap) {
+ let lines = rtrim(cap[0], "\n").split("\n");
+ let raw = "";
+ let text = "";
+ const tokens = [];
+ while (lines.length > 0) {
+ let inBlockquote = false;
+ const currentLines = [];
+ let i;
+ for (i = 0; i < lines.length; i++) {
+ if (this.rules.other.blockquoteStart.test(lines[i])) {
+ currentLines.push(lines[i]);
+ inBlockquote = true;
+ } else if (!inBlockquote) {
+ currentLines.push(lines[i]);
+ } else {
+ break;
+ }
+ }
+ lines = lines.slice(i);
+ const currentRaw = currentLines.join("\n");
+ const currentText = currentRaw.replace(this.rules.other.blockquoteSetextReplace, "\n $1").replace(this.rules.other.blockquoteSetextReplace2, "");
+ raw = raw ? `${raw}
+${currentRaw}` : currentRaw;
+ text = text ? `${text}
+${currentText}` : currentText;
+ const top = this.lexer.state.top;
+ this.lexer.state.top = true;
+ this.lexer.blockTokens(currentText, tokens, true);
+ this.lexer.state.top = top;
+ if (lines.length === 0) {
+ break;
+ }
+ const lastToken = tokens.at(-1);
+ if (lastToken?.type === "code") {
+ break;
+ } else if (lastToken?.type === "blockquote") {
+ const oldToken = lastToken;
+ const newText = oldToken.raw + "\n" + lines.join("\n");
+ const newToken = this.blockquote(newText);
+ tokens[tokens.length - 1] = newToken;
+ raw = raw.substring(0, raw.length - oldToken.raw.length) + newToken.raw;
+ text = text.substring(0, text.length - oldToken.text.length) + newToken.text;
+ break;
+ } else if (lastToken?.type === "list") {
+ const oldToken = lastToken;
+ const newText = oldToken.raw + "\n" + lines.join("\n");
+ const newToken = this.list(newText);
+ tokens[tokens.length - 1] = newToken;
+ raw = raw.substring(0, raw.length - lastToken.raw.length) + newToken.raw;
+ text = text.substring(0, text.length - oldToken.raw.length) + newToken.raw;
+ lines = newText.substring(tokens.at(-1).raw.length).split("\n");
+ continue;
+ }
+ }
+ return {
+ type: "blockquote",
+ raw,
+ tokens,
+ text
+ };
+ }
+ }
+ list(src) {
+ let cap = this.rules.block.list.exec(src);
+ if (cap) {
+ let bull = cap[1].trim();
+ const isordered = bull.length > 1;
+ const list2 = {
+ type: "list",
+ raw: "",
+ ordered: isordered,
+ start: isordered ? +bull.slice(0, -1) : "",
+ loose: false,
+ items: []
+ };
+ bull = isordered ? `\\d{1,9}\\${bull.slice(-1)}` : `\\${bull}`;
+ if (this.options.pedantic) {
+ bull = isordered ? bull : "[*+-]";
+ }
+ const itemRegex = this.rules.other.listItemRegex(bull);
+ let endsWithBlankLine = false;
+ while (src) {
+ let endEarly = false;
+ let raw = "";
+ let itemContents = "";
+ if (!(cap = itemRegex.exec(src))) {
+ break;
+ }
+ if (this.rules.block.hr.test(src)) {
+ break;
+ }
+ raw = cap[0];
+ src = src.substring(raw.length);
+ let line = cap[2].split("\n", 1)[0].replace(this.rules.other.listReplaceTabs, (t) => " ".repeat(3 * t.length));
+ let nextLine = src.split("\n", 1)[0];
+ let blankLine = !line.trim();
+ let indent = 0;
+ if (this.options.pedantic) {
+ indent = 2;
+ itemContents = line.trimStart();
+ } else if (blankLine) {
+ indent = cap[1].length + 1;
+ } else {
+ indent = cap[2].search(this.rules.other.nonSpaceChar);
+ indent = indent > 4 ? 1 : indent;
+ itemContents = line.slice(indent);
+ indent += cap[1].length;
+ }
+ if (blankLine && this.rules.other.blankLine.test(nextLine)) {
+ raw += nextLine + "\n";
+ src = src.substring(nextLine.length + 1);
+ endEarly = true;
+ }
+ if (!endEarly) {
+ const nextBulletRegex = this.rules.other.nextBulletRegex(indent);
+ const hrRegex = this.rules.other.hrRegex(indent);
+ const fencesBeginRegex = this.rules.other.fencesBeginRegex(indent);
+ const headingBeginRegex = this.rules.other.headingBeginRegex(indent);
+ const htmlBeginRegex = this.rules.other.htmlBeginRegex(indent);
+ while (src) {
+ const rawLine = src.split("\n", 1)[0];
+ let nextLineWithoutTabs;
+ nextLine = rawLine;
+ if (this.options.pedantic) {
+ nextLine = nextLine.replace(this.rules.other.listReplaceNesting, " ");
+ nextLineWithoutTabs = nextLine;
+ } else {
+ nextLineWithoutTabs = nextLine.replace(this.rules.other.tabCharGlobal, " ");
+ }
+ if (fencesBeginRegex.test(nextLine)) {
+ break;
+ }
+ if (headingBeginRegex.test(nextLine)) {
+ break;
+ }
+ if (htmlBeginRegex.test(nextLine)) {
+ break;
+ }
+ if (nextBulletRegex.test(nextLine)) {
+ break;
+ }
+ if (hrRegex.test(nextLine)) {
+ break;
+ }
+ if (nextLineWithoutTabs.search(this.rules.other.nonSpaceChar) >= indent || !nextLine.trim()) {
+ itemContents += "\n" + nextLineWithoutTabs.slice(indent);
+ } else {
+ if (blankLine) {
+ break;
+ }
+ if (line.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4) {
+ break;
+ }
+ if (fencesBeginRegex.test(line)) {
+ break;
+ }
+ if (headingBeginRegex.test(line)) {
+ break;
+ }
+ if (hrRegex.test(line)) {
+ break;
+ }
+ itemContents += "\n" + nextLine;
+ }
+ if (!blankLine && !nextLine.trim()) {
+ blankLine = true;
+ }
+ raw += rawLine + "\n";
+ src = src.substring(rawLine.length + 1);
+ line = nextLineWithoutTabs.slice(indent);
+ }
+ }
+ if (!list2.loose) {
+ if (endsWithBlankLine) {
+ list2.loose = true;
+ } else if (this.rules.other.doubleBlankLine.test(raw)) {
+ endsWithBlankLine = true;
+ }
+ }
+ let istask = null;
+ let ischecked;
+ if (this.options.gfm) {
+ istask = this.rules.other.listIsTask.exec(itemContents);
+ if (istask) {
+ ischecked = istask[0] !== "[ ] ";
+ itemContents = itemContents.replace(this.rules.other.listReplaceTask, "");
+ }
+ }
+ list2.items.push({
+ type: "list_item",
+ raw,
+ task: !!istask,
+ checked: ischecked,
+ loose: false,
+ text: itemContents,
+ tokens: []
+ });
+ list2.raw += raw;
+ }
+ const lastItem = list2.items.at(-1);
+ if (lastItem) {
+ lastItem.raw = lastItem.raw.trimEnd();
+ lastItem.text = lastItem.text.trimEnd();
+ } else {
+ return;
+ }
+ list2.raw = list2.raw.trimEnd();
+ for (let i = 0; i < list2.items.length; i++) {
+ this.lexer.state.top = false;
+ list2.items[i].tokens = this.lexer.blockTokens(list2.items[i].text, []);
+ if (!list2.loose) {
+ const spacers = list2.items[i].tokens.filter((t) => t.type === "space");
+ const hasMultipleLineBreaks = spacers.length > 0 && spacers.some((t) => this.rules.other.anyLine.test(t.raw));
+ list2.loose = hasMultipleLineBreaks;
+ }
+ }
+ if (list2.loose) {
+ for (let i = 0; i < list2.items.length; i++) {
+ list2.items[i].loose = true;
+ }
+ }
+ return list2;
+ }
+ }
+ html(src) {
+ const cap = this.rules.block.html.exec(src);
+ if (cap) {
+ const token = {
+ type: "html",
+ block: true,
+ raw: cap[0],
+ pre: cap[1] === "pre" || cap[1] === "script" || cap[1] === "style",
+ text: cap[0]
+ };
+ return token;
+ }
+ }
+ def(src) {
+ const cap = this.rules.block.def.exec(src);
+ if (cap) {
+ const tag2 = cap[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal, " ");
+ const href = cap[2] ? cap[2].replace(this.rules.other.hrefBrackets, "$1").replace(this.rules.inline.anyPunctuation, "$1") : "";
+ const title = cap[3] ? cap[3].substring(1, cap[3].length - 1).replace(this.rules.inline.anyPunctuation, "$1") : cap[3];
+ return {
+ type: "def",
+ tag: tag2,
+ raw: cap[0],
+ href,
+ title
+ };
+ }
+ }
+ table(src) {
+ const cap = this.rules.block.table.exec(src);
+ if (!cap) {
+ return;
+ }
+ if (!this.rules.other.tableDelimiter.test(cap[2])) {
+ return;
+ }
+ const headers = splitCells(cap[1]);
+ const aligns = cap[2].replace(this.rules.other.tableAlignChars, "").split("|");
+ const rows = cap[3]?.trim() ? cap[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [];
+ const item = {
+ type: "table",
+ raw: cap[0],
+ header: [],
+ align: [],
+ rows: []
+ };
+ if (headers.length !== aligns.length) {
+ return;
+ }
+ for (const align of aligns) {
+ if (this.rules.other.tableAlignRight.test(align)) {
+ item.align.push("right");
+ } else if (this.rules.other.tableAlignCenter.test(align)) {
+ item.align.push("center");
+ } else if (this.rules.other.tableAlignLeft.test(align)) {
+ item.align.push("left");
+ } else {
+ item.align.push(null);
+ }
+ }
+ for (let i = 0; i < headers.length; i++) {
+ item.header.push({
+ text: headers[i],
+ tokens: this.lexer.inline(headers[i]),
+ header: true,
+ align: item.align[i]
+ });
+ }
+ for (const row of rows) {
+ item.rows.push(splitCells(row, item.header.length).map((cell, i) => {
+ return {
+ text: cell,
+ tokens: this.lexer.inline(cell),
+ header: false,
+ align: item.align[i]
+ };
+ }));
+ }
+ return item;
+ }
+ lheading(src) {
+ const cap = this.rules.block.lheading.exec(src);
+ if (cap) {
+ return {
+ type: "heading",
+ raw: cap[0],
+ depth: cap[2].charAt(0) === "=" ? 1 : 2,
+ text: cap[1],
+ tokens: this.lexer.inline(cap[1])
+ };
+ }
+ }
+ paragraph(src) {
+ const cap = this.rules.block.paragraph.exec(src);
+ if (cap) {
+ const text = cap[1].charAt(cap[1].length - 1) === "\n" ? cap[1].slice(0, -1) : cap[1];
+ return {
+ type: "paragraph",
+ raw: cap[0],
+ text,
+ tokens: this.lexer.inline(text)
+ };
+ }
+ }
+ text(src) {
+ const cap = this.rules.block.text.exec(src);
+ if (cap) {
+ return {
+ type: "text",
+ raw: cap[0],
+ text: cap[0],
+ tokens: this.lexer.inline(cap[0])
+ };
+ }
+ }
+ escape(src) {
+ const cap = this.rules.inline.escape.exec(src);
+ if (cap) {
+ return {
+ type: "escape",
+ raw: cap[0],
+ text: cap[1]
+ };
+ }
+ }
+ tag(src) {
+ const cap = this.rules.inline.tag.exec(src);
+ if (cap) {
+ if (!this.lexer.state.inLink && this.rules.other.startATag.test(cap[0])) {
+ this.lexer.state.inLink = true;
+ } else if (this.lexer.state.inLink && this.rules.other.endATag.test(cap[0])) {
+ this.lexer.state.inLink = false;
+ }
+ if (!this.lexer.state.inRawBlock && this.rules.other.startPreScriptTag.test(cap[0])) {
+ this.lexer.state.inRawBlock = true;
+ } else if (this.lexer.state.inRawBlock && this.rules.other.endPreScriptTag.test(cap[0])) {
+ this.lexer.state.inRawBlock = false;
+ }
+ return {
+ type: "html",
+ raw: cap[0],
+ inLink: this.lexer.state.inLink,
+ inRawBlock: this.lexer.state.inRawBlock,
+ block: false,
+ text: cap[0]
+ };
+ }
+ }
+ link(src) {
+ const cap = this.rules.inline.link.exec(src);
+ if (cap) {
+ const trimmedUrl = cap[2].trim();
+ if (!this.options.pedantic && this.rules.other.startAngleBracket.test(trimmedUrl)) {
+ if (!this.rules.other.endAngleBracket.test(trimmedUrl)) {
+ return;
+ }
+ const rtrimSlash = rtrim(trimmedUrl.slice(0, -1), "\\");
+ if ((trimmedUrl.length - rtrimSlash.length) % 2 === 0) {
+ return;
+ }
+ } else {
+ const lastParenIndex = findClosingBracket(cap[2], "()");
+ if (lastParenIndex > -1) {
+ const start = cap[0].indexOf("!") === 0 ? 5 : 4;
+ const linkLen = start + cap[1].length + lastParenIndex;
+ cap[2] = cap[2].substring(0, lastParenIndex);
+ cap[0] = cap[0].substring(0, linkLen).trim();
+ cap[3] = "";
+ }
+ }
+ let href = cap[2];
+ let title = "";
+ if (this.options.pedantic) {
+ const link2 = this.rules.other.pedanticHrefTitle.exec(href);
+ if (link2) {
+ href = link2[1];
+ title = link2[3];
+ }
+ } else {
+ title = cap[3] ? cap[3].slice(1, -1) : "";
+ }
+ href = href.trim();
+ if (this.rules.other.startAngleBracket.test(href)) {
+ if (this.options.pedantic && !this.rules.other.endAngleBracket.test(trimmedUrl)) {
+ href = href.slice(1);
+ } else {
+ href = href.slice(1, -1);
+ }
+ }
+ return outputLink(cap, {
+ href: href ? href.replace(this.rules.inline.anyPunctuation, "$1") : href,
+ title: title ? title.replace(this.rules.inline.anyPunctuation, "$1") : title
+ }, cap[0], this.lexer, this.rules);
+ }
+ }
+ reflink(src, links) {
+ let cap;
+ if ((cap = this.rules.inline.reflink.exec(src)) || (cap = this.rules.inline.nolink.exec(src))) {
+ const linkString = (cap[2] || cap[1]).replace(this.rules.other.multipleSpaceGlobal, " ");
+ const link2 = links[linkString.toLowerCase()];
+ if (!link2) {
+ const text = cap[0].charAt(0);
+ return {
+ type: "text",
+ raw: text,
+ text
+ };
+ }
+ return outputLink(cap, link2, cap[0], this.lexer, this.rules);
+ }
+ }
+ emStrong(src, maskedSrc, prevChar = "") {
+ let match = this.rules.inline.emStrongLDelim.exec(src);
+ if (!match)
+ return;
+ if (match[3] && prevChar.match(this.rules.other.unicodeAlphaNumeric))
+ return;
+ const nextChar = match[1] || match[2] || "";
+ if (!nextChar || !prevChar || this.rules.inline.punctuation.exec(prevChar)) {
+ const lLength = [...match[0]].length - 1;
+ let rDelim, rLength, delimTotal = lLength, midDelimTotal = 0;
+ const endReg = match[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
+ endReg.lastIndex = 0;
+ maskedSrc = maskedSrc.slice(-1 * src.length + lLength);
+ while ((match = endReg.exec(maskedSrc)) != null) {
+ rDelim = match[1] || match[2] || match[3] || match[4] || match[5] || match[6];
+ if (!rDelim)
+ continue;
+ rLength = [...rDelim].length;
+ if (match[3] || match[4]) {
+ delimTotal += rLength;
+ continue;
+ } else if (match[5] || match[6]) {
+ if (lLength % 3 && !((lLength + rLength) % 3)) {
+ midDelimTotal += rLength;
+ continue;
+ }
+ }
+ delimTotal -= rLength;
+ if (delimTotal > 0)
+ continue;
+ rLength = Math.min(rLength, rLength + delimTotal + midDelimTotal);
+ const lastCharLength = [...match[0]][0].length;
+ const raw = src.slice(0, lLength + match.index + lastCharLength + rLength);
+ if (Math.min(lLength, rLength) % 2) {
+ const text2 = raw.slice(1, -1);
+ return {
+ type: "em",
+ raw,
+ text: text2,
+ tokens: this.lexer.inlineTokens(text2)
+ };
+ }
+ const text = raw.slice(2, -2);
+ return {
+ type: "strong",
+ raw,
+ text,
+ tokens: this.lexer.inlineTokens(text)
+ };
+ }
+ }
+ }
+ codespan(src) {
+ const cap = this.rules.inline.code.exec(src);
+ if (cap) {
+ let text = cap[2].replace(this.rules.other.newLineCharGlobal, " ");
+ const hasNonSpaceChars = this.rules.other.nonSpaceChar.test(text);
+ const hasSpaceCharsOnBothEnds = this.rules.other.startingSpaceChar.test(text) && this.rules.other.endingSpaceChar.test(text);
+ if (hasNonSpaceChars && hasSpaceCharsOnBothEnds) {
+ text = text.substring(1, text.length - 1);
+ }
+ return {
+ type: "codespan",
+ raw: cap[0],
+ text
+ };
+ }
+ }
+ br(src) {
+ const cap = this.rules.inline.br.exec(src);
+ if (cap) {
+ return {
+ type: "br",
+ raw: cap[0]
+ };
+ }
+ }
+ del(src) {
+ const cap = this.rules.inline.del.exec(src);
+ if (cap) {
+ return {
+ type: "del",
+ raw: cap[0],
+ text: cap[2],
+ tokens: this.lexer.inlineTokens(cap[2])
+ };
+ }
+ }
+ autolink(src) {
+ const cap = this.rules.inline.autolink.exec(src);
+ if (cap) {
+ let text, href;
+ if (cap[2] === "@") {
+ text = cap[1];
+ href = "mailto:" + text;
+ } else {
+ text = cap[1];
+ href = text;
+ }
+ return {
+ type: "link",
+ raw: cap[0],
+ text,
+ href,
+ tokens: [
+ {
+ type: "text",
+ raw: text,
+ text
+ }
+ ]
+ };
+ }
+ }
+ url(src) {
+ let cap;
+ if (cap = this.rules.inline.url.exec(src)) {
+ let text, href;
+ if (cap[2] === "@") {
+ text = cap[0];
+ href = "mailto:" + text;
+ } else {
+ let prevCapZero;
+ do {
+ prevCapZero = cap[0];
+ cap[0] = this.rules.inline._backpedal.exec(cap[0])?.[0] ?? "";
+ } while (prevCapZero !== cap[0]);
+ text = cap[0];
+ if (cap[1] === "www.") {
+ href = "http://" + cap[0];
+ } else {
+ href = cap[0];
+ }
+ }
+ return {
+ type: "link",
+ raw: cap[0],
+ text,
+ href,
+ tokens: [
+ {
+ type: "text",
+ raw: text,
+ text
+ }
+ ]
+ };
+ }
+ }
+ inlineText(src) {
+ const cap = this.rules.inline.text.exec(src);
+ if (cap) {
+ const escaped = this.lexer.state.inRawBlock;
+ return {
+ type: "text",
+ raw: cap[0],
+ text: cap[0],
+ escaped
+ };
+ }
+ }
+}
+class _Lexer {
+ tokens;
+ options;
+ state;
+ tokenizer;
+ inlineQueue;
+ constructor(options) {
+ this.tokens = [];
+ this.tokens.links = /* @__PURE__ */ Object.create(null);
+ this.options = options || _defaults;
+ this.options.tokenizer = this.options.tokenizer || new _Tokenizer();
+ this.tokenizer = this.options.tokenizer;
+ this.tokenizer.options = this.options;
+ this.tokenizer.lexer = this;
+ this.inlineQueue = [];
+ this.state = {
+ inLink: false,
+ inRawBlock: false,
+ top: true
+ };
+ const rules = {
+ other,
+ block: block.normal,
+ inline: inline.normal
+ };
+ if (this.options.pedantic) {
+ rules.block = block.pedantic;
+ rules.inline = inline.pedantic;
+ } else if (this.options.gfm) {
+ rules.block = block.gfm;
+ if (this.options.breaks) {
+ rules.inline = inline.breaks;
+ } else {
+ rules.inline = inline.gfm;
+ }
+ }
+ this.tokenizer.rules = rules;
+ }
+ /**
+ * Expose Rules
+ */
+ static get rules() {
+ return {
+ block,
+ inline
+ };
+ }
+ /**
+ * Static Lex Method
+ */
+ static lex(src, options) {
+ const lexer = new _Lexer(options);
+ return lexer.lex(src);
+ }
+ /**
+ * Static Lex Inline Method
+ */
+ static lexInline(src, options) {
+ const lexer = new _Lexer(options);
+ return lexer.inlineTokens(src);
+ }
+ /**
+ * Preprocessing
+ */
+ lex(src) {
+ src = src.replace(other.carriageReturn, "\n");
+ this.blockTokens(src, this.tokens);
+ for (let i = 0; i < this.inlineQueue.length; i++) {
+ const next = this.inlineQueue[i];
+ this.inlineTokens(next.src, next.tokens);
+ }
+ this.inlineQueue = [];
+ return this.tokens;
+ }
+ blockTokens(src, tokens = [], lastParagraphClipped = false) {
+ if (this.options.pedantic) {
+ src = src.replace(other.tabCharGlobal, " ").replace(other.spaceLine, "");
+ }
+ while (src) {
+ let token;
+ if (this.options.extensions?.block?.some((extTokenizer) => {
+ if (token = extTokenizer.call({ lexer: this }, src, tokens)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ return true;
+ }
+ return false;
+ })) {
+ continue;
+ }
+ if (token = this.tokenizer.space(src)) {
+ src = src.substring(token.raw.length);
+ const lastToken = tokens.at(-1);
+ if (token.raw.length === 1 && lastToken !== void 0) {
+ lastToken.raw += "\n";
+ } else {
+ tokens.push(token);
+ }
+ continue;
+ }
+ if (token = this.tokenizer.code(src)) {
+ src = src.substring(token.raw.length);
+ const lastToken = tokens.at(-1);
+ if (lastToken?.type === "paragraph" || lastToken?.type === "text") {
+ lastToken.raw += "\n" + token.raw;
+ lastToken.text += "\n" + token.text;
+ this.inlineQueue.at(-1).src = lastToken.text;
+ } else {
+ tokens.push(token);
+ }
+ continue;
+ }
+ if (token = this.tokenizer.fences(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.heading(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.hr(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.blockquote(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.list(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.html(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.def(src)) {
+ src = src.substring(token.raw.length);
+ const lastToken = tokens.at(-1);
+ if (lastToken?.type === "paragraph" || lastToken?.type === "text") {
+ lastToken.raw += "\n" + token.raw;
+ lastToken.text += "\n" + token.raw;
+ this.inlineQueue.at(-1).src = lastToken.text;
+ } else if (!this.tokens.links[token.tag]) {
+ this.tokens.links[token.tag] = {
+ href: token.href,
+ title: token.title
+ };
+ }
+ continue;
+ }
+ if (token = this.tokenizer.table(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.lheading(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ let cutSrc = src;
+ if (this.options.extensions?.startBlock) {
+ let startIndex = Infinity;
+ const tempSrc = src.slice(1);
+ let tempStart;
+ this.options.extensions.startBlock.forEach((getStartIndex) => {
+ tempStart = getStartIndex.call({ lexer: this }, tempSrc);
+ if (typeof tempStart === "number" && tempStart >= 0) {
+ startIndex = Math.min(startIndex, tempStart);
+ }
+ });
+ if (startIndex < Infinity && startIndex >= 0) {
+ cutSrc = src.substring(0, startIndex + 1);
+ }
+ }
+ if (this.state.top && (token = this.tokenizer.paragraph(cutSrc))) {
+ const lastToken = tokens.at(-1);
+ if (lastParagraphClipped && lastToken?.type === "paragraph") {
+ lastToken.raw += "\n" + token.raw;
+ lastToken.text += "\n" + token.text;
+ this.inlineQueue.pop();
+ this.inlineQueue.at(-1).src = lastToken.text;
+ } else {
+ tokens.push(token);
+ }
+ lastParagraphClipped = cutSrc.length !== src.length;
+ src = src.substring(token.raw.length);
+ continue;
+ }
+ if (token = this.tokenizer.text(src)) {
+ src = src.substring(token.raw.length);
+ const lastToken = tokens.at(-1);
+ if (lastToken?.type === "text") {
+ lastToken.raw += "\n" + token.raw;
+ lastToken.text += "\n" + token.text;
+ this.inlineQueue.pop();
+ this.inlineQueue.at(-1).src = lastToken.text;
+ } else {
+ tokens.push(token);
+ }
+ continue;
+ }
+ if (src) {
+ const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
+ if (this.options.silent) {
+ console.error(errMsg);
+ break;
+ } else {
+ throw new Error(errMsg);
+ }
+ }
+ }
+ this.state.top = true;
+ return tokens;
+ }
+ inline(src, tokens = []) {
+ this.inlineQueue.push({ src, tokens });
+ return tokens;
+ }
+ /**
+ * Lexing/Compiling
+ */
+ inlineTokens(src, tokens = []) {
+ let maskedSrc = src;
+ let match = null;
+ if (this.tokens.links) {
+ const links = Object.keys(this.tokens.links);
+ if (links.length > 0) {
+ while ((match = this.tokenizer.rules.inline.reflinkSearch.exec(maskedSrc)) != null) {
+ if (links.includes(match[0].slice(match[0].lastIndexOf("[") + 1, -1))) {
+ maskedSrc = maskedSrc.slice(0, match.index) + "[" + "a".repeat(match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex);
+ }
+ }
+ }
+ }
+ while ((match = this.tokenizer.rules.inline.blockSkip.exec(maskedSrc)) != null) {
+ maskedSrc = maskedSrc.slice(0, match.index) + "[" + "a".repeat(match[0].length - 2) + "]" + maskedSrc.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
+ }
+ while ((match = this.tokenizer.rules.inline.anyPunctuation.exec(maskedSrc)) != null) {
+ maskedSrc = maskedSrc.slice(0, match.index) + "++" + maskedSrc.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
+ }
+ let keepPrevChar = false;
+ let prevChar = "";
+ while (src) {
+ if (!keepPrevChar) {
+ prevChar = "";
+ }
+ keepPrevChar = false;
+ let token;
+ if (this.options.extensions?.inline?.some((extTokenizer) => {
+ if (token = extTokenizer.call({ lexer: this }, src, tokens)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ return true;
+ }
+ return false;
+ })) {
+ continue;
+ }
+ if (token = this.tokenizer.escape(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.tag(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.link(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.reflink(src, this.tokens.links)) {
+ src = src.substring(token.raw.length);
+ const lastToken = tokens.at(-1);
+ if (token.type === "text" && lastToken?.type === "text") {
+ lastToken.raw += token.raw;
+ lastToken.text += token.text;
+ } else {
+ tokens.push(token);
+ }
+ continue;
+ }
+ if (token = this.tokenizer.emStrong(src, maskedSrc, prevChar)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.codespan(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.br(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.del(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (token = this.tokenizer.autolink(src)) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ if (!this.state.inLink && (token = this.tokenizer.url(src))) {
+ src = src.substring(token.raw.length);
+ tokens.push(token);
+ continue;
+ }
+ let cutSrc = src;
+ if (this.options.extensions?.startInline) {
+ let startIndex = Infinity;
+ const tempSrc = src.slice(1);
+ let tempStart;
+ this.options.extensions.startInline.forEach((getStartIndex) => {
+ tempStart = getStartIndex.call({ lexer: this }, tempSrc);
+ if (typeof tempStart === "number" && tempStart >= 0) {
+ startIndex = Math.min(startIndex, tempStart);
+ }
+ });
+ if (startIndex < Infinity && startIndex >= 0) {
+ cutSrc = src.substring(0, startIndex + 1);
+ }
+ }
+ if (token = this.tokenizer.inlineText(cutSrc)) {
+ src = src.substring(token.raw.length);
+ if (token.raw.slice(-1) !== "_") {
+ prevChar = token.raw.slice(-1);
+ }
+ keepPrevChar = true;
+ const lastToken = tokens.at(-1);
+ if (lastToken?.type === "text") {
+ lastToken.raw += token.raw;
+ lastToken.text += token.text;
+ } else {
+ tokens.push(token);
+ }
+ continue;
+ }
+ if (src) {
+ const errMsg = "Infinite loop on byte: " + src.charCodeAt(0);
+ if (this.options.silent) {
+ console.error(errMsg);
+ break;
+ } else {
+ throw new Error(errMsg);
+ }
+ }
+ }
+ return tokens;
+ }
+}
+class _Renderer {
+ options;
+ parser;
+ // set by the parser
+ constructor(options) {
+ this.options = options || _defaults;
+ }
+ space(token) {
+ return "";
+ }
+ code({ text, lang, escaped }) {
+ const langString = (lang || "").match(other.notSpaceStart)?.[0];
+ const code = text.replace(other.endingNewline, "") + "\n";
+ if (!langString) {
+ return "" + (escaped ? code : escape(code, true)) + "
\n";
+ }
+ return '' + (escaped ? code : escape(code, true)) + "
\n";
+ }
+ blockquote({ tokens }) {
+ const body = this.parser.parse(tokens);
+ return `
+${body}
+`;
+ }
+ html({ text }) {
+ return text;
+ }
+ heading({ tokens, depth }) {
+ return `${this.parser.parseInline(tokens)}
+`;
+ }
+ hr(token) {
+ return "
\n";
+ }
+ list(token) {
+ const ordered = token.ordered;
+ const start = token.start;
+ let body = "";
+ for (let j = 0; j < token.items.length; j++) {
+ const item = token.items[j];
+ body += this.listitem(item);
+ }
+ const type = ordered ? "ol" : "ul";
+ const startAttr = ordered && start !== 1 ? ' start="' + start + '"' : "";
+ return "<" + type + startAttr + ">\n" + body + "" + type + ">\n";
+ }
+ listitem(item) {
+ let itemBody = "";
+ if (item.task) {
+ const checkbox = this.checkbox({ checked: !!item.checked });
+ if (item.loose) {
+ if (item.tokens[0]?.type === "paragraph") {
+ item.tokens[0].text = checkbox + " " + item.tokens[0].text;
+ if (item.tokens[0].tokens && item.tokens[0].tokens.length > 0 && item.tokens[0].tokens[0].type === "text") {
+ item.tokens[0].tokens[0].text = checkbox + " " + escape(item.tokens[0].tokens[0].text);
+ item.tokens[0].tokens[0].escaped = true;
+ }
+ } else {
+ item.tokens.unshift({
+ type: "text",
+ raw: checkbox + " ",
+ text: checkbox + " ",
+ escaped: true
+ });
+ }
+ } else {
+ itemBody += checkbox + " ";
+ }
+ }
+ itemBody += this.parser.parse(item.tokens, !!item.loose);
+ return `${itemBody}
+`;
+ }
+ checkbox({ checked }) {
+ return "';
+ }
+ paragraph({ tokens }) {
+ return `${this.parser.parseInline(tokens)}
+`;
+ }
+ table(token) {
+ let header = "";
+ let cell = "";
+ for (let j = 0; j < token.header.length; j++) {
+ cell += this.tablecell(token.header[j]);
+ }
+ header += this.tablerow({ text: cell });
+ let body = "";
+ for (let j = 0; j < token.rows.length; j++) {
+ const row = token.rows[j];
+ cell = "";
+ for (let k = 0; k < row.length; k++) {
+ cell += this.tablecell(row[k]);
+ }
+ body += this.tablerow({ text: cell });
+ }
+ if (body)
+ body = `${body}`;
+ return "\n\n" + header + "\n" + body + "
\n";
+ }
+ tablerow({ text }) {
+ return `
+${text}
+`;
+ }
+ tablecell(token) {
+ const content = this.parser.parseInline(token.tokens);
+ const type = token.header ? "th" : "td";
+ const tag2 = token.align ? `<${type} align="${token.align}">` : `<${type}>`;
+ return tag2 + content + `${type}>
+`;
+ }
+ /**
+ * span level renderer
+ */
+ strong({ tokens }) {
+ return `${this.parser.parseInline(tokens)}`;
+ }
+ em({ tokens }) {
+ return `${this.parser.parseInline(tokens)}`;
+ }
+ codespan({ text }) {
+ return `${escape(text, true)}`;
+ }
+ br(token) {
+ return "
";
+ }
+ del({ tokens }) {
+ return `${this.parser.parseInline(tokens)}`;
+ }
+ link({ href, title, tokens }) {
+ const text = this.parser.parseInline(tokens);
+ const cleanHref = cleanUrl(href);
+ if (cleanHref === null) {
+ return text;
+ }
+ href = cleanHref;
+ let out = '" + text + "";
+ return out;
+ }
+ image({ href, title, text }) {
+ const cleanHref = cleanUrl(href);
+ if (cleanHref === null) {
+ return escape(text);
+ }
+ href = cleanHref;
+ let out = `
";
+ return out;
+ }
+ text(token) {
+ return "tokens" in token && token.tokens ? this.parser.parseInline(token.tokens) : "escaped" in token && token.escaped ? token.text : escape(token.text);
+ }
+}
+class _TextRenderer {
+ // no need for block level renderers
+ strong({ text }) {
+ return text;
+ }
+ em({ text }) {
+ return text;
+ }
+ codespan({ text }) {
+ return text;
+ }
+ del({ text }) {
+ return text;
+ }
+ html({ text }) {
+ return text;
+ }
+ text({ text }) {
+ return text;
+ }
+ link({ text }) {
+ return "" + text;
+ }
+ image({ text }) {
+ return "" + text;
+ }
+ br() {
+ return "";
+ }
+}
+class _Parser {
+ options;
+ renderer;
+ textRenderer;
+ constructor(options) {
+ this.options = options || _defaults;
+ this.options.renderer = this.options.renderer || new _Renderer();
+ this.renderer = this.options.renderer;
+ this.renderer.options = this.options;
+ this.renderer.parser = this;
+ this.textRenderer = new _TextRenderer();
+ }
+ /**
+ * Static Parse Method
+ */
+ static parse(tokens, options) {
+ const parser = new _Parser(options);
+ return parser.parse(tokens);
+ }
+ /**
+ * Static Parse Inline Method
+ */
+ static parseInline(tokens, options) {
+ const parser = new _Parser(options);
+ return parser.parseInline(tokens);
+ }
+ /**
+ * Parse Loop
+ */
+ parse(tokens, top = true) {
+ let out = "";
+ for (let i = 0; i < tokens.length; i++) {
+ const anyToken = tokens[i];
+ if (this.options.extensions?.renderers?.[anyToken.type]) {
+ const genericToken = anyToken;
+ const ret = this.options.extensions.renderers[genericToken.type].call({ parser: this }, genericToken);
+ if (ret !== false || !["space", "hr", "heading", "code", "table", "blockquote", "list", "html", "paragraph", "text"].includes(genericToken.type)) {
+ out += ret || "";
+ continue;
+ }
+ }
+ const token = anyToken;
+ switch (token.type) {
+ case "space": {
+ out += this.renderer.space(token);
+ continue;
+ }
+ case "hr": {
+ out += this.renderer.hr(token);
+ continue;
+ }
+ case "heading": {
+ out += this.renderer.heading(token);
+ continue;
+ }
+ case "code": {
+ out += this.renderer.code(token);
+ continue;
+ }
+ case "table": {
+ out += this.renderer.table(token);
+ continue;
+ }
+ case "blockquote": {
+ out += this.renderer.blockquote(token);
+ continue;
+ }
+ case "list": {
+ out += this.renderer.list(token);
+ continue;
+ }
+ case "html": {
+ out += this.renderer.html(token);
+ continue;
+ }
+ case "paragraph": {
+ out += this.renderer.paragraph(token);
+ continue;
+ }
+ case "text": {
+ let textToken = token;
+ let body = this.renderer.text(textToken);
+ while (i + 1 < tokens.length && tokens[i + 1].type === "text") {
+ textToken = tokens[++i];
+ body += "\n" + this.renderer.text(textToken);
+ }
+ if (top) {
+ out += this.renderer.paragraph({
+ type: "paragraph",
+ raw: body,
+ text: body,
+ tokens: [{ type: "text", raw: body, text: body, escaped: true }]
+ });
+ } else {
+ out += body;
+ }
+ continue;
+ }
+ default: {
+ const errMsg = 'Token with "' + token.type + '" type was not found.';
+ if (this.options.silent) {
+ console.error(errMsg);
+ return "";
+ } else {
+ throw new Error(errMsg);
+ }
+ }
+ }
+ }
+ return out;
+ }
+ /**
+ * Parse Inline Tokens
+ */
+ parseInline(tokens, renderer2 = this.renderer) {
+ let out = "";
+ for (let i = 0; i < tokens.length; i++) {
+ const anyToken = tokens[i];
+ if (this.options.extensions?.renderers?.[anyToken.type]) {
+ const ret = this.options.extensions.renderers[anyToken.type].call({ parser: this }, anyToken);
+ if (ret !== false || !["escape", "html", "link", "image", "strong", "em", "codespan", "br", "del", "text"].includes(anyToken.type)) {
+ out += ret || "";
+ continue;
+ }
+ }
+ const token = anyToken;
+ switch (token.type) {
+ case "escape": {
+ out += renderer2.text(token);
+ break;
+ }
+ case "html": {
+ out += renderer2.html(token);
+ break;
+ }
+ case "link": {
+ out += renderer2.link(token);
+ break;
+ }
+ case "image": {
+ out += renderer2.image(token);
+ break;
+ }
+ case "strong": {
+ out += renderer2.strong(token);
+ break;
+ }
+ case "em": {
+ out += renderer2.em(token);
+ break;
+ }
+ case "codespan": {
+ out += renderer2.codespan(token);
+ break;
+ }
+ case "br": {
+ out += renderer2.br(token);
+ break;
+ }
+ case "del": {
+ out += renderer2.del(token);
+ break;
+ }
+ case "text": {
+ out += renderer2.text(token);
+ break;
+ }
+ default: {
+ const errMsg = 'Token with "' + token.type + '" type was not found.';
+ if (this.options.silent) {
+ console.error(errMsg);
+ return "";
+ } else {
+ throw new Error(errMsg);
+ }
+ }
+ }
+ }
+ return out;
+ }
+}
+class _Hooks {
+ options;
+ block;
+ constructor(options) {
+ this.options = options || _defaults;
+ }
+ static passThroughHooks = /* @__PURE__ */ new Set([
+ "preprocess",
+ "postprocess",
+ "processAllTokens"
+ ]);
+ /**
+ * Process markdown before marked
+ */
+ preprocess(markdown) {
+ return markdown;
+ }
+ /**
+ * Process HTML after marked is finished
+ */
+ postprocess(html2) {
+ return html2;
+ }
+ /**
+ * Process all tokens before walk tokens
+ */
+ processAllTokens(tokens) {
+ return tokens;
+ }
+ /**
+ * Provide function to tokenize markdown
+ */
+ provideLexer() {
+ return this.block ? _Lexer.lex : _Lexer.lexInline;
+ }
+ /**
+ * Provide function to parse tokens
+ */
+ provideParser() {
+ return this.block ? _Parser.parse : _Parser.parseInline;
+ }
+}
+class Marked {
+ defaults = _getDefaults();
+ options = this.setOptions;
+ parse = this.parseMarkdown(true);
+ parseInline = this.parseMarkdown(false);
+ Parser = _Parser;
+ Renderer = _Renderer;
+ TextRenderer = _TextRenderer;
+ Lexer = _Lexer;
+ Tokenizer = _Tokenizer;
+ Hooks = _Hooks;
+ constructor(...args) {
+ this.use(...args);
+ }
+ /**
+ * Run callback for every token
+ */
+ walkTokens(tokens, callback) {
+ let values = [];
+ for (const token of tokens) {
+ values = values.concat(callback.call(this, token));
+ switch (token.type) {
+ case "table": {
+ const tableToken = token;
+ for (const cell of tableToken.header) {
+ values = values.concat(this.walkTokens(cell.tokens, callback));
+ }
+ for (const row of tableToken.rows) {
+ for (const cell of row) {
+ values = values.concat(this.walkTokens(cell.tokens, callback));
+ }
+ }
+ break;
+ }
+ case "list": {
+ const listToken = token;
+ values = values.concat(this.walkTokens(listToken.items, callback));
+ break;
+ }
+ default: {
+ const genericToken = token;
+ if (this.defaults.extensions?.childTokens?.[genericToken.type]) {
+ this.defaults.extensions.childTokens[genericToken.type].forEach((childTokens) => {
+ const tokens2 = genericToken[childTokens].flat(Infinity);
+ values = values.concat(this.walkTokens(tokens2, callback));
+ });
+ } else if (genericToken.tokens) {
+ values = values.concat(this.walkTokens(genericToken.tokens, callback));
+ }
+ }
+ }
+ }
+ return values;
+ }
+ use(...args) {
+ const extensions = this.defaults.extensions || { renderers: {}, childTokens: {} };
+ args.forEach((pack) => {
+ const opts = { ...pack };
+ opts.async = this.defaults.async || opts.async || false;
+ if (pack.extensions) {
+ pack.extensions.forEach((ext) => {
+ if (!ext.name) {
+ throw new Error("extension name required");
+ }
+ if ("renderer" in ext) {
+ const prevRenderer = extensions.renderers[ext.name];
+ if (prevRenderer) {
+ extensions.renderers[ext.name] = function(...args2) {
+ let ret = ext.renderer.apply(this, args2);
+ if (ret === false) {
+ ret = prevRenderer.apply(this, args2);
+ }
+ return ret;
+ };
+ } else {
+ extensions.renderers[ext.name] = ext.renderer;
+ }
+ }
+ if ("tokenizer" in ext) {
+ if (!ext.level || ext.level !== "block" && ext.level !== "inline") {
+ throw new Error("extension level must be 'block' or 'inline'");
+ }
+ const extLevel = extensions[ext.level];
+ if (extLevel) {
+ extLevel.unshift(ext.tokenizer);
+ } else {
+ extensions[ext.level] = [ext.tokenizer];
+ }
+ if (ext.start) {
+ if (ext.level === "block") {
+ if (extensions.startBlock) {
+ extensions.startBlock.push(ext.start);
+ } else {
+ extensions.startBlock = [ext.start];
+ }
+ } else if (ext.level === "inline") {
+ if (extensions.startInline) {
+ extensions.startInline.push(ext.start);
+ } else {
+ extensions.startInline = [ext.start];
+ }
+ }
+ }
+ }
+ if ("childTokens" in ext && ext.childTokens) {
+ extensions.childTokens[ext.name] = ext.childTokens;
+ }
+ });
+ opts.extensions = extensions;
+ }
+ if (pack.renderer) {
+ const renderer2 = this.defaults.renderer || new _Renderer(this.defaults);
+ for (const prop in pack.renderer) {
+ if (!(prop in renderer2)) {
+ throw new Error(`renderer '${prop}' does not exist`);
+ }
+ if (["options", "parser"].includes(prop)) {
+ continue;
+ }
+ const rendererProp = prop;
+ const rendererFunc = pack.renderer[rendererProp];
+ const prevRenderer = renderer2[rendererProp];
+ renderer2[rendererProp] = (...args2) => {
+ let ret = rendererFunc.apply(renderer2, args2);
+ if (ret === false) {
+ ret = prevRenderer.apply(renderer2, args2);
+ }
+ return ret || "";
+ };
+ }
+ opts.renderer = renderer2;
+ }
+ if (pack.tokenizer) {
+ const tokenizer = this.defaults.tokenizer || new _Tokenizer(this.defaults);
+ for (const prop in pack.tokenizer) {
+ if (!(prop in tokenizer)) {
+ throw new Error(`tokenizer '${prop}' does not exist`);
+ }
+ if (["options", "rules", "lexer"].includes(prop)) {
+ continue;
+ }
+ const tokenizerProp = prop;
+ const tokenizerFunc = pack.tokenizer[tokenizerProp];
+ const prevTokenizer = tokenizer[tokenizerProp];
+ tokenizer[tokenizerProp] = (...args2) => {
+ let ret = tokenizerFunc.apply(tokenizer, args2);
+ if (ret === false) {
+ ret = prevTokenizer.apply(tokenizer, args2);
+ }
+ return ret;
+ };
+ }
+ opts.tokenizer = tokenizer;
+ }
+ if (pack.hooks) {
+ const hooks = this.defaults.hooks || new _Hooks();
+ for (const prop in pack.hooks) {
+ if (!(prop in hooks)) {
+ throw new Error(`hook '${prop}' does not exist`);
+ }
+ if (["options", "block"].includes(prop)) {
+ continue;
+ }
+ const hooksProp = prop;
+ const hooksFunc = pack.hooks[hooksProp];
+ const prevHook = hooks[hooksProp];
+ if (_Hooks.passThroughHooks.has(prop)) {
+ hooks[hooksProp] = (arg) => {
+ if (this.defaults.async) {
+ return Promise.resolve(hooksFunc.call(hooks, arg)).then((ret2) => {
+ return prevHook.call(hooks, ret2);
+ });
+ }
+ const ret = hooksFunc.call(hooks, arg);
+ return prevHook.call(hooks, ret);
+ };
+ } else {
+ hooks[hooksProp] = (...args2) => {
+ let ret = hooksFunc.apply(hooks, args2);
+ if (ret === false) {
+ ret = prevHook.apply(hooks, args2);
+ }
+ return ret;
+ };
+ }
+ }
+ opts.hooks = hooks;
+ }
+ if (pack.walkTokens) {
+ const walkTokens = this.defaults.walkTokens;
+ const packWalktokens = pack.walkTokens;
+ opts.walkTokens = function(token) {
+ let values = [];
+ values.push(packWalktokens.call(this, token));
+ if (walkTokens) {
+ values = values.concat(walkTokens.call(this, token));
+ }
+ return values;
+ };
+ }
+ this.defaults = { ...this.defaults, ...opts };
+ });
+ return this;
+ }
+ setOptions(opt) {
+ this.defaults = { ...this.defaults, ...opt };
+ return this;
+ }
+ lexer(src, options) {
+ return _Lexer.lex(src, options ?? this.defaults);
+ }
+ parser(tokens, options) {
+ return _Parser.parse(tokens, options ?? this.defaults);
+ }
+ parseMarkdown(blockType) {
+ const parse = (src, options) => {
+ const origOpt = { ...options };
+ const opt = { ...this.defaults, ...origOpt };
+ const throwError2 = this.onError(!!opt.silent, !!opt.async);
+ if (this.defaults.async === true && origOpt.async === false) {
+ return throwError2(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
+ }
+ if (typeof src === "undefined" || src === null) {
+ return throwError2(new Error("marked(): input parameter is undefined or null"));
+ }
+ if (typeof src !== "string") {
+ return throwError2(new Error("marked(): input parameter is of type " + Object.prototype.toString.call(src) + ", string expected"));
+ }
+ if (opt.hooks) {
+ opt.hooks.options = opt;
+ opt.hooks.block = blockType;
+ }
+ const lexer = opt.hooks ? opt.hooks.provideLexer() : blockType ? _Lexer.lex : _Lexer.lexInline;
+ const parser = opt.hooks ? opt.hooks.provideParser() : blockType ? _Parser.parse : _Parser.parseInline;
+ if (opt.async) {
+ return Promise.resolve(opt.hooks ? opt.hooks.preprocess(src) : src).then((src2) => lexer(src2, opt)).then((tokens) => opt.hooks ? opt.hooks.processAllTokens(tokens) : tokens).then((tokens) => opt.walkTokens ? Promise.all(this.walkTokens(tokens, opt.walkTokens)).then(() => tokens) : tokens).then((tokens) => parser(tokens, opt)).then((html2) => opt.hooks ? opt.hooks.postprocess(html2) : html2).catch(throwError2);
+ }
+ try {
+ if (opt.hooks) {
+ src = opt.hooks.preprocess(src);
+ }
+ let tokens = lexer(src, opt);
+ if (opt.hooks) {
+ tokens = opt.hooks.processAllTokens(tokens);
+ }
+ if (opt.walkTokens) {
+ this.walkTokens(tokens, opt.walkTokens);
+ }
+ let html2 = parser(tokens, opt);
+ if (opt.hooks) {
+ html2 = opt.hooks.postprocess(html2);
+ }
+ return html2;
+ } catch (e) {
+ return throwError2(e);
+ }
+ };
+ return parse;
+ }
+ onError(silent, async) {
+ return (e) => {
+ e.message += "\nPlease report this to https://github.com/markedjs/marked.";
+ if (silent) {
+ const msg2 = "An error occurred:
" + escape(e.message + "", true) + "
";
+ if (async) {
+ return Promise.resolve(msg2);
+ }
+ return msg2;
+ }
+ if (async) {
+ return Promise.reject(e);
+ }
+ throw e;
+ };
+ }
+}
+const markedInstance = new Marked();
+function marked(src, opt) {
+ return markedInstance.parse(src, opt);
+}
+marked.options = marked.setOptions = function(options) {
+ markedInstance.setOptions(options);
+ marked.defaults = markedInstance.defaults;
+ changeDefaults(marked.defaults);
+ return marked;
+};
+marked.getDefaults = _getDefaults;
+marked.defaults = _defaults;
+marked.use = function(...args) {
+ markedInstance.use(...args);
+ marked.defaults = markedInstance.defaults;
+ changeDefaults(marked.defaults);
+ return marked;
+};
+marked.walkTokens = function(tokens, callback) {
+ return markedInstance.walkTokens(tokens, callback);
+};
+marked.parseInline = markedInstance.parseInline;
+marked.Parser = _Parser;
+marked.parser = _Parser.parse;
+marked.Renderer = _Renderer;
+marked.TextRenderer = _TextRenderer;
+marked.Lexer = _Lexer;
+marked.lexer = _Lexer.lex;
+marked.Tokenizer = _Tokenizer;
+marked.Hooks = _Hooks;
+marked.parse = marked;
+marked.options;
+marked.setOptions;
+marked.use;
+marked.walkTokens;
+marked.parseInline;
+_Parser.parse;
+_Lexer.lex;
+const _hoisted_1$2 = { class: "modal-content" };
+const _hoisted_2$2 = { class: "modal-header" };
+const _hoisted_3$1 = { class: "app-info" };
+const _hoisted_4$1 = { class: "app-name" };
+const _hoisted_5 = { class: "app-desc mb-2" };
+const _hoisted_6 = { class: "update-info" };
+const _hoisted_7 = ["innerHTML"];
+const _hoisted_8 = { class: "modal-actions" };
+const _sfc_main$3 = /* @__PURE__ */ defineComponent({
+ __name: "UpdateModal",
+ setup(__props) {
+ marked.setOptions({
+ breaks: true,
+ // 支持 GitHub 风格的换行
+ gfm: true
+ // 启用 GitHub 风格的 Markdown
+ });
+ const showModal = ref(false);
+ const noPrompt = ref(false);
+ const updateInfo = ref({
+ hasUpdate: false,
+ latestVersion: "",
+ currentVersion: config.version,
+ releaseInfo: null
+ });
+ const parsedReleaseNotes = computed(() => {
+ if (!updateInfo.value.releaseInfo?.body) return "";
+ try {
+ return marked.parse(updateInfo.value.releaseInfo.body);
+ } catch (error) {
+ console.error("Error parsing markdown:", error);
+ return updateInfo.value.releaseInfo.body;
+ }
+ });
+ const closeModal = () => {
+ showModal.value = false;
+ if (noPrompt.value) {
+ localStorage.setItem("updatePromptDismissed", "true");
+ }
+ };
+ const checkForUpdates = async () => {
+ try {
+ const result = await checkUpdate();
+ updateInfo.value = result;
+ if (result.hasUpdate && localStorage.getItem("updatePromptDismissed") !== "true") {
+ showModal.value = true;
+ }
+ } catch (error) {
+ console.error("检查更新失败:", error);
+ }
+ };
+ const handleUpdate = async () => {
+ const { userAgent } = navigator;
+ const isMac = userAgent.includes("Mac");
+ const isWindows = userAgent.includes("Win");
+ const isARM = userAgent.includes("ARM") || userAgent.includes("arm") || userAgent.includes("OS X");
+ const isX64 = userAgent.includes("x86_64") || userAgent.includes("Win64") || userAgent.includes("WOW64");
+ const isX86 = !isX64 && (userAgent.includes("i686") || userAgent.includes("i386") || userAgent.includes("Win32"));
+ const getDownloadUrl = (os, arch) => {
+ const version2 = updateInfo.value.latestVersion;
+ const setup = os !== "mac" ? "Setup_" : "";
+ return `https://gh.llkk.cc/https://github.com/algerkong/AlgerMusicPlayer/releases/download/v${version2}/AlgerMusic_${version2}_${setup}${arch}.${os === "mac" ? "dmg" : "exe"}`;
+ };
+ const osType = isMac ? "mac" : isWindows ? "windows" : null;
+ const archType = isARM ? "arm64" : isX64 ? "x64" : isX86 ? "x86" : null;
+ const downloadUrl = osType && archType ? getDownloadUrl(osType, archType) : null;
+ window.open(downloadUrl || "https://github.com/algerkong/AlgerMusicPlayer/releases/latest", "_blank");
+ closeModal();
+ };
+ onMounted(() => {
+ checkForUpdates();
+ });
+ return (_ctx, _cache) => {
+ const _component_n_checkbox = __unplugin_components_0$2;
+ const _component_n_scrollbar = Scrollbar;
+ const _component_n_button = Button;
+ const _component_n_modal = __unplugin_components_3;
+ return openBlock(), createBlock(_component_n_modal, {
+ show: showModal.value,
+ "onUpdate:show": _cache[1] || (_cache[1] = ($event) => showModal.value = $event),
+ preset: "dialog",
+ "show-icon": false,
+ "mask-closable": true,
+ class: "update-app-modal",
+ style: { "width": "800px", "max-width": "90vw" }
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1$2, [
+ createBaseVNode("div", _hoisted_2$2, [
+ _cache[3] || (_cache[3] = createBaseVNode("div", { class: "app-icon" }, [
+ createBaseVNode("img", {
+ src: _imports_0,
+ alt: "App Icon"
+ })
+ ], -1)),
+ createBaseVNode("div", _hoisted_3$1, [
+ createBaseVNode("h2", _hoisted_4$1, "发现新版本 " + toDisplayString(updateInfo.value.latestVersion), 1),
+ createBaseVNode("p", _hoisted_5, "当前版本 " + toDisplayString(updateInfo.value.currentVersion), 1),
+ createVNode(_component_n_checkbox, {
+ checked: noPrompt.value,
+ "onUpdate:checked": _cache[0] || (_cache[0] = ($event) => noPrompt.value = $event)
+ }, {
+ default: withCtx(() => _cache[2] || (_cache[2] = [
+ createTextVNode("不再提示")
+ ])),
+ _: 1
+ }, 8, ["checked"])
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_6, [
+ _cache[4] || (_cache[4] = createBaseVNode("div", { class: "update-title" }, "更新内容:", -1)),
+ createVNode(_component_n_scrollbar, { style: { "max-height": "300px" } }, {
+ default: withCtx(() => [
+ createBaseVNode("div", {
+ class: "update-body",
+ innerHTML: parsedReleaseNotes.value
+ }, null, 8, _hoisted_7)
+ ]),
+ _: 1
+ })
+ ]),
+ createBaseVNode("div", _hoisted_8, [
+ createVNode(_component_n_button, {
+ class: "cancel-btn",
+ onClick: closeModal
+ }, {
+ default: withCtx(() => _cache[5] || (_cache[5] = [
+ createTextVNode("暂不更新")
+ ])),
+ _: 1
+ }),
+ createVNode(_component_n_button, {
+ type: "primary",
+ class: "update-btn",
+ onClick: handleUpdate
+ }, {
+ default: withCtx(() => _cache[6] || (_cache[6] = [
+ createTextVNode("立即更新")
+ ])),
+ _: 1
+ })
+ ]),
+ _cache[7] || (_cache[7] = createBaseVNode("div", { class: "modal-desc mt-4 text-center" }, [
+ createBaseVNode("p", { class: "text-xs text-gray-400" }, [
+ createTextVNode(" 下载遇到问题?去 "),
+ createBaseVNode("a", {
+ class: "text-green-500",
+ target: "_blank",
+ href: "https://github.com/algerkong/AlgerMusicPlayer/releases"
+ }, "GitHub"),
+ createTextVNode(" 下载最新版本 ")
+ ])
+ ], -1))
+ ])
+ ]),
+ _: 1
+ }, 8, ["show"]);
+ };
+ }
+});
+const UpdateModal = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-f3abdbb7"]]);
+const _hoisted_1$1 = { class: "layout-page" };
+const _hoisted_2$1 = {
+ id: "layout-main",
+ class: "layout-main"
+};
+const _hoisted_3 = { class: "main" };
+const _hoisted_4 = {
+ class: "main-content",
+ "native-scrollbar": false
+};
+const _sfc_main$2 = /* @__PURE__ */ defineComponent({
+ __name: "AppLayout",
+ setup(__props) {
+ const keepAliveInclude = computed(
+ () => layoutRouter.filter((item) => {
+ return item.meta.keepAlive;
+ }).map((item) => {
+ return item.name.charAt(0).toUpperCase() + item.name.slice(1);
+ })
+ );
+ const AppMenu = /* @__PURE__ */ defineAsyncComponent(() => __vitePreload(() => import("./AppMenu-CbDXL_JE.js"), true ? __vite__mapDeps([33,34]) : void 0, import.meta.url));
+ const PlayBar = /* @__PURE__ */ defineAsyncComponent(() => __vitePreload(() => import("./PlayBar-BNzUvTGp.js"), true ? __vite__mapDeps([35,3,4,5,6,7,20,8,18,36]) : void 0, import.meta.url));
+ const SearchBar = /* @__PURE__ */ defineAsyncComponent(() => __vitePreload(() => import("./SearchBar-Cx7zzS9t.js"), true ? __vite__mapDeps([37,1,38,4,5,17,31,9,10,39]) : void 0, import.meta.url));
+ const TitleBar = /* @__PURE__ */ defineAsyncComponent(() => __vitePreload(() => import("./TitleBar-Bl1cFyS0.js"), true ? __vite__mapDeps([40,41]) : void 0, import.meta.url));
+ const store2 = useStore();
+ const isPlay = computed(() => store2.state.isPlay);
+ const { menus } = store2.state;
+ const route = useRoute();
+ onMounted(() => {
+ store2.dispatch("initializeSettings");
+ store2.dispatch("initializeTheme");
+ });
+ return (_ctx, _cache) => {
+ const _component_router_view = resolveComponent("router-view");
+ return openBlock(), createElementBlock("div", _hoisted_1$1, [
+ createBaseVNode("div", _hoisted_2$1, [
+ unref(isElectron) ? (openBlock(), createBlock(unref(TitleBar), { key: 0 })) : createCommentVNode("", true),
+ createBaseVNode("div", {
+ class: normalizeClass(["layout-main-page", unref(isElectron) ? "" : "pt-6"])
+ }, [
+ !unref(isMobile) ? (openBlock(), createBlock(unref(AppMenu), {
+ key: 0,
+ class: "menu",
+ menus: unref(menus)
+ }, null, 8, ["menus"])) : createCommentVNode("", true),
+ createBaseVNode("div", _hoisted_3, [
+ createVNode(unref(SearchBar)),
+ createBaseVNode("div", _hoisted_4, [
+ createVNode(_component_router_view, {
+ class: normalizeClass(["main-page", unref(route).meta.noScroll && !unref(isMobile) ? "pr-3" : ""])
+ }, {
+ default: withCtx(({ Component }) => [
+ (openBlock(), createBlock(KeepAlive, { include: keepAliveInclude.value }, [
+ (openBlock(), createBlock(resolveDynamicComponent(Component)))
+ ], 1032, ["include"]))
+ ]),
+ _: 1
+ }, 8, ["class"])
+ ]),
+ createVNode(PlayBottom, { height: "5rem" }),
+ unref(isMobile) ? (openBlock(), createBlock(unref(AppMenu), {
+ key: 0,
+ class: "menu",
+ menus: unref(menus)
+ }, null, 8, ["menus"])) : createCommentVNode("", true)
+ ])
+ ], 2),
+ isPlay.value ? (openBlock(), createBlock(unref(PlayBar), { key: 1 })) : createCommentVNode("", true)
+ ]),
+ createVNode(InstallAppModal),
+ createVNode(UpdateModal)
+ ]);
+ };
+ }
+});
+const AppLayout = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-f03a9852"]]);
+const loginRouter = {
+ path: "/login",
+ name: "login",
+ mate: {
+ keepAlive: true,
+ title: "登录",
+ icon: "icon-Home"
+ },
+ component: () => __vitePreload(() => import("./index-Dn0J0Jmw.js"), true ? __vite__mapDeps([42,38,43]) : void 0, import.meta.url)
+};
+const setRouter = {
+ path: "/set",
+ name: "set",
+ mate: {
+ keepAlive: true,
+ title: "设置",
+ icon: "icon-Home"
+ },
+ component: () => __vitePreload(() => import("./index-RCxsGzpS.js"), true ? __vite__mapDeps([30,31,5,10,18,32]) : void 0, import.meta.url)
+};
+const routes = [
+ {
+ path: "/",
+ component: AppLayout,
+ children: [...layoutRouter, loginRouter, setRouter]
+ },
+ {
+ path: "/lyric",
+ component: () => __vitePreload(() => import("./index-BCv4VDKm.js"), true ? __vite__mapDeps([44,45]) : void 0, import.meta.url)
+ }
+];
+const router = createRouter({
+ routes,
+ history: createWebHashHistory()
+});
+const _sfc_main$1 = /* @__PURE__ */ defineComponent({
+ __name: "App",
+ setup(__props) {
+ const theme = computed(() => {
+ return store.state.theme;
+ });
+ onMounted(() => {
+ store.dispatch("initializeSettings");
+ store.dispatch("initializeTheme");
+ if (isMobile.value) {
+ store.commit(
+ "setMenus",
+ layoutRouter.filter((item) => item.meta.isMobile)
+ );
+ console.log(
+ "qqq ",
+ layoutRouter.filter((item) => item.meta.isMobile)
+ );
+ }
+ });
+ return (_ctx, _cache) => {
+ const _component_router_view = resolveComponent("router-view");
+ const _component_n_message_provider = __unplugin_components_0$1;
+ const _component_n_dialog_provider = NDialogProvider;
+ const _component_n_config_provider = __unplugin_components_2;
+ return openBlock(), createElementBlock("div", {
+ class: normalizeClass(["app-container", { mobile: unref(isMobile), noElectron: !unref(isElectron) }])
+ }, [
+ createVNode(_component_n_config_provider, {
+ theme: unref(theme) === "dark" ? unref(darkTheme) : unref(lightTheme)
+ }, {
+ default: withCtx(() => [
+ createVNode(_component_n_dialog_provider, null, {
+ default: withCtx(() => [
+ createVNode(_component_n_message_provider, null, {
+ default: withCtx(() => [
+ createVNode(_component_router_view)
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ })
+ ]),
+ _: 1
+ }, 8, ["theme"])
+ ], 2);
+ };
+ }
+});
+const App = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-49a312c0"]]);
+const _hoisted_1 = {
+ key: 0,
+ class: "loading-box"
+};
+const _hoisted_2 = { class: "loading-content-box" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "index",
+ props: {
+ tip: {
+ type: String,
+ default() {
+ return "加载中...";
+ }
+ },
+ maskBackground: {
+ type: String,
+ default() {
+ return "rgba(0, 0, 0, 0.05)";
+ }
+ },
+ loadingColor: {
+ type: String,
+ default() {
+ return "rgba(255, 255, 255, 1)";
+ }
+ },
+ textColor: {
+ type: String,
+ default() {
+ return "rgba(255, 255, 255, 1)";
+ }
+ }
+ },
+ setup(__props, { expose: __expose }) {
+ const isShow = ref(false);
+ const show = () => {
+ isShow.value = true;
+ };
+ const hide = () => {
+ isShow.value = false;
+ };
+ __expose({
+ show,
+ hide,
+ isShow
+ });
+ return (_ctx, _cache) => {
+ return isShow.value ? (openBlock(), createElementBlock("div", _hoisted_1, [
+ _cache[0] || (_cache[0] = createBaseVNode("div", { class: "mask" }, null, -1)),
+ createBaseVNode("div", _hoisted_2, [
+ createVNode(unref(__unplugin_components_0), { size: "small" }),
+ createBaseVNode("div", {
+ style: normalizeStyle({ color: __props.textColor }),
+ class: "tip"
+ }, toDisplayString(__props.tip), 5)
+ ])
+ ])) : createCommentVNode("", true);
+ };
+ }
+});
+const Loading = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-d776f97a"]]);
+const vnode = createVNode(Loading);
+const vLoading = {
+ // 在绑定元素的父组件 及他自己的所有子节点都挂载完成后调用
+ mounted: (el) => {
+ render$2(vnode, el);
+ },
+ // 在绑定元素的父组件 及他自己的所有子节点都更新后调用
+ updated: (el, binding) => {
+ if (binding.value) {
+ vnode?.component?.exposed?.show();
+ } else {
+ vnode?.component?.exposed?.hide();
+ }
+ formatterClass(el, binding);
+ },
+ // 绑定元素的父组件卸载后调用
+ unmounted: () => {
+ vnode?.component?.exposed?.hide();
+ }
+};
+function formatterClass(el, binding) {
+ const classStr = el.getAttribute("class");
+ const tagetClass = classStr?.indexOf("loading-parent");
+ if (binding.value) {
+ if (tagetClass === -1) {
+ el.setAttribute("class", `${classStr} loading-parent`);
+ }
+ } else if (tagetClass > -1) {
+ const classArray = classStr?.split("");
+ classArray.splice(tagetClass - 1, tagetClass + 15);
+ el.setAttribute("class", classArray?.join(""));
+ }
+}
+const directives = {
+ loading: vLoading
+};
+const app = createApp(App);
+Object.keys(directives).forEach((key) => {
+ app.directive(key, directives[key]);
+});
+app.use(router);
+app.use(store);
+app.mount("#app");
+export {
+ provide as $,
+ toRef as A,
+ Button as B,
+ useMergedState as C,
+ useMemo as D,
+ watch as E,
+ useRtl as F,
+ computed as G,
+ rgba as H,
+ resolveWrappedSlot as I,
+ on as J,
+ resolveSlot as K,
+ call as L,
+ nextTick as M,
+ NBaseIcon as N,
+ createBlock as O,
+ checkUpdate as P,
+ config as Q,
+ isElectron as R,
+ Scrollbar as S,
+ createCommentVNode as T,
+ PlayBottom as U,
+ cNotM as V,
+ cM as W,
+ XButton as X,
+ cE as Y,
+ useStyle as Z,
+ _export_sfc as _,
+ onBeforeUnmount as a,
+ fadeInTransition as a$,
+ buttonGroupInjectionKey as a0,
+ onUnmounted as a1,
+ normalizeStyle as a2,
+ Fragment as a3,
+ renderList as a4,
+ setAnimationDelay as a5,
+ vShow as a6,
+ getImgUrl as a7,
+ watchEffect as a8,
+ setBackgroundImg as a9,
+ store as aA,
+ getTextColors as aB,
+ getHoverBackgroundColor as aC,
+ animateGradient as aD,
+ useDebounceFn as aE,
+ useThrottleFn as aF,
+ useTemplateRef as aG,
+ secondToMinute as aH,
+ layoutLight as aI,
+ useReactivated as aJ,
+ Scrollbar$1 as aK,
+ createInjectionKey as aL,
+ fadeInScaleUpTransition as aM,
+ insideModal as aN,
+ insidePopover as aO,
+ onBeforeUpdate as aP,
+ sliderLight as aQ,
+ isMounted as aR,
+ off as aS,
+ clickoutside as aT,
+ useLockHtmlScroll as aU,
+ FocusTrap as aV,
+ drawerInjectionKey as aW,
+ drawerBodyInjectionKey as aX,
+ popoverBodyInjectionKey as aY,
+ modalBodyInjectionKey as aZ,
+ commonVariables$n as a_,
+ router as aa,
+ resolveDirective as ab,
+ isMobile as ac,
+ request$1 as ad,
+ audioService as ae,
+ useRoute as af,
+ useDateFormat as ag,
+ withModifiers as ah,
+ formatNumber as ai,
+ __unplugin_components_0 as aj,
+ Transition as ak,
+ useMusicHistory as al,
+ getMusicDetail as am,
+ emptyLight as an,
+ createKey as ao,
+ useThemeClass as ap,
+ onActivated as aq,
+ resolveComponent as ar,
+ inject as as,
+ useSsrAdapter as at,
+ onDeactivated as au,
+ depx as av,
+ pxfy as aw,
+ mergeProps as ax,
+ VResizeObserver as ay,
+ XScrollbar as az,
+ createBaseVNode as b,
+ cCB as b$,
+ useIsComposing as b0,
+ LazyTeleport as b1,
+ drawerLight as b2,
+ eventEffectNotPerformed as b3,
+ zindexable as b4,
+ getImageBackground as b5,
+ useMergedClsPrefix as b6,
+ ellipsisLight as b7,
+ reactive as b8,
+ hasInstance as b9,
+ getNative as bA,
+ root as bB,
+ overArg as bC,
+ isPrototype as bD,
+ isArrayLike as bE,
+ arrayLikeKeys as bF,
+ isArray$1 as bG,
+ isSymbol as bH,
+ MapCache as bI,
+ toString$2 as bJ,
+ toSource as bK,
+ Map$1 as bL,
+ baseGetTag as bM,
+ Symbol$1 as bN,
+ eq as bO,
+ Uint8Array$1 as bP,
+ isBuffer$1 as bQ,
+ Stack as bR,
+ isTypedArray$1 as bS,
+ isObjectLike as bT,
+ isObject$2 as bU,
+ isLength as bV,
+ isIndex as bW,
+ isArguments as bX,
+ identity as bY,
+ baseFor as bZ,
+ arrayMap as b_,
+ onBeforeMount as ba,
+ readonly as bb,
+ render as bc,
+ warn as bd,
+ dropdownLight as be,
+ keep as bf,
+ renderSlot as bg,
+ withKeys as bh,
+ throwError as bi,
+ messageApiInjectionKey as bj,
+ replaceable as bk,
+ iconSwitchTransition as bl,
+ NIconSwitchTransition as bm,
+ NBaseLoading as bn,
+ resolveSlotWithProps as bo,
+ inputLight as bp,
+ isSafari as bq,
+ getCurrentInstance as br,
+ getMargin as bs,
+ switchLight as bt,
+ isSlotEmpty as bu,
+ iconLight as bv,
+ avatarLight as bw,
+ color2Class as bx,
+ tagLight as by,
+ NBaseClose as bz,
+ createElementBlock as c,
+ popoverLight as c0,
+ getPreciseEventTarget as c1,
+ useCompitable as c2,
+ getFirstSlotVNode as c3,
+ cloneVNode as c4,
+ Text as c5,
+ isBrowser$1 as c6,
+ tooltipLight as c7,
+ imageLight as c8,
+ isBrowser$2 as c9,
+ getSlot as ca,
+ getFirstVNode as cb,
+ CssRender as cc,
+ configProviderInjectionKey as cd,
+ dialogApiInjectionKey as ce,
+ defineComponent as d,
+ createVNode as e,
+ withCtx as f,
+ useStore as g,
+ useRouter as h,
+ isRef as i,
+ openBlock as j,
+ createTextVNode as k,
+ h as l,
+ c as m,
+ normalizeClass as n,
+ onMounted as o,
+ cB as p,
+ useTheme as q,
+ ref as r,
+ setAnimationClass as s,
+ toDisplayString as t,
+ unref as u,
+ vModelText as v,
+ withDirectives as w,
+ useConfig as x,
+ inputNumberLight as y,
+ useFormItem as z
+};
diff --git a/out/renderer/assets/index-DKaFsuse.js.gz b/out/renderer/assets/index-DKaFsuse.js.gz
new file mode 100644
index 0000000..a85bc24
Binary files /dev/null and b/out/renderer/assets/index-DKaFsuse.js.gz differ
diff --git a/out/renderer/assets/index-DSilVM87.js b/out/renderer/assets/index-DSilVM87.js
new file mode 100644
index 0000000..7369825
--- /dev/null
+++ b/out/renderer/assets/index-DSilVM87.js
@@ -0,0 +1,424 @@
+import { d as defineComponent, r as ref, G as computed, a5 as setAnimationDelay, E as watch, h as useRouter, o as onMounted, j as openBlock, c as createElementBlock, b as createBaseVNode, n as normalizeClass, u as unref, s as setAnimationClass, a3 as Fragment, a4 as renderList, w as withDirectives, a6 as vShow, a2 as normalizeStyle, t as toDisplayString, _ as _export_sfc, e as createVNode, a7 as getImgUrl, T as createCommentVNode, g as useStore, a8 as watchEffect, O as createBlock, f as withCtx, a9 as setBackgroundImg, k as createTextVNode, aa as router, S as Scrollbar, ab as resolveDirective, ac as isMobile } from "./index-DKaFsuse.js";
+import { g as getPlaylistCategory, a as getNewAlbum, b as getHotSinger, c as getDayRecommend, d as getRecommendMusic } from "./home-BXGE9AqN.js";
+import { M as MusicList, g as getAlbum } from "./MusicList-s-QHu-iA.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { F as Favorite } from "./index-JJypdZPY.js";
+import "./Drawer-BEJ8Ydua.js";
+import "./Avatar-rQ2og-6c.js";
+import "./Tag-C0oC92WF.js";
+import "./Ellipsis-D4R5dIX2.js";
+import "./use-locale-DLWAOXez.js";
+const _hoisted_1$4 = { class: "play-list-type" };
+const _hoisted_2$3 = ["onClick"];
+const DELAY_TIME = 40;
+const _sfc_main$4 = /* @__PURE__ */ defineComponent({
+ __name: "PlaylistType",
+ setup(__props) {
+ const playlistCategory = ref();
+ const isShowAllPlaylistCategory = ref(false);
+ const getAnimationDelay = computed(() => {
+ return (index2) => {
+ if (index2 <= 19) {
+ return setAnimationDelay(index2, DELAY_TIME);
+ }
+ if (!isShowAllPlaylistCategory.value) {
+ const nowIndex = (playlistCategory.value?.sub.length || 0) - index2;
+ return setAnimationDelay(nowIndex, DELAY_TIME);
+ }
+ return setAnimationDelay(index2 - 19, DELAY_TIME);
+ };
+ });
+ watch(isShowAllPlaylistCategory, (newVal) => {
+ if (!newVal) {
+ const elements = playlistCategory.value?.sub.map(
+ (_, index2) => document.querySelector(`.type-item-${index2}`)
+ );
+ elements.slice(20).reverse().forEach((element, index2) => {
+ if (element) {
+ setTimeout(
+ () => {
+ element.style.position = "absolute";
+ },
+ index2 * DELAY_TIME + 400
+ );
+ }
+ });
+ setTimeout(
+ () => {
+ isHiding.value = false;
+ document.querySelectorAll(".play-list-type-item").forEach((element) => {
+ if (element) {
+ console.log("element", element);
+ element.style.position = "none";
+ }
+ });
+ },
+ (playlistCategory.value?.sub.length || 0 - 19) * DELAY_TIME
+ );
+ } else {
+ document.querySelectorAll(".play-list-type-item").forEach((element) => {
+ if (element) {
+ element.style.position = "none";
+ }
+ });
+ }
+ });
+ const loadPlaylistCategory = async () => {
+ const { data } = await getPlaylistCategory();
+ playlistCategory.value = data;
+ };
+ const router2 = useRouter();
+ const handleClickPlaylistType = (type) => {
+ router2.push({
+ path: "/list",
+ query: {
+ type
+ }
+ });
+ };
+ const isHiding = ref(false);
+ const handleToggleShowAllPlaylistCategory = () => {
+ isShowAllPlaylistCategory.value = !isShowAllPlaylistCategory.value;
+ if (!isShowAllPlaylistCategory.value) {
+ isHiding.value = true;
+ }
+ };
+ onMounted(() => {
+ loadPlaylistCategory();
+ });
+ return (_ctx, _cache) => {
+ return openBlock(), createElementBlock("div", _hoisted_1$4, [
+ createBaseVNode("div", {
+ class: normalizeClass(["title", unref(setAnimationClass)("animate__fadeInLeft")])
+ }, "歌单分类", 2),
+ createBaseVNode("div", null, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(playlistCategory.value?.sub, (item, index2) => {
+ return withDirectives((openBlock(), createElementBlock("span", {
+ key: item.name,
+ class: normalizeClass([
+ "play-list-type-item",
+ unref(setAnimationClass)(
+ index2 <= 19 ? "animate__bounceIn" : !isShowAllPlaylistCategory.value ? "animate__backOutLeft" : "animate__bounceIn"
+ ) + " type-item-" + index2
+ ]),
+ style: normalizeStyle(getAnimationDelay.value(index2)),
+ onClick: ($event) => handleClickPlaylistType(item.name)
+ }, toDisplayString(item.name), 15, _hoisted_2$3)), [
+ [vShow, isShowAllPlaylistCategory.value || index2 <= 19 || isHiding.value]
+ ]);
+ }), 128)),
+ createBaseVNode("div", {
+ class: normalizeClass(["play-list-type-showall", unref(setAnimationClass)("animate__bounceIn")]),
+ style: normalizeStyle(
+ unref(setAnimationDelay)(
+ !isShowAllPlaylistCategory.value ? 25 : playlistCategory.value?.sub.length || 100 + 30
+ )
+ ),
+ onClick: handleToggleShowAllPlaylistCategory
+ }, toDisplayString(!isShowAllPlaylistCategory.value ? "显示全部" : "隐藏一些"), 7)
+ ])
+ ]);
+ };
+ }
+});
+const PlaylistType = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-686a7f41"]]);
+const _hoisted_1$3 = { class: "recommend-album" };
+const _hoisted_2$2 = { class: "recommend-album-list" };
+const _hoisted_3$1 = ["onClick"];
+const _hoisted_4$1 = { class: "recommend-album-list-item-content" };
+const _sfc_main$3 = /* @__PURE__ */ defineComponent({
+ __name: "RecommendAlbum",
+ setup(__props) {
+ const albumData = ref();
+ const loadAlbumList = async () => {
+ const { data } = await getNewAlbum();
+ albumData.value = data;
+ };
+ const showMusic = ref(false);
+ const songList = ref([]);
+ const albumName = ref("");
+ const loadingList = ref(false);
+ const albumInfo = ref({});
+ const handleClick = async (item) => {
+ songList.value = [];
+ albumInfo.value = {};
+ albumName.value = item.name;
+ loadingList.value = true;
+ showMusic.value = true;
+ const res = await getAlbum(item.id);
+ songList.value = res.data.songs.map((song) => {
+ song.al.picUrl = song.al.picUrl || item.picUrl;
+ return song;
+ });
+ albumInfo.value = {
+ ...res.data.album,
+ creator: {
+ avatarUrl: res.data.album.artist.img1v1Url,
+ nickname: `${res.data.album.artist.name} - ${res.data.album.company}`
+ },
+ description: res.data.album.description
+ };
+ loadingList.value = false;
+ };
+ onMounted(() => {
+ loadAlbumList();
+ });
+ return (_ctx, _cache) => {
+ const _component_n_image = NImage;
+ return openBlock(), createElementBlock("div", _hoisted_1$3, [
+ createBaseVNode("div", {
+ class: normalizeClass(["title", unref(setAnimationClass)("animate__fadeInRight")])
+ }, "最新专辑", 2),
+ createBaseVNode("div", _hoisted_2$2, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(albumData.value?.albums, (item, index2) => {
+ return openBlock(), createElementBlock(Fragment, {
+ key: item.id
+ }, [
+ index2 < 6 ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: normalizeClass(["recommend-album-list-item", unref(setAnimationClass)("animate__backInUp")]),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 100)),
+ onClick: ($event) => handleClick(item)
+ }, [
+ createVNode(_component_n_image, {
+ class: "recommend-album-list-item-img",
+ src: unref(getImgUrl)(item.blurPicUrl, "200y200"),
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_4$1, toDisplayString(item.name), 1)
+ ], 14, _hoisted_3$1)) : createCommentVNode("", true)
+ ], 64);
+ }), 128))
+ ]),
+ createVNode(MusicList, {
+ show: showMusic.value,
+ "onUpdate:show": _cache[0] || (_cache[0] = ($event) => showMusic.value = $event),
+ name: albumName.value,
+ "song-list": songList.value,
+ cover: false,
+ loading: loadingList.value,
+ "list-info": albumInfo.value
+ }, null, 8, ["show", "name", "song-list", "loading", "list-info"])
+ ]);
+ };
+ }
+});
+const RecommendAlbum = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-1df7dbee"]]);
+const _hoisted_1$2 = { class: "recommend-singer" };
+const _hoisted_2$1 = { class: "recommend-singer-list" };
+const _hoisted_3 = { class: "mt-2" };
+const _hoisted_4 = { class: "recommend-singer-item-count p-2 text-base text-gray-200 z-10" };
+const _hoisted_5 = { class: "recommend-singer-item-info z-10" };
+const _hoisted_6 = ["onClick"];
+const _hoisted_7 = { class: "ml-4" };
+const _hoisted_8 = { class: "recommend-singer-item-info-name text-el" };
+const _hoisted_9 = { class: "recommend-singer-item-info-name text-el" };
+const _sfc_main$2 = /* @__PURE__ */ defineComponent({
+ __name: "RecommendSinger",
+ setup(__props) {
+ const store = useStore();
+ const hotSingerData = ref();
+ const dayRecommendData = ref();
+ const showMusic = ref(false);
+ onMounted(async () => {
+ await loadData();
+ });
+ const loadData = async () => {
+ try {
+ const { data: singerData } = await getHotSinger({ offset: 0, limit: 5 });
+ try {
+ const {
+ data: { data: dayRecommend }
+ } = await getDayRecommend();
+ if (dayRecommend) {
+ singerData.artists = singerData.artists.slice(0, 4);
+ }
+ dayRecommendData.value = dayRecommend;
+ } catch (error) {
+ console.error("error", error);
+ }
+ hotSingerData.value = singerData;
+ } catch (error) {
+ console.error("error", error);
+ }
+ };
+ const toSearchSinger = (keyword) => {
+ router.push({
+ path: "/search",
+ query: {
+ keyword
+ }
+ });
+ };
+ watchEffect(() => {
+ if (store.state.user) {
+ loadData();
+ }
+ });
+ return (_ctx, _cache) => {
+ const _component_n_scrollbar = Scrollbar;
+ return openBlock(), createBlock(_component_n_scrollbar, {
+ size: 100,
+ "x-scrollable": true
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1$2, [
+ createBaseVNode("div", _hoisted_2$1, [
+ dayRecommendData.value ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: normalizeClass(["recommend-singer-item relative", unref(setAnimationClass)("animate__backInRight")]),
+ style: normalizeStyle(unref(setAnimationDelay)(0, 100))
+ }, [
+ createBaseVNode("div", {
+ style: normalizeStyle(
+ unref(setBackgroundImg)(unref(getImgUrl)(dayRecommendData.value?.dailySongs[0].al.picUrl, "500y500"))
+ ),
+ class: "recommend-singer-item-bg"
+ }, null, 4),
+ createBaseVNode("div", {
+ class: "recommend-singer-item-count p-2 text-base text-gray-200 z-10 cursor-pointer",
+ onClick: _cache[0] || (_cache[0] = ($event) => showMusic.value = true)
+ }, [
+ _cache[3] || (_cache[3] = createBaseVNode("div", { class: "font-bold text-xl" }, "每日推荐", -1)),
+ createBaseVNode("div", _hoisted_3, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(dayRecommendData.value?.dailySongs.slice(0, 5), (item) => {
+ return openBlock(), createElementBlock("p", {
+ key: item.id,
+ class: "text-el"
+ }, [
+ createTextVNode(toDisplayString(item.name) + " ", 1),
+ _cache[2] || (_cache[2] = createBaseVNode("br", null, null, -1))
+ ]);
+ }), 128))
+ ])
+ ])
+ ], 6)) : createCommentVNode("", true),
+ (openBlock(true), createElementBlock(Fragment, null, renderList(hotSingerData.value?.artists, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["recommend-singer-item relative", unref(setAnimationClass)("animate__backInRight")]),
+ style: normalizeStyle(unref(setAnimationDelay)(index2 + 1, 100))
+ }, [
+ createBaseVNode("div", {
+ style: normalizeStyle(unref(setBackgroundImg)(unref(getImgUrl)(item.picUrl, "500y500"))),
+ class: "recommend-singer-item-bg"
+ }, null, 4),
+ createBaseVNode("div", _hoisted_4, toDisplayString(item.musicSize) + "首 ", 1),
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("div", {
+ class: "recommend-singer-item-info-play",
+ onClick: ($event) => toSearchSinger(item.name)
+ }, _cache[4] || (_cache[4] = [
+ createBaseVNode("i", { class: "iconfont icon-playfill text-xl" }, null, -1)
+ ]), 8, _hoisted_6),
+ createBaseVNode("div", _hoisted_7, [
+ createBaseVNode("div", _hoisted_8, toDisplayString(item.name), 1),
+ createBaseVNode("div", _hoisted_9, toDisplayString(item.name), 1)
+ ])
+ ])
+ ], 6);
+ }), 128))
+ ]),
+ dayRecommendData.value?.dailySongs.length ? (openBlock(), createBlock(MusicList, {
+ key: 0,
+ show: showMusic.value,
+ "onUpdate:show": _cache[1] || (_cache[1] = ($event) => showMusic.value = $event),
+ name: "每日推荐列表",
+ "song-list": dayRecommendData.value?.dailySongs,
+ cover: false
+ }, null, 8, ["show", "song-list"])) : createCommentVNode("", true)
+ ])
+ ]),
+ _: 1
+ });
+ };
+ }
+});
+const RecommendSinger = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-f8da161d"]]);
+const _hoisted_1$1 = { class: "recommend-music" };
+const _sfc_main$1 = /* @__PURE__ */ defineComponent({
+ __name: "RecommendSonglist",
+ setup(__props) {
+ const store = useStore();
+ const recommendMusic = ref();
+ const loading = ref(false);
+ const loadRecommendMusic = async () => {
+ loading.value = true;
+ const { data } = await getRecommendMusic({ limit: 10 });
+ recommendMusic.value = data;
+ loading.value = false;
+ };
+ onMounted(() => {
+ loadRecommendMusic();
+ });
+ const handlePlay = () => {
+ store.commit("setPlayList", recommendMusic.value?.result);
+ };
+ return (_ctx, _cache) => {
+ const _directive_loading = resolveDirective("loading");
+ return openBlock(), createElementBlock("div", _hoisted_1$1, [
+ createBaseVNode("div", {
+ class: normalizeClass(["title", unref(setAnimationClass)("animate__fadeInLeft")])
+ }, "本周最热音乐", 2),
+ withDirectives((openBlock(), createElementBlock("div", {
+ class: normalizeClass(["recommend-music-list", unref(setAnimationClass)("animate__bounceInUp")])
+ }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(recommendMusic)?.result, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(unref(setAnimationClass)("animate__bounceInUp")),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 100))
+ }, [
+ createVNode(SongItem, {
+ item,
+ onPlay: handlePlay
+ }, null, 8, ["item"])
+ ], 6);
+ }), 128))
+ ], 2)), [
+ [vShow, unref(recommendMusic)?.result],
+ [_directive_loading, unref(loading)]
+ ])
+ ]);
+ };
+ }
+});
+const RecommendSonglist = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-ae2da107"]]);
+const _hoisted_1 = { class: "main-page" };
+const _hoisted_2 = { class: "main-content" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "Home"
+ },
+ __name: "index",
+ setup(__props) {
+ return (_ctx, _cache) => {
+ const _component_n_scrollbar = Scrollbar;
+ return openBlock(), createBlock(_component_n_scrollbar, {
+ size: 100,
+ "x-scrollable": false
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1, [
+ createVNode(RecommendSinger),
+ createBaseVNode("div", _hoisted_2, [
+ !unref(isMobile) ? (openBlock(), createBlock(PlaylistType, { key: 0 })) : createCommentVNode("", true),
+ createVNode(RecommendSonglist),
+ createBaseVNode("div", null, [
+ createVNode(Favorite, { "is-component": "" }),
+ createVNode(RecommendAlbum)
+ ])
+ ])
+ ])
+ ]),
+ _: 1
+ });
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-b0ca1b97"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-DSilVM87.js.gz b/out/renderer/assets/index-DSilVM87.js.gz
new file mode 100644
index 0000000..418d6f5
Binary files /dev/null and b/out/renderer/assets/index-DSilVM87.js.gz differ
diff --git a/out/renderer/assets/index-DVDStqOk.css b/out/renderer/assets/index-DVDStqOk.css
new file mode 100644
index 0000000..9ad6dea
--- /dev/null
+++ b/out/renderer/assets/index-DVDStqOk.css
@@ -0,0 +1,120 @@
+.set-page[data-v-0331ad9e] {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+
+ padding: 1rem
+}
+.set-page[data-v-0331ad9e]:is(.dark *) {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1))
+}
+.set-item[data-v-0331ad9e] {
+
+ margin-bottom: 1rem;
+
+ display: flex;
+
+ align-items: center;
+
+ justify-content: space-between;
+
+ border-radius: 0.5rem;
+
+ padding: 1rem;
+
+ transition-property: all;
+
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+
+ transition-duration: 150ms;
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+
+ --tw-text-opacity: 1;
+
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.set-item[data-v-0331ad9e]:is(.dark *) {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+
+ --tw-text-opacity: 1;
+
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.set-item[data-v-0331ad9e] {
+
+ border-width: 1px;
+
+ --tw-border-opacity: 1;
+
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1))
+}
+.set-item[data-v-0331ad9e]:is(.dark *) {
+
+ --tw-border-opacity: 1;
+
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1))
+}
+.set-item-title[data-v-0331ad9e] {
+
+ margin-bottom: 0.25rem;
+
+ font-size: 1rem;
+
+ line-height: 1.5rem;
+
+ font-weight: 500
+}
+.set-item-content[data-v-0331ad9e] {
+
+ font-size: 0.875rem;
+
+ line-height: 1.25rem;
+
+ --tw-text-opacity: 1;
+
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.set-item-content[data-v-0331ad9e]:is(.dark *) {
+
+ --tw-text-opacity: 1;
+
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.set-item[data-v-0331ad9e]:hover {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(249 250 251 / var(--tw-bg-opacity, 1))
+}
+.set-item[data-v-0331ad9e]:hover:is(.dark *) {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1))
+}
+.set-item.cursor-pointer[data-v-0331ad9e]:hover {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(240 253 244 / var(--tw-bg-opacity, 1));
+
+ --tw-text-opacity: 1;
+
+ color: rgb(34 197 94 / var(--tw-text-opacity, 1))
+}
+.set-item.cursor-pointer[data-v-0331ad9e]:hover:is(.dark *) {
+
+ --tw-bg-opacity: 1;
+
+ background-color: rgb(20 83 45 / var(--tw-bg-opacity, 1))
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-DVDStqOk.css.gz b/out/renderer/assets/index-DVDStqOk.css.gz
new file mode 100644
index 0000000..e705153
Binary files /dev/null and b/out/renderer/assets/index-DVDStqOk.css.gz differ
diff --git a/out/renderer/assets/index-DcmHQdN6.css b/out/renderer/assets/index-DcmHQdN6.css
new file mode 100644
index 0000000..de2bad0
--- /dev/null
+++ b/out/renderer/assets/index-DcmHQdN6.css
@@ -0,0 +1,189 @@
+.login-page[data-v-baab8304] {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+ padding: 5rem;
+ padding-top: 5rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}.login-page[data-v-baab8304]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.login-title[data-v-baab8304] {
+ margin-bottom: 1.5rem;
+ font-size: 1.5rem;
+ line-height: 2rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.text[data-v-baab8304] {
+ margin-top: 1rem;
+ font-size: 0.75rem;
+ line-height: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.phone-login[data-v-baab8304] {
+ width: 350px;
+ height: 550px;
+ position: relative;
+ overflow: hidden;
+ border-radius: 1rem;
+ border-bottom-right-radius: 0px;
+ border-bottom-left-radius: 0px;
+ background-size: cover;
+ background-repeat: no-repeat;
+ background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' version='1.1' xmlns:xlink='http://www.w3.org/1999/xlink' xmlns:svgjs='http://svgjs.dev/svgjs' width='400' height='560' preserveAspectRatio='none' viewBox='0 0 400 560'%3e%3cg mask='url(%26quot%3b%23SvgjsMask1066%26quot%3b)' fill='none'%3e%3crect width='400' height='560' x='0' y='0' fill='rgba(24%2c 106%2c 59%2c 1)'%3e%3c/rect%3e%3cpath d='M0%2c234.738C43.535%2c236.921%2c80.103%2c205.252%2c116.272%2c180.923C151.738%2c157.067%2c188.295%2c132.929%2c207.855%2c94.924C227.898%2c55.979%2c233.386%2c10.682%2c226.119%2c-32.511C218.952%2c-75.107%2c199.189%2c-115.793%2c167.469%2c-145.113C137.399%2c-172.909%2c92.499%2c-171.842%2c55.779%2c-189.967C8.719%2c-213.196%2c-28.344%2c-282.721%2c-78.217%2c-266.382C-128.725%2c-249.834%2c-111.35%2c-166.696%2c-143.781%2c-124.587C-173.232%2c-86.348%2c-244.72%2c-83.812%2c-255.129%2c-36.682C-265.368%2c9.678%2c-217.952%2c48.26%2c-190.512%2c87.004C-167.691%2c119.226%2c-140.216%2c145.431%2c-109.013%2c169.627C-74.874%2c196.1%2c-43.147%2c232.575%2c0%2c234.738' fill='%23114b2a'%3e%3c/path%3e%3cpath d='M400 800.9010000000001C443.973 795.023 480.102 765.6 513.011 735.848 541.923 709.71 561.585 676.6320000000001 577.037 640.85 592.211 605.712 606.958 568.912 601.458 531.035 595.962 493.182 568.394 464.36400000000003 546.825 432.775 522.317 396.88300000000004 507.656 347.475 466.528 333.426 425.366 319.366 384.338 352.414 342.111 362.847 297.497 373.869 242.385 362.645 211.294 396.486 180.212 430.318 192.333 483.83299999999997 188.872 529.644 185.656 572.218 178.696 614.453 191.757 655.101 205.885 699.068 227.92 742.4110000000001 265.75 768.898 304.214 795.829 353.459 807.1220000000001 400 800.9010000000001' fill='%231f894c'%3e%3c/path%3e%3c/g%3e%3cdefs%3e%3cmask id='SvgjsMask1066'%3e%3crect width='400' height='560' fill='white'%3e%3c/rect%3e%3c/mask%3e%3c/defs%3e%3c/svg%3e");
+ box-shadow: inset 0px 0px 20px 5px rgba(0, 0, 0, 0.37);
+}
+.phone-login .bg[data-v-baab8304] {
+ position: absolute;
+ height: 100%;
+ width: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(248 249 250 / var(--tw-bg-opacity, 1));
+ opacity: 0.2;
+}
+.phone-login .bg[data-v-baab8304]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 22 22 / var(--tw-bg-opacity, 1));
+}
+.phone-login .bottom[data-v-baab8304] {
+ width: 200%;
+ height: 250px;
+ bottom: -180px;
+ border-radius: 50%;
+ left: 50%;
+ padding: 10px;
+ transform: translateX(-50%);
+ position: absolute;
+ display: flex;
+ cursor: pointer;
+ justify-content: center;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+}
+.phone-login .bottom[data-v-baab8304]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.phone-login .bottom[data-v-baab8304] {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.phone-login .bottom[data-v-baab8304]:hover {
+ --tw-text-opacity: 1;
+ color: rgb(31 41 55 / var(--tw-text-opacity, 1));
+}
+.phone-login .bottom[data-v-baab8304]:is(.dark *):hover {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.phone-login .bottom[data-v-baab8304] {
+ box-shadow: 10px 0px 20px rgba(0, 0, 0, 0.66);
+}
+.phone-login .content[data-v-baab8304] {
+ position: absolute;
+ display: flex;
+ height: 100%;
+ width: 100%;
+ flex-direction: column;
+ align-items: center;
+ justify-content: center;
+ padding: 1rem;
+ padding-bottom: 5rem;
+ text-align: center;
+}
+.phone-login .content .qr-img[data-v-baab8304] {
+ cursor: pointer;
+ border-radius: 1rem;
+ transition-property: opacity;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.phone-login .content .phone[data-v-baab8304] {
+ animation-duration: 0.5s;
+}
+.phone-login .content .phone-page[data-v-baab8304] {
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.9;
+}
+.phone-login .content .phone-page[data-v-baab8304]:is(.dark *) {
+ background-color: rgb(31 41 55 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.9;
+}
+.phone-login .content .phone-page[data-v-baab8304] {
+ width: 250px;
+ overflow: hidden;
+ border-radius: 1rem;
+}
+.phone-login .content .phone-input[data-v-baab8304] {
+ height: 40px;
+ width: 100%;
+ padding-left: 1rem;
+ padding-right: 1rem;
+ outline: 2px solid transparent;
+ outline-offset: 2px;
+ background-color: transparent;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304] {
+ border-bottom-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]::-moz-placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-placeholder-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]::placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-placeholder-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]:is(.dark *)::-moz-placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-placeholder-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]:is(.dark *)::placeholder {
+ --tw-placeholder-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-placeholder-opacity, 1));
+}
+.phone-login .content .phone-input[data-v-baab8304]:focus {
+ --tw-border-opacity: 1;
+ border-color: rgb(34 197 94 / var(--tw-border-opacity, 1));
+}
+.phone-login .content .btn-login[data-v-baab8304] {
+ width: 250px;
+ height: 40px;
+ margin-top: 2.5rem;
+ border-radius: 0.75rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(22 163 74 / var(--tw-bg-opacity, 1));
+ transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 150ms;
+}
+.phone-login .content .btn-login[data-v-baab8304]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(21 128 61 / var(--tw-bg-opacity, 1));
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-DcmHQdN6.css.gz b/out/renderer/assets/index-DcmHQdN6.css.gz
new file mode 100644
index 0000000..2d08a0f
Binary files /dev/null and b/out/renderer/assets/index-DcmHQdN6.css.gz differ
diff --git a/out/renderer/assets/index-DhLgZEXT.js b/out/renderer/assets/index-DhLgZEXT.js
new file mode 100644
index 0000000..5318c50
--- /dev/null
+++ b/out/renderer/assets/index-DhLgZEXT.js
@@ -0,0 +1,151 @@
+import { F as Favorite } from "./index-JJypdZPY.js";
+import { d as defineComponent, al as useMusicHistory, r as ref, o as onMounted, c as createElementBlock, b as createBaseVNode, n as normalizeClass, u as unref, e as createVNode, f as withCtx, am as getMusicDetail, S as Scrollbar, g as useStore, j as openBlock, s as setAnimationClass, a3 as Fragment, a4 as renderList, a2 as normalizeStyle, a5 as setAnimationDelay, t as toDisplayString, T as createCommentVNode, aj as __unplugin_components_0, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import "./use-locale-DLWAOXez.js";
+import "./Image-DXClIklC.js";
+import "./Ellipsis-D4R5dIX2.js";
+const _hoisted_1$1 = { class: "history-page" };
+const _hoisted_2 = { class: "history-item-count min-w-[60px]" };
+const _hoisted_3 = { class: "history-item-delete" };
+const _hoisted_4 = ["onClick"];
+const _hoisted_5 = {
+ key: 0,
+ class: "loading-wrapper"
+};
+const _hoisted_6 = {
+ key: 1,
+ class: "no-more-tip"
+};
+const pageSize = 20;
+const _sfc_main$1 = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "History"
+ },
+ __name: "index",
+ setup(__props) {
+ const store = useStore();
+ const { delMusic, musicList } = useMusicHistory();
+ const scrollbarRef = ref();
+ const loading = ref(false);
+ const noMore = ref(false);
+ const displayList = ref([]);
+ const currentPage = ref(1);
+ const getHistorySongs = async () => {
+ if (musicList.value.length === 0) {
+ displayList.value = [];
+ return;
+ }
+ loading.value = true;
+ try {
+ const startIndex = (currentPage.value - 1) * pageSize;
+ const endIndex = startIndex + pageSize;
+ const currentPageItems = musicList.value.slice(startIndex, endIndex);
+ const currentIds = currentPageItems.map((item) => item.id);
+ const res = await getMusicDetail(currentIds);
+ if (res.data.songs) {
+ const newSongs = res.data.songs.map((song) => {
+ const historyItem = currentPageItems.find((item) => item.id === song.id);
+ return {
+ ...song,
+ picUrl: song.al?.picUrl || "",
+ count: historyItem?.count || 0
+ };
+ });
+ if (currentPage.value === 1) {
+ displayList.value = newSongs;
+ } else {
+ displayList.value = [...displayList.value, ...newSongs];
+ }
+ noMore.value = displayList.value.length >= musicList.value.length;
+ }
+ } catch (error) {
+ console.error("获取历史记录失败:", error);
+ } finally {
+ loading.value = false;
+ }
+ };
+ const handleScroll = (e) => {
+ const { scrollTop, scrollHeight, offsetHeight } = e.target;
+ const threshold = 100;
+ if (!loading.value && !noMore.value && scrollHeight - (scrollTop + offsetHeight) < threshold) {
+ currentPage.value++;
+ getHistorySongs();
+ }
+ };
+ const handlePlay = () => {
+ store.commit("setPlayList", displayList.value);
+ };
+ onMounted(() => {
+ getHistorySongs();
+ });
+ const handleDelMusic = async (item) => {
+ delMusic(item);
+ musicList.value = musicList.value.filter((music) => music.id !== item.id);
+ displayList.value = displayList.value.filter((music) => music.id !== item.id);
+ };
+ return (_ctx, _cache) => {
+ const _component_n_spin = __unplugin_components_0;
+ const _component_n_scrollbar = Scrollbar;
+ return openBlock(), createElementBlock("div", _hoisted_1$1, [
+ createBaseVNode("div", {
+ class: normalizeClass(["title", unref(setAnimationClass)("animate__fadeInRight")])
+ }, "播放历史", 2),
+ createVNode(_component_n_scrollbar, {
+ ref_key: "scrollbarRef",
+ ref: scrollbarRef,
+ size: 100,
+ onScroll: handleScroll
+ }, {
+ default: withCtx(() => [
+ createBaseVNode("div", {
+ class: normalizeClass(["history-list-content", unref(setAnimationClass)("animate__bounceInLeft")])
+ }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(displayList.value, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["history-item", unref(setAnimationClass)("animate__bounceInRight")]),
+ style: normalizeStyle(unref(setAnimationDelay)(index2, 30))
+ }, [
+ createVNode(SongItem, {
+ class: "history-item-content",
+ item,
+ onPlay: handlePlay
+ }, null, 8, ["item"]),
+ createBaseVNode("div", _hoisted_2, toDisplayString(item.count), 1),
+ createBaseVNode("div", _hoisted_3, [
+ createBaseVNode("i", {
+ class: "iconfont icon-close",
+ onClick: ($event) => handleDelMusic(item)
+ }, null, 8, _hoisted_4)
+ ])
+ ], 6);
+ }), 128)),
+ loading.value ? (openBlock(), createElementBlock("div", _hoisted_5, [
+ createVNode(_component_n_spin, { size: "large" })
+ ])) : createCommentVNode("", true),
+ noMore.value ? (openBlock(), createElementBlock("div", _hoisted_6, "没有更多了")) : createCommentVNode("", true)
+ ], 2)
+ ]),
+ _: 1
+ }, 512)
+ ]);
+ };
+ }
+});
+const History = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-7e434221"]]);
+const _hoisted_1 = { class: "flex gap-4 h-full pb-4" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "index",
+ setup(__props) {
+ return (_ctx, _cache) => {
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ createVNode(Favorite, { class: "flex-item" }),
+ createVNode(History, { class: "flex-item" })
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-36d023b3"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-DhLgZEXT.js.gz b/out/renderer/assets/index-DhLgZEXT.js.gz
new file mode 100644
index 0000000..44989b0
Binary files /dev/null and b/out/renderer/assets/index-DhLgZEXT.js.gz differ
diff --git a/out/renderer/assets/index-Dn0J0Jmw.js b/out/renderer/assets/index-Dn0J0Jmw.js
new file mode 100644
index 0000000..86a88be
--- /dev/null
+++ b/out/renderer/assets/index-Dn0J0Jmw.js
@@ -0,0 +1,155 @@
+import { d as defineComponent, r as ref, o as onMounted, a as onBeforeUnmount, c as createElementBlock, b as createBaseVNode, u as unref, n as normalizeClass, w as withDirectives, v as vModelText, i as isRef, e as createVNode, f as withCtx, t as toDisplayString, g as useStore, h as useRouter, B as Button, j as openBlock, s as setAnimationClass, k as createTextVNode, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { u as useMessage, g as getQrKey, c as createQr, a as checkQr, b as getUserDetail, l as loginByCellphone } from "./login-BsPxQYi6.js";
+const _hoisted_1 = { class: "login-page" };
+const _hoisted_2 = { class: "phone-login" };
+const _hoisted_3 = { class: "content" };
+const _hoisted_4 = ["src"];
+const _hoisted_5 = { class: "phone-page" };
+const _hoisted_6 = { class: "bottom" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "Login"
+ },
+ __name: "index",
+ setup(__props) {
+ const message = useMessage();
+ const store = useStore();
+ const router = useRouter();
+ const isQr = ref(false);
+ const qrUrl = ref();
+ onMounted(() => {
+ loadLogin();
+ });
+ const timerRef = ref(null);
+ const loadLogin = async () => {
+ try {
+ if (timerRef.value) {
+ clearInterval(timerRef.value);
+ timerRef.value = null;
+ }
+ if (!isQr.value) return;
+ const qrKey = await getQrKey();
+ const key = qrKey.data.data.unikey;
+ const { data } = await createQr(key);
+ qrUrl.value = data.data.qrimg;
+ const timer = timerIsQr(key);
+ timerRef.value = timer;
+ } catch (error) {
+ console.error("加载登录信息时出错:", error);
+ }
+ };
+ const timerIsQr = (key) => {
+ const timer = setInterval(async () => {
+ try {
+ const { data } = await checkQr(key);
+ if (data.code === 800) {
+ clearInterval(timer);
+ timerRef.value = null;
+ }
+ if (data.code === 803) {
+ localStorage.setItem("token", data.cookie);
+ const user = await getUserDetail();
+ store.state.user = user.data.profile;
+ localStorage.setItem("user", JSON.stringify(store.state.user));
+ message.success("登录成功");
+ clearInterval(timer);
+ timerRef.value = null;
+ router.push("/user");
+ }
+ } catch (error) {
+ console.error("检查二维码状态时出错:", error);
+ clearInterval(timer);
+ timerRef.value = null;
+ }
+ }, 3e3);
+ return timer;
+ };
+ onBeforeUnmount(() => {
+ if (timerRef.value) {
+ clearInterval(timerRef.value);
+ timerRef.value = null;
+ }
+ });
+ const chooseQr = () => {
+ isQr.value = !isQr.value;
+ loadLogin();
+ };
+ const phone = ref("");
+ const password = ref("");
+ const loginPhone = async () => {
+ const { data } = await loginByCellphone(phone.value, password.value);
+ if (data.code === 200) {
+ message.success("登录成功");
+ store.state.user = data.profile;
+ localStorage.setItem("token", data.cookie);
+ setTimeout(() => {
+ router.push("/user");
+ }, 1e3);
+ }
+ };
+ return (_ctx, _cache) => {
+ const _component_n_button = Button;
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ _cache[9] || (_cache[9] = createBaseVNode("div", { class: "bg" }, null, -1)),
+ createBaseVNode("div", _hoisted_3, [
+ unref(isQr) ? (openBlock(), createElementBlock("div", {
+ key: 0,
+ class: normalizeClass(["phone", unref(setAnimationClass)("animate__fadeInUp")])
+ }, [
+ _cache[4] || (_cache[4] = createBaseVNode("div", { class: "login-title" }, "扫码登陆", -1)),
+ createBaseVNode("img", {
+ class: "qr-img",
+ src: unref(qrUrl)
+ }, null, 8, _hoisted_4),
+ _cache[5] || (_cache[5] = createBaseVNode("div", { class: "text" }, "使用网易云APP扫码登录", -1))
+ ], 2)) : (openBlock(), createElementBlock("div", {
+ key: 1,
+ class: normalizeClass(["phone", unref(setAnimationClass)("animate__fadeInUp")])
+ }, [
+ _cache[7] || (_cache[7] = createBaseVNode("div", { class: "login-title" }, "手机号登录", -1)),
+ createBaseVNode("div", _hoisted_5, [
+ withDirectives(createBaseVNode("input", {
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => isRef(phone) ? phone.value = $event : null),
+ class: "phone-input",
+ type: "text",
+ placeholder: "手机号"
+ }, null, 512), [
+ [vModelText, unref(phone)]
+ ]),
+ withDirectives(createBaseVNode("input", {
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => isRef(password) ? password.value = $event : null),
+ class: "phone-input",
+ type: "password",
+ placeholder: "密码"
+ }, null, 512), [
+ [vModelText, unref(password)]
+ ])
+ ]),
+ _cache[8] || (_cache[8] = createBaseVNode("div", { class: "text" }, "使用网易云账号登录", -1)),
+ createVNode(_component_n_button, {
+ class: "btn-login",
+ onClick: _cache[2] || (_cache[2] = ($event) => loginPhone())
+ }, {
+ default: withCtx(() => _cache[6] || (_cache[6] = [
+ createTextVNode("登录")
+ ])),
+ _: 1
+ })
+ ], 2))
+ ]),
+ createBaseVNode("div", _hoisted_6, [
+ createBaseVNode("div", {
+ class: "title",
+ onClick: _cache[3] || (_cache[3] = ($event) => chooseQr())
+ }, toDisplayString(unref(isQr) ? "手机号登录" : "扫码登录"), 1)
+ ])
+ ])
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-baab8304"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-Dn0J0Jmw.js.gz b/out/renderer/assets/index-Dn0J0Jmw.js.gz
new file mode 100644
index 0000000..0f7a1c1
Binary files /dev/null and b/out/renderer/assets/index-Dn0J0Jmw.js.gz differ
diff --git a/out/renderer/assets/index-JJypdZPY.js b/out/renderer/assets/index-JJypdZPY.js
new file mode 100644
index 0000000..a863787
--- /dev/null
+++ b/out/renderer/assets/index-JJypdZPY.js
@@ -0,0 +1,320 @@
+import { d as defineComponent, l as h, p as cB, Y as cE, m as c, q as useTheme, x as useConfig, an as emptyLight, G as computed, ao as createKey, ap as useThemeClass, N as NBaseIcon, r as ref, o as onMounted, E as watch, c as createElementBlock, b as createBaseVNode, t as toDisplayString, n as normalizeClass, u as unref, e as createVNode, f as withCtx, T as createCommentVNode, am as getMusicDetail, S as Scrollbar, g as useStore, h as useRouter, j as openBlock, s as setAnimationClass, a3 as Fragment, a4 as renderList, O as createBlock, a2 as normalizeStyle, k as createTextVNode, a5 as setAnimationDelay, B as Button, aj as __unplugin_components_0$1, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { S as SongItem } from "./SongItem-CoswpGn6.js";
+import { u as useLocale } from "./use-locale-DLWAOXez.js";
+const EmptyIcon = defineComponent({
+ name: "Empty",
+ render() {
+ return h("svg", {
+ viewBox: "0 0 28 28",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M26 7.5C26 11.0899 23.0899 14 19.5 14C15.9101 14 13 11.0899 13 7.5C13 3.91015 15.9101 1 19.5 1C23.0899 1 26 3.91015 26 7.5ZM16.8536 4.14645C16.6583 3.95118 16.3417 3.95118 16.1464 4.14645C15.9512 4.34171 15.9512 4.65829 16.1464 4.85355L18.7929 7.5L16.1464 10.1464C15.9512 10.3417 15.9512 10.6583 16.1464 10.8536C16.3417 11.0488 16.6583 11.0488 16.8536 10.8536L19.5 8.20711L22.1464 10.8536C22.3417 11.0488 22.6583 11.0488 22.8536 10.8536C23.0488 10.6583 23.0488 10.3417 22.8536 10.1464L20.2071 7.5L22.8536 4.85355C23.0488 4.65829 23.0488 4.34171 22.8536 4.14645C22.6583 3.95118 22.3417 3.95118 22.1464 4.14645L19.5 6.79289L16.8536 4.14645Z",
+ fill: "currentColor"
+ }), h("path", {
+ d: "M25 22.75V12.5991C24.5572 13.0765 24.053 13.4961 23.5 13.8454V16H17.5L17.3982 16.0068C17.0322 16.0565 16.75 16.3703 16.75 16.75C16.75 18.2688 15.5188 19.5 14 19.5C12.4812 19.5 11.25 18.2688 11.25 16.75L11.2432 16.6482C11.1935 16.2822 10.8797 16 10.5 16H4.5V7.25C4.5 6.2835 5.2835 5.5 6.25 5.5H12.2696C12.4146 4.97463 12.6153 4.47237 12.865 4H6.25C4.45507 4 3 5.45507 3 7.25V22.75C3 24.5449 4.45507 26 6.25 26H21.75C23.5449 26 25 24.5449 25 22.75ZM4.5 22.75V17.5H9.81597L9.85751 17.7041C10.2905 19.5919 11.9808 21 14 21L14.215 20.9947C16.2095 20.8953 17.842 19.4209 18.184 17.5H23.5V22.75C23.5 23.7165 22.7165 24.5 21.75 24.5H6.25C5.2835 24.5 4.5 23.7165 4.5 22.75Z",
+ fill: "currentColor"
+ }));
+ }
+});
+const style = cB("empty", `
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ font-size: var(--n-font-size);
+`, [cE("icon", `
+ width: var(--n-icon-size);
+ height: var(--n-icon-size);
+ font-size: var(--n-icon-size);
+ line-height: var(--n-icon-size);
+ color: var(--n-icon-color);
+ transition:
+ color .3s var(--n-bezier);
+ `, [c("+", [cE("description", `
+ margin-top: 8px;
+ `)])]), cE("description", `
+ transition: color .3s var(--n-bezier);
+ color: var(--n-text-color);
+ `), cE("extra", `
+ text-align: center;
+ transition: color .3s var(--n-bezier);
+ margin-top: 12px;
+ color: var(--n-extra-text-color);
+ `)]);
+const emptyProps = Object.assign(Object.assign({}, useTheme.props), {
+ description: String,
+ showDescription: {
+ type: Boolean,
+ default: true
+ },
+ showIcon: {
+ type: Boolean,
+ default: true
+ },
+ size: {
+ type: String,
+ default: "medium"
+ },
+ renderIcon: Function
+});
+const __unplugin_components_0 = defineComponent({
+ name: "Empty",
+ props: emptyProps,
+ setup(props) {
+ const {
+ mergedClsPrefixRef,
+ inlineThemeDisabled,
+ mergedComponentPropsRef
+ } = useConfig(props);
+ const themeRef = useTheme("Empty", "-empty", style, emptyLight, props, mergedClsPrefixRef);
+ const {
+ localeRef
+ } = useLocale("Empty");
+ const mergedDescriptionRef = computed(() => {
+ var _a, _b, _c;
+ return (_a = props.description) !== null && _a !== void 0 ? _a : (_c = (_b = mergedComponentPropsRef === null || mergedComponentPropsRef === void 0 ? void 0 : mergedComponentPropsRef.value) === null || _b === void 0 ? void 0 : _b.Empty) === null || _c === void 0 ? void 0 : _c.description;
+ });
+ const mergedRenderIconRef = computed(() => {
+ var _a, _b;
+ return ((_b = (_a = mergedComponentPropsRef === null || mergedComponentPropsRef === void 0 ? void 0 : mergedComponentPropsRef.value) === null || _a === void 0 ? void 0 : _a.Empty) === null || _b === void 0 ? void 0 : _b.renderIcon) || (() => h(EmptyIcon, null));
+ });
+ const cssVarsRef = computed(() => {
+ const {
+ size
+ } = props;
+ const {
+ common: {
+ cubicBezierEaseInOut
+ },
+ self: {
+ [createKey("iconSize", size)]: iconSize,
+ [createKey("fontSize", size)]: fontSize,
+ textColor,
+ iconColor,
+ extraTextColor
+ }
+ } = themeRef.value;
+ return {
+ "--n-icon-size": iconSize,
+ "--n-font-size": fontSize,
+ "--n-bezier": cubicBezierEaseInOut,
+ "--n-text-color": textColor,
+ "--n-icon-color": iconColor,
+ "--n-extra-text-color": extraTextColor
+ };
+ });
+ const themeClassHandle = inlineThemeDisabled ? useThemeClass("empty", computed(() => {
+ let hash = "";
+ const {
+ size
+ } = props;
+ hash += size[0];
+ return hash;
+ }), cssVarsRef, props) : void 0;
+ return {
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedRenderIcon: mergedRenderIconRef,
+ localizedDescription: computed(() => {
+ return mergedDescriptionRef.value || localeRef.value.description;
+ }),
+ cssVars: inlineThemeDisabled ? void 0 : cssVarsRef,
+ themeClass: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.themeClass,
+ onRender: themeClassHandle === null || themeClassHandle === void 0 ? void 0 : themeClassHandle.onRender
+ };
+ },
+ render() {
+ const {
+ $slots,
+ mergedClsPrefix,
+ onRender
+ } = this;
+ onRender === null || onRender === void 0 ? void 0 : onRender();
+ return h("div", {
+ class: [`${mergedClsPrefix}-empty`, this.themeClass],
+ style: this.cssVars
+ }, this.showIcon ? h("div", {
+ class: `${mergedClsPrefix}-empty__icon`
+ }, $slots.icon ? $slots.icon() : h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix
+ }, {
+ default: this.mergedRenderIcon
+ })) : null, this.showDescription ? h("div", {
+ class: `${mergedClsPrefix}-empty__description`
+ }, $slots.default ? $slots.default() : this.localizedDescription) : null, $slots.extra ? h("div", {
+ class: `${mergedClsPrefix}-empty__extra`
+ }, $slots.extra()) : null);
+ }
+});
+const _hoisted_1 = {
+ key: 0,
+ class: "favorite-page"
+};
+const _hoisted_2 = { class: "favorite-count" };
+const _hoisted_3 = {
+ key: 0,
+ class: "empty-tip"
+};
+const _hoisted_4 = {
+ key: 1,
+ class: "favorite-list"
+};
+const _hoisted_5 = {
+ key: 0,
+ class: "favorite-list-more text-center"
+};
+const _hoisted_6 = {
+ key: 1,
+ class: "loading-wrapper"
+};
+const _hoisted_7 = {
+ key: 2,
+ class: "no-more-tip"
+};
+const pageSize = 16;
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "index",
+ props: {
+ isComponent: {
+ type: Boolean,
+ default: false
+ }
+ },
+ setup(__props) {
+ const store = useStore();
+ const favoriteList = computed(() => store.state.favoriteList);
+ const favoriteSongs = ref([]);
+ const loading = ref(false);
+ const noMore = ref(false);
+ const scrollbarRef = ref();
+ const currentPage = ref(1);
+ const props = __props;
+ const getCurrentPageIds = () => {
+ const reversedList = [...favoriteList.value];
+ const startIndex = (currentPage.value - 1) * pageSize;
+ const endIndex = startIndex + pageSize;
+ return reversedList.slice(startIndex, endIndex);
+ };
+ const getFavoriteSongs = async () => {
+ if (favoriteList.value.length === 0) {
+ favoriteSongs.value = [];
+ return;
+ }
+ if (props.isComponent && favoriteSongs.value.length >= 16) {
+ return;
+ }
+ loading.value = true;
+ try {
+ const currentIds = getCurrentPageIds();
+ const res = await getMusicDetail(currentIds);
+ if (res.data.songs) {
+ const newSongs = res.data.songs.map((song) => ({
+ ...song,
+ picUrl: song.al?.picUrl || ""
+ }));
+ if (currentPage.value === 1) {
+ favoriteSongs.value = newSongs;
+ } else {
+ favoriteSongs.value = [...favoriteSongs.value, ...newSongs];
+ }
+ noMore.value = favoriteSongs.value.length >= favoriteList.value.length;
+ }
+ } catch (error) {
+ console.error("获取收藏歌曲失败:", error);
+ } finally {
+ loading.value = false;
+ }
+ };
+ const handleScroll = (e) => {
+ const { scrollTop, scrollHeight, offsetHeight } = e.target;
+ const threshold = 100;
+ if (!loading.value && !noMore.value && scrollHeight - (scrollTop + offsetHeight) < threshold) {
+ currentPage.value++;
+ getFavoriteSongs();
+ }
+ };
+ onMounted(() => {
+ getFavoriteSongs();
+ });
+ watch(
+ favoriteList,
+ () => {
+ currentPage.value = 1;
+ noMore.value = false;
+ getFavoriteSongs();
+ },
+ { deep: true, immediate: true }
+ );
+ const handlePlay = () => {
+ store.commit("setPlayList", favoriteSongs.value);
+ };
+ const getItemAnimationDelay = (index) => {
+ return setAnimationDelay(index, 30);
+ };
+ const router = useRouter();
+ const handleMore = () => {
+ router.push("/favorite");
+ };
+ return (_ctx, _cache) => {
+ const _component_n_empty = __unplugin_components_0;
+ const _component_n_button = Button;
+ const _component_n_spin = __unplugin_components_0$1;
+ const _component_n_scrollbar = Scrollbar;
+ return (__props.isComponent ? favoriteSongs.value.length : true) ? (openBlock(), createElementBlock("div", _hoisted_1, [
+ createBaseVNode("div", {
+ class: normalizeClass(["favorite-header", unref(setAnimationClass)("animate__fadeInLeft")])
+ }, [
+ _cache[0] || (_cache[0] = createBaseVNode("h2", null, "我的收藏", -1)),
+ createBaseVNode("div", _hoisted_2, "共 " + toDisplayString(favoriteList.value.length) + " 首", 1)
+ ], 2),
+ createBaseVNode("div", {
+ class: normalizeClass(["favorite-main", unref(setAnimationClass)("animate__bounceInRight")])
+ }, [
+ createVNode(_component_n_scrollbar, {
+ ref_key: "scrollbarRef",
+ ref: scrollbarRef,
+ class: "favorite-content",
+ onScroll: handleScroll
+ }, {
+ default: withCtx(() => [
+ favoriteList.value.length === 0 ? (openBlock(), createElementBlock("div", _hoisted_3, [
+ createVNode(_component_n_empty, { description: "还没有收藏歌曲" })
+ ])) : (openBlock(), createElementBlock("div", _hoisted_4, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(favoriteSongs.value, (song, index) => {
+ return openBlock(), createBlock(SongItem, {
+ key: song.id,
+ item: song,
+ favorite: !__props.isComponent,
+ class: normalizeClass(unref(setAnimationClass)("animate__bounceInLeft")),
+ style: normalizeStyle(getItemAnimationDelay(index)),
+ onPlay: handlePlay
+ }, null, 8, ["item", "favorite", "class", "style"]);
+ }), 128)),
+ __props.isComponent ? (openBlock(), createElementBlock("div", _hoisted_5, [
+ createVNode(_component_n_button, {
+ text: "",
+ type: "primary",
+ onClick: handleMore
+ }, {
+ default: withCtx(() => _cache[1] || (_cache[1] = [
+ createTextVNode("查看更多")
+ ])),
+ _: 1
+ })
+ ])) : createCommentVNode("", true),
+ loading.value ? (openBlock(), createElementBlock("div", _hoisted_6, [
+ createVNode(_component_n_spin, { size: "large" })
+ ])) : createCommentVNode("", true),
+ noMore.value ? (openBlock(), createElementBlock("div", _hoisted_7, "没有更多了")) : createCommentVNode("", true)
+ ]))
+ ]),
+ _: 1
+ }, 512)
+ ], 2)
+ ])) : createCommentVNode("", true);
+ };
+ }
+});
+const Favorite = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-2d1a7423"]]);
+export {
+ Favorite as F
+};
diff --git a/out/renderer/assets/index-JJypdZPY.js.gz b/out/renderer/assets/index-JJypdZPY.js.gz
new file mode 100644
index 0000000..d2bb6dd
Binary files /dev/null and b/out/renderer/assets/index-JJypdZPY.js.gz differ
diff --git a/out/renderer/assets/index-RCxsGzpS.js b/out/renderer/assets/index-RCxsGzpS.js
new file mode 100644
index 0000000..dc2971d
--- /dev/null
+++ b/out/renderer/assets/index-RCxsGzpS.js
@@ -0,0 +1,944 @@
+import { d as defineComponent, l as h, m as c, p as cB, q as useTheme, x as useConfig, y as inputNumberLight, z as useFormItem, r as ref, A as toRef, C as useMergedState, D as useMemo, E as watch, F as useRtl, G as computed, H as rgba, I as resolveWrappedSlot, J as on, K as resolveSlot, N as NBaseIcon, X as XButton, L as call, M as nextTick, o as onMounted, O as createBlock, f as withCtx, P as checkUpdate, S as Scrollbar, g as useStore, Q as config, j as openBlock, b as createBaseVNode, e as createVNode, u as unref, R as isElectron, c as createElementBlock, T as createCommentVNode, t as toDisplayString, k as createTextVNode, U as PlayBottom, B as Button, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { _ as __unplugin_components_1$1, a as __unplugin_components_3 } from "./Switch-D3Z_Vg3u.js";
+import { u as useLocale } from "./use-locale-DLWAOXez.js";
+import { _ as __unplugin_components_4 } from "./Tag-C0oC92WF.js";
+import { _ as __unplugin_components_0 } from "./Slider-BA6NituQ.js";
+const AddIcon = defineComponent({
+ name: "Add",
+ render() {
+ return h("svg", {
+ width: "512",
+ height: "512",
+ viewBox: "0 0 512 512",
+ fill: "none",
+ xmlns: "http://www.w3.org/2000/svg"
+ }, h("path", {
+ d: "M256 112V400M400 256H112",
+ stroke: "currentColor",
+ "stroke-width": "32",
+ "stroke-linecap": "round",
+ "stroke-linejoin": "round"
+ }));
+ }
+});
+const RemoveIcon = defineComponent({
+ name: "Remove",
+ render() {
+ return h("svg", {
+ xmlns: "http://www.w3.org/2000/svg",
+ viewBox: "0 0 512 512"
+ }, h("line", {
+ x1: "400",
+ y1: "256",
+ x2: "112",
+ y2: "256",
+ style: "\n fill: none;\n stroke: currentColor;\n stroke-linecap: round;\n stroke-linejoin: round;\n stroke-width: 32px;\n "
+ }));
+ }
+});
+const style = c([cB("input-number-suffix", `
+ display: inline-block;
+ margin-right: 10px;
+ `), cB("input-number-prefix", `
+ display: inline-block;
+ margin-left: 10px;
+ `)]);
+function parse(value) {
+ if (value === void 0 || value === null || typeof value === "string" && value.trim() === "") {
+ return null;
+ }
+ return Number(value);
+}
+function isWipValue(value) {
+ return value.includes(".") && (/^(-)?\d+.*(\.|0)$/.test(value) || /^-?\d*$/.test(value)) || value === "-" || value === "-0";
+}
+function validator(value) {
+ if (value === void 0 || value === null) return true;
+ if (Number.isNaN(value)) return false;
+ return true;
+}
+function format(value, precision) {
+ if (typeof value !== "number") return "";
+ return precision === void 0 ? String(value) : value.toFixed(precision);
+}
+function parseNumber(number) {
+ if (number === null) return null;
+ if (typeof number === "number") {
+ return number;
+ } else {
+ const parsedNumber = Number(number);
+ if (Number.isNaN(parsedNumber)) {
+ return null;
+ } else {
+ return parsedNumber;
+ }
+ }
+}
+const HOLDING_CHANGE_THRESHOLD = 800;
+const HOLDING_CHANGE_INTERVAL = 100;
+const inputNumberProps = Object.assign(Object.assign({}, useTheme.props), {
+ autofocus: Boolean,
+ loading: {
+ type: Boolean,
+ default: void 0
+ },
+ placeholder: String,
+ defaultValue: {
+ type: Number,
+ default: null
+ },
+ value: Number,
+ step: {
+ type: [Number, String],
+ default: 1
+ },
+ min: [Number, String],
+ max: [Number, String],
+ size: String,
+ disabled: {
+ type: Boolean,
+ default: void 0
+ },
+ validator: Function,
+ bordered: {
+ type: Boolean,
+ default: void 0
+ },
+ showButton: {
+ type: Boolean,
+ default: true
+ },
+ buttonPlacement: {
+ type: String,
+ default: "right"
+ },
+ inputProps: Object,
+ readonly: Boolean,
+ clearable: Boolean,
+ keyboard: {
+ type: Object,
+ default: {}
+ },
+ updateValueOnInput: {
+ type: Boolean,
+ default: true
+ },
+ round: {
+ type: Boolean,
+ default: void 0
+ },
+ parse: Function,
+ format: Function,
+ precision: Number,
+ status: String,
+ "onUpdate:value": [Function, Array],
+ onUpdateValue: [Function, Array],
+ onFocus: [Function, Array],
+ onBlur: [Function, Array],
+ onClear: [Function, Array],
+ // deprecated
+ onChange: [Function, Array]
+});
+const __unplugin_components_1 = defineComponent({
+ name: "InputNumber",
+ props: inputNumberProps,
+ setup(props) {
+ const {
+ mergedBorderedRef,
+ mergedClsPrefixRef,
+ mergedRtlRef
+ } = useConfig(props);
+ const themeRef = useTheme("InputNumber", "-input-number", style, inputNumberLight, props, mergedClsPrefixRef);
+ const {
+ localeRef
+ } = useLocale("InputNumber");
+ const formItem = useFormItem(props);
+ const {
+ mergedSizeRef,
+ mergedDisabledRef,
+ mergedStatusRef
+ } = formItem;
+ const inputInstRef = ref(null);
+ const minusButtonInstRef = ref(null);
+ const addButtonInstRef = ref(null);
+ const uncontrolledValueRef = ref(props.defaultValue);
+ const controlledValueRef = toRef(props, "value");
+ const mergedValueRef = useMergedState(controlledValueRef, uncontrolledValueRef);
+ const displayedValueRef = ref("");
+ const getPrecision = (value) => {
+ const fraction = String(value).split(".")[1];
+ return fraction ? fraction.length : 0;
+ };
+ const getMaxPrecision = (currentValue) => {
+ const precisions = [props.min, props.max, props.step, currentValue].map((value) => {
+ if (value === void 0) return 0;
+ return getPrecision(value);
+ });
+ return Math.max(...precisions);
+ };
+ const mergedPlaceholderRef = useMemo(() => {
+ const {
+ placeholder
+ } = props;
+ if (placeholder !== void 0) return placeholder;
+ return localeRef.value.placeholder;
+ });
+ const mergedStepRef = useMemo(() => {
+ const parsedNumber = parseNumber(props.step);
+ if (parsedNumber !== null) {
+ return parsedNumber === 0 ? 1 : Math.abs(parsedNumber);
+ }
+ return 1;
+ });
+ const mergedMinRef = useMemo(() => {
+ const parsedNumber = parseNumber(props.min);
+ if (parsedNumber !== null) return parsedNumber;
+ else return null;
+ });
+ const mergedMaxRef = useMemo(() => {
+ const parsedNumber = parseNumber(props.max);
+ if (parsedNumber !== null) return parsedNumber;
+ else return null;
+ });
+ const deriveDisplayedValueFromValue = () => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (validator(mergedValue)) {
+ const {
+ format: formatProp,
+ precision
+ } = props;
+ if (formatProp) {
+ displayedValueRef.value = formatProp(mergedValue);
+ } else {
+ if (mergedValue === null || precision === void 0 || getPrecision(mergedValue) > precision) {
+ displayedValueRef.value = format(mergedValue, void 0);
+ } else {
+ displayedValueRef.value = format(mergedValue, precision);
+ }
+ }
+ } else {
+ displayedValueRef.value = String(mergedValue);
+ }
+ };
+ deriveDisplayedValueFromValue();
+ const doUpdateValue = (value) => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (value === mergedValue) {
+ deriveDisplayedValueFromValue();
+ return;
+ }
+ const {
+ "onUpdate:value": _onUpdateValue,
+ onUpdateValue,
+ onChange
+ } = props;
+ const {
+ nTriggerFormInput,
+ nTriggerFormChange
+ } = formItem;
+ if (onChange) call(onChange, value);
+ if (onUpdateValue) call(onUpdateValue, value);
+ if (_onUpdateValue) call(_onUpdateValue, value);
+ uncontrolledValueRef.value = value;
+ nTriggerFormInput();
+ nTriggerFormChange();
+ };
+ const deriveValueFromDisplayedValue = ({
+ offset,
+ doUpdateIfValid,
+ fixPrecision,
+ isInputing
+ }) => {
+ const {
+ value: displayedValue
+ } = displayedValueRef;
+ if (isInputing && isWipValue(displayedValue)) {
+ return false;
+ }
+ const parsedValue = (props.parse || parse)(displayedValue);
+ if (parsedValue === null) {
+ if (doUpdateIfValid) doUpdateValue(null);
+ return null;
+ }
+ if (validator(parsedValue)) {
+ const currentPrecision = getPrecision(parsedValue);
+ const {
+ precision
+ } = props;
+ if (precision !== void 0 && precision < currentPrecision && !fixPrecision) {
+ return false;
+ }
+ let nextValue = Number.parseFloat((parsedValue + offset).toFixed(precision !== null && precision !== void 0 ? precision : getMaxPrecision(parsedValue)));
+ if (validator(nextValue)) {
+ const {
+ value: mergedMax
+ } = mergedMaxRef;
+ const {
+ value: mergedMin
+ } = mergedMinRef;
+ if (mergedMax !== null && nextValue > mergedMax) {
+ if (!doUpdateIfValid || isInputing) return false;
+ nextValue = mergedMax;
+ }
+ if (mergedMin !== null && nextValue < mergedMin) {
+ if (!doUpdateIfValid || isInputing) return false;
+ nextValue = mergedMin;
+ }
+ if (props.validator && !props.validator(nextValue)) return false;
+ if (doUpdateIfValid) doUpdateValue(nextValue);
+ return nextValue;
+ }
+ }
+ return false;
+ };
+ const displayedValueInvalidRef = useMemo(() => {
+ const derivedValue = deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: false,
+ isInputing: false,
+ fixPrecision: false
+ });
+ return derivedValue === false;
+ });
+ const minusableRef = useMemo(() => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (props.validator && mergedValue === null) {
+ return false;
+ }
+ const {
+ value: mergedStep
+ } = mergedStepRef;
+ const derivedNextValue = deriveValueFromDisplayedValue({
+ offset: -mergedStep,
+ doUpdateIfValid: false,
+ isInputing: false,
+ fixPrecision: false
+ });
+ return derivedNextValue !== false;
+ });
+ const addableRef = useMemo(() => {
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (props.validator && mergedValue === null) {
+ return false;
+ }
+ const {
+ value: mergedStep
+ } = mergedStepRef;
+ const derivedNextValue = deriveValueFromDisplayedValue({
+ offset: +mergedStep,
+ doUpdateIfValid: false,
+ isInputing: false,
+ fixPrecision: false
+ });
+ return derivedNextValue !== false;
+ });
+ function doFocus(e) {
+ const {
+ onFocus
+ } = props;
+ const {
+ nTriggerFormFocus
+ } = formItem;
+ if (onFocus) call(onFocus, e);
+ nTriggerFormFocus();
+ }
+ function doBlur(e) {
+ var _a, _b;
+ if (e.target === ((_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.wrapperElRef)) {
+ return;
+ }
+ const value = deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ if (value !== false) {
+ const inputElRef = (_b = inputInstRef.value) === null || _b === void 0 ? void 0 : _b.inputElRef;
+ if (inputElRef) {
+ inputElRef.value = String(value || "");
+ }
+ if (mergedValueRef.value === value) {
+ deriveDisplayedValueFromValue();
+ }
+ } else {
+ deriveDisplayedValueFromValue();
+ }
+ const {
+ onBlur
+ } = props;
+ const {
+ nTriggerFormBlur
+ } = formItem;
+ if (onBlur) call(onBlur, e);
+ nTriggerFormBlur();
+ void nextTick(() => {
+ deriveDisplayedValueFromValue();
+ });
+ }
+ function doClear(e) {
+ const {
+ onClear
+ } = props;
+ if (onClear) call(onClear, e);
+ }
+ function doAdd() {
+ const {
+ value: addable
+ } = addableRef;
+ if (!addable) {
+ clearAddHoldTimeout();
+ return;
+ }
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (mergedValue === null) {
+ if (!props.validator) {
+ doUpdateValue(createValidValue());
+ }
+ } else {
+ const {
+ value: mergedStep
+ } = mergedStepRef;
+ deriveValueFromDisplayedValue({
+ offset: mergedStep,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ }
+ }
+ function doMinus() {
+ const {
+ value: minusable
+ } = minusableRef;
+ if (!minusable) {
+ clearMinusHoldTimeout();
+ return;
+ }
+ const {
+ value: mergedValue
+ } = mergedValueRef;
+ if (mergedValue === null) {
+ if (!props.validator) {
+ doUpdateValue(createValidValue());
+ }
+ } else {
+ const {
+ value: mergedStep
+ } = mergedStepRef;
+ deriveValueFromDisplayedValue({
+ offset: -mergedStep,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ }
+ }
+ const handleFocus = doFocus;
+ const handleBlur = doBlur;
+ function createValidValue() {
+ if (props.validator) return null;
+ const {
+ value: mergedMin
+ } = mergedMinRef;
+ const {
+ value: mergedMax
+ } = mergedMaxRef;
+ if (mergedMin !== null) {
+ return Math.max(0, mergedMin);
+ } else if (mergedMax !== null) {
+ return Math.min(0, mergedMax);
+ } else {
+ return 0;
+ }
+ }
+ function handleClear(e) {
+ doClear(e);
+ doUpdateValue(null);
+ }
+ function handleMouseDown(e) {
+ var _a, _b, _c;
+ if ((_a = addButtonInstRef.value) === null || _a === void 0 ? void 0 : _a.$el.contains(e.target)) {
+ e.preventDefault();
+ }
+ if ((_b = minusButtonInstRef.value) === null || _b === void 0 ? void 0 : _b.$el.contains(e.target)) {
+ e.preventDefault();
+ }
+ (_c = inputInstRef.value) === null || _c === void 0 ? void 0 : _c.activate();
+ }
+ let minusHoldStateIntervalId = null;
+ let addHoldStateIntervalId = null;
+ let firstMinusMousedownId = null;
+ function clearMinusHoldTimeout() {
+ if (firstMinusMousedownId) {
+ window.clearTimeout(firstMinusMousedownId);
+ firstMinusMousedownId = null;
+ }
+ if (minusHoldStateIntervalId) {
+ window.clearInterval(minusHoldStateIntervalId);
+ minusHoldStateIntervalId = null;
+ }
+ }
+ let firstAddMousedownId = null;
+ function clearAddHoldTimeout() {
+ if (firstAddMousedownId) {
+ window.clearTimeout(firstAddMousedownId);
+ firstAddMousedownId = null;
+ }
+ if (addHoldStateIntervalId) {
+ window.clearInterval(addHoldStateIntervalId);
+ addHoldStateIntervalId = null;
+ }
+ }
+ function handleMinusMousedown() {
+ clearMinusHoldTimeout();
+ firstMinusMousedownId = window.setTimeout(() => {
+ minusHoldStateIntervalId = window.setInterval(() => {
+ doMinus();
+ }, HOLDING_CHANGE_INTERVAL);
+ }, HOLDING_CHANGE_THRESHOLD);
+ on("mouseup", document, clearMinusHoldTimeout, {
+ once: true
+ });
+ }
+ function handleAddMousedown() {
+ clearAddHoldTimeout();
+ firstAddMousedownId = window.setTimeout(() => {
+ addHoldStateIntervalId = window.setInterval(() => {
+ doAdd();
+ }, HOLDING_CHANGE_INTERVAL);
+ }, HOLDING_CHANGE_THRESHOLD);
+ on("mouseup", document, clearAddHoldTimeout, {
+ once: true
+ });
+ }
+ const handleAddClick = () => {
+ if (addHoldStateIntervalId) return;
+ doAdd();
+ };
+ const handleMinusClick = () => {
+ if (minusHoldStateIntervalId) return;
+ doMinus();
+ };
+ function handleKeyDown(e) {
+ var _a, _b;
+ if (e.key === "Enter") {
+ if (e.target === ((_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.wrapperElRef)) {
+ return;
+ }
+ const value = deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ if (value !== false) {
+ (_b = inputInstRef.value) === null || _b === void 0 ? void 0 : _b.deactivate();
+ }
+ } else if (e.key === "ArrowUp") {
+ if (!addableRef.value) return;
+ if (props.keyboard.ArrowUp === false) return;
+ e.preventDefault();
+ const value = deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ if (value !== false) {
+ doAdd();
+ }
+ } else if (e.key === "ArrowDown") {
+ if (!minusableRef.value) return;
+ if (props.keyboard.ArrowDown === false) return;
+ e.preventDefault();
+ const value = deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: true,
+ isInputing: false,
+ fixPrecision: true
+ });
+ if (value !== false) {
+ doMinus();
+ }
+ }
+ }
+ function handleUpdateDisplayedValue(value) {
+ displayedValueRef.value = value;
+ if (props.updateValueOnInput && !props.format && !props.parse && props.precision === void 0) {
+ deriveValueFromDisplayedValue({
+ offset: 0,
+ doUpdateIfValid: true,
+ isInputing: true,
+ fixPrecision: false
+ });
+ }
+ }
+ watch(mergedValueRef, () => {
+ deriveDisplayedValueFromValue();
+ });
+ const exposedMethods = {
+ focus: () => {
+ var _a;
+ return (_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.focus();
+ },
+ blur: () => {
+ var _a;
+ return (_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.blur();
+ },
+ select: () => {
+ var _a;
+ return (_a = inputInstRef.value) === null || _a === void 0 ? void 0 : _a.select();
+ }
+ };
+ const rtlEnabledRef = useRtl("InputNumber", mergedRtlRef, mergedClsPrefixRef);
+ return Object.assign(Object.assign({}, exposedMethods), {
+ rtlEnabled: rtlEnabledRef,
+ inputInstRef,
+ minusButtonInstRef,
+ addButtonInstRef,
+ mergedClsPrefix: mergedClsPrefixRef,
+ mergedBordered: mergedBorderedRef,
+ uncontrolledValue: uncontrolledValueRef,
+ mergedValue: mergedValueRef,
+ mergedPlaceholder: mergedPlaceholderRef,
+ displayedValueInvalid: displayedValueInvalidRef,
+ mergedSize: mergedSizeRef,
+ mergedDisabled: mergedDisabledRef,
+ displayedValue: displayedValueRef,
+ addable: addableRef,
+ minusable: minusableRef,
+ mergedStatus: mergedStatusRef,
+ handleFocus,
+ handleBlur,
+ handleClear,
+ handleMouseDown,
+ handleAddClick,
+ handleMinusClick,
+ handleAddMousedown,
+ handleMinusMousedown,
+ handleKeyDown,
+ handleUpdateDisplayedValue,
+ // theme
+ mergedTheme: themeRef,
+ inputThemeOverrides: {
+ paddingSmall: "0 8px 0 10px",
+ paddingMedium: "0 8px 0 12px",
+ paddingLarge: "0 8px 0 14px"
+ },
+ buttonThemeOverrides: computed(() => {
+ const {
+ self: {
+ iconColorDisabled
+ }
+ } = themeRef.value;
+ const [r, g, b, a] = rgba(iconColorDisabled);
+ return {
+ textColorTextDisabled: `rgb(${r}, ${g}, ${b})`,
+ opacityDisabled: `${a}`
+ };
+ })
+ });
+ },
+ render() {
+ const {
+ mergedClsPrefix,
+ $slots
+ } = this;
+ const renderMinusButton = () => {
+ return h(XButton, {
+ text: true,
+ disabled: !this.minusable || this.mergedDisabled || this.readonly,
+ focusable: false,
+ theme: this.mergedTheme.peers.Button,
+ themeOverrides: this.mergedTheme.peerOverrides.Button,
+ builtinThemeOverrides: this.buttonThemeOverrides,
+ onClick: this.handleMinusClick,
+ onMousedown: this.handleMinusMousedown,
+ ref: "minusButtonInstRef"
+ }, {
+ icon: () => resolveSlot($slots["minus-icon"], () => [h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix
+ }, {
+ default: () => h(RemoveIcon, null)
+ })])
+ });
+ };
+ const renderAddButton = () => {
+ return h(XButton, {
+ text: true,
+ disabled: !this.addable || this.mergedDisabled || this.readonly,
+ focusable: false,
+ theme: this.mergedTheme.peers.Button,
+ themeOverrides: this.mergedTheme.peerOverrides.Button,
+ builtinThemeOverrides: this.buttonThemeOverrides,
+ onClick: this.handleAddClick,
+ onMousedown: this.handleAddMousedown,
+ ref: "addButtonInstRef"
+ }, {
+ icon: () => resolveSlot($slots["add-icon"], () => [h(NBaseIcon, {
+ clsPrefix: mergedClsPrefix
+ }, {
+ default: () => h(AddIcon, null)
+ })])
+ });
+ };
+ return h("div", {
+ class: [`${mergedClsPrefix}-input-number`, this.rtlEnabled && `${mergedClsPrefix}-input-number--rtl`]
+ }, h(__unplugin_components_1$1, {
+ ref: "inputInstRef",
+ autofocus: this.autofocus,
+ status: this.mergedStatus,
+ bordered: this.mergedBordered,
+ loading: this.loading,
+ value: this.displayedValue,
+ onUpdateValue: this.handleUpdateDisplayedValue,
+ theme: this.mergedTheme.peers.Input,
+ themeOverrides: this.mergedTheme.peerOverrides.Input,
+ builtinThemeOverrides: this.inputThemeOverrides,
+ size: this.mergedSize,
+ placeholder: this.mergedPlaceholder,
+ disabled: this.mergedDisabled,
+ readonly: this.readonly,
+ round: this.round,
+ textDecoration: this.displayedValueInvalid ? "line-through" : void 0,
+ onFocus: this.handleFocus,
+ onBlur: this.handleBlur,
+ onKeydown: this.handleKeyDown,
+ onMousedown: this.handleMouseDown,
+ onClear: this.handleClear,
+ clearable: this.clearable,
+ inputProps: this.inputProps,
+ internalLoadingBeforeSuffix: true
+ }, {
+ prefix: () => {
+ var _a;
+ return this.showButton && this.buttonPlacement === "both" ? [renderMinusButton(), resolveWrappedSlot($slots.prefix, (children) => {
+ if (children) {
+ return h("span", {
+ class: `${mergedClsPrefix}-input-number-prefix`
+ }, children);
+ }
+ return null;
+ })] : (_a = $slots.prefix) === null || _a === void 0 ? void 0 : _a.call($slots);
+ },
+ suffix: () => {
+ var _a;
+ return this.showButton ? [resolveWrappedSlot($slots.suffix, (children) => {
+ if (children) {
+ return h("span", {
+ class: `${mergedClsPrefix}-input-number-suffix`
+ }, children);
+ }
+ return null;
+ }), this.buttonPlacement === "right" ? renderMinusButton() : null, renderAddButton()] : (_a = $slots.suffix) === null || _a === void 0 ? void 0 : _a.call($slots);
+ }
+ }));
+ }
+});
+const _hoisted_1 = { class: "set-page" };
+const _hoisted_2 = { class: "set-item" };
+const _hoisted_3 = {
+ key: 0,
+ class: "set-item"
+};
+const _hoisted_4 = { class: "set-item" };
+const _hoisted_5 = { class: "flex items-center gap-2" };
+const _hoisted_6 = { class: "text-sm text-gray-400" };
+const _hoisted_7 = { class: "w-40" };
+const _hoisted_8 = { class: "set-item" };
+const _hoisted_9 = { class: "set-item-content" };
+const _hoisted_10 = { class: "flex items-center gap-2" };
+const _hoisted_11 = { class: "set-item" };
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ __name: "index",
+ setup(__props) {
+ const store = useStore();
+ const checking = ref(false);
+ const updateInfo = ref({
+ hasUpdate: false,
+ latestVersion: "",
+ currentVersion: config.version,
+ releaseInfo: null
+ });
+ const setData = computed(() => store.state.setData);
+ watch(() => setData.value, (newVal) => {
+ store.commit("setSetData", newVal);
+ }, { deep: true });
+ const isDarkTheme = computed({
+ get: () => store.state.theme === "dark",
+ set: () => store.commit("toggleTheme")
+ });
+ const openAuthor = () => {
+ window.open(setData.value.authorUrl);
+ };
+ const restartApp = () => {
+ window.electron.ipcRenderer.send("restart");
+ };
+ const checkForUpdates = async () => {
+ checking.value = true;
+ try {
+ const result = await checkUpdate();
+ updateInfo.value = result;
+ } finally {
+ checking.value = false;
+ }
+ };
+ const openReleasePage = () => {
+ window.open("https://github.com/algerkong/AlgerMusicPlayer/releases/latest");
+ };
+ onMounted(() => {
+ checkForUpdates();
+ });
+ return (_ctx, _cache) => {
+ const _component_n_switch = __unplugin_components_3;
+ const _component_n_input_number = __unplugin_components_1;
+ const _component_n_slider = __unplugin_components_0;
+ const _component_n_tag = __unplugin_components_4;
+ const _component_n_button = Button;
+ const _component_n_scrollbar = Scrollbar;
+ return openBlock(), createBlock(_component_n_scrollbar, null, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ _cache[5] || (_cache[5] = createBaseVNode("div", null, [
+ createBaseVNode("div", { class: "set-item-title" }, "主题模式"),
+ createBaseVNode("div", { class: "set-item-content" }, "切换日间/夜间主题")
+ ], -1)),
+ createVNode(_component_n_switch, {
+ value: isDarkTheme.value,
+ "onUpdate:value": _cache[0] || (_cache[0] = ($event) => isDarkTheme.value = $event)
+ }, {
+ checked: withCtx(() => _cache[3] || (_cache[3] = [
+ createBaseVNode("i", { class: "ri-moon-line" }, null, -1)
+ ])),
+ unchecked: withCtx(() => _cache[4] || (_cache[4] = [
+ createBaseVNode("i", { class: "ri-sun-line" }, null, -1)
+ ])),
+ _: 1
+ }, 8, ["value"])
+ ]),
+ unref(isElectron) ? (openBlock(), createElementBlock("div", _hoisted_3, [
+ _cache[6] || (_cache[6] = createBaseVNode("div", null, [
+ createBaseVNode("div", { class: "set-item-title" }, "音乐API端口"),
+ createBaseVNode("div", { class: "set-item-content" }, " 修改后需要重启应用 ")
+ ], -1)),
+ createVNode(_component_n_input_number, {
+ value: setData.value.musicApiPort,
+ "onUpdate:value": _cache[1] || (_cache[1] = ($event) => setData.value.musicApiPort = $event)
+ }, null, 8, ["value"])
+ ])) : createCommentVNode("", true),
+ createBaseVNode("div", _hoisted_4, [
+ _cache[7] || (_cache[7] = createBaseVNode("div", null, [
+ createBaseVNode("div", { class: "set-item-title" }, "动画速度"),
+ createBaseVNode("div", { class: "set-item-content" }, "调节动画播放速度")
+ ], -1)),
+ createBaseVNode("div", _hoisted_5, [
+ createBaseVNode("span", _hoisted_6, toDisplayString(setData.value.animationSpeed) + "x", 1),
+ createBaseVNode("div", _hoisted_7, [
+ createVNode(_component_n_slider, {
+ value: setData.value.animationSpeed,
+ "onUpdate:value": _cache[2] || (_cache[2] = ($event) => setData.value.animationSpeed = $event),
+ min: 0.1,
+ max: 3,
+ step: 0.1,
+ marks: {
+ 0.1: "极慢",
+ 1: "正常",
+ 3: "极快"
+ },
+ disabled: setData.value.noAnimate,
+ class: "w-40"
+ }, null, 8, ["value", "disabled"])
+ ])
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_8, [
+ createBaseVNode("div", null, [
+ _cache[8] || (_cache[8] = createBaseVNode("div", { class: "set-item-title" }, "版本", -1)),
+ createBaseVNode("div", _hoisted_9, [
+ createTextVNode(toDisplayString(updateInfo.value.currentVersion) + " ", 1),
+ updateInfo.value.hasUpdate ? (openBlock(), createBlock(_component_n_tag, {
+ key: 0,
+ type: "success",
+ class: "ml-2"
+ }, {
+ default: withCtx(() => [
+ createTextVNode("发现新版本 " + toDisplayString(updateInfo.value.latestVersion), 1)
+ ]),
+ _: 1
+ })) : createCommentVNode("", true)
+ ])
+ ]),
+ createBaseVNode("div", _hoisted_10, [
+ createVNode(_component_n_button, {
+ type: updateInfo.value.hasUpdate ? "primary" : "default",
+ size: "small",
+ loading: checking.value,
+ onClick: checkForUpdates
+ }, {
+ default: withCtx(() => [
+ createTextVNode(toDisplayString(checking.value ? "检查中..." : "检查更新"), 1)
+ ]),
+ _: 1
+ }, 8, ["type", "loading"]),
+ updateInfo.value.hasUpdate ? (openBlock(), createBlock(_component_n_button, {
+ key: 0,
+ type: "success",
+ size: "small",
+ onClick: openReleasePage
+ }, {
+ default: withCtx(() => _cache[9] || (_cache[9] = [
+ createTextVNode(" 前往更新 ")
+ ])),
+ _: 1
+ })) : createCommentVNode("", true)
+ ])
+ ]),
+ createBaseVNode("div", {
+ class: "set-item cursor-pointer hover:text-green-500 hover:bg-green-950 transition-all",
+ onClick: openAuthor
+ }, [
+ _cache[10] || (_cache[10] = createBaseVNode("div", null, [
+ createBaseVNode("div", { class: "set-item-title" }, "作者"),
+ createBaseVNode("div", { class: "set-item-content" }, "algerkong github")
+ ], -1)),
+ createBaseVNode("div", null, toDisplayString(setData.value.author), 1)
+ ]),
+ createBaseVNode("div", _hoisted_11, [
+ _cache[12] || (_cache[12] = createBaseVNode("div", null, [
+ createBaseVNode("div", { class: "set-item-title" }, "重启"),
+ createBaseVNode("div", { class: "set-item-content" }, "重启应用")
+ ], -1)),
+ createVNode(_component_n_button, {
+ type: "primary",
+ onClick: restartApp
+ }, {
+ default: withCtx(() => _cache[11] || (_cache[11] = [
+ createTextVNode("重启")
+ ])),
+ _: 1
+ })
+ ])
+ ]),
+ createVNode(PlayBottom)
+ ]),
+ _: 1
+ });
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-0331ad9e"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-RCxsGzpS.js.gz b/out/renderer/assets/index-RCxsGzpS.js.gz
new file mode 100644
index 0000000..4229d8a
Binary files /dev/null and b/out/renderer/assets/index-RCxsGzpS.js.gz differ
diff --git a/out/renderer/assets/index-SvIREzLs.js b/out/renderer/assets/index-SvIREzLs.js
new file mode 100644
index 0000000..866b6be
--- /dev/null
+++ b/out/renderer/assets/index-SvIREzLs.js
@@ -0,0 +1,216 @@
+import { d as defineComponent, r as ref, E as watch, o as onMounted, G as computed, c as createElementBlock, b as createBaseVNode, e as createVNode, f as withCtx, S as Scrollbar, g as useStore, ae as audioService, ab as resolveDirective, j as openBlock, a3 as Fragment, a4 as renderList, n as normalizeClass, u as unref, s as setAnimationClass, a2 as normalizeStyle, t as toDisplayString, w as withDirectives, a7 as getImgUrl, ai as formatNumber, T as createCommentVNode, a5 as setAnimationDelay, _ as _export_sfc } from "./index-DKaFsuse.js";
+import { g as getTopMv, a as getAllMv, M as MvPlayer } from "./MvPlayer-I4IDK1xL.js";
+import { N as NImage } from "./Image-DXClIklC.js";
+import "./Icon-DucaliTK.js";
+import "./Slider-BA6NituQ.js";
+import "./use-locale-DLWAOXez.js";
+import "./Drawer-BEJ8Ydua.js";
+import "./Ellipsis-D4R5dIX2.js";
+const _hoisted_1 = { class: "mv-list" };
+const _hoisted_2 = { class: "play-list-type" };
+const _hoisted_3 = { class: "categories-wrapper" };
+const _hoisted_4 = ["onClick"];
+const _hoisted_5 = ["onClick"];
+const _hoisted_6 = { class: "top" };
+const _hoisted_7 = { class: "play-count" };
+const _hoisted_8 = { class: "mv-item-title" };
+const _hoisted_9 = {
+ key: 0,
+ class: "loading-more"
+};
+const _hoisted_10 = {
+ key: 1,
+ class: "no-more"
+};
+const _sfc_main = /* @__PURE__ */ defineComponent({
+ ...{
+ name: "Mv"
+ },
+ __name: "index",
+ setup(__props) {
+ const showMv = ref(false);
+ const mvList = ref([]);
+ const playMvItem = ref();
+ const store = useStore();
+ const initLoading = ref(false);
+ const loadingMore = ref(false);
+ const currentIndex = ref(0);
+ const offset = ref(0);
+ const limit = ref(42);
+ const hasMore = ref(true);
+ const categories = [
+ { label: "全部", value: "全部" },
+ { label: "内地", value: "内地" },
+ { label: "港台", value: "港台" },
+ { label: "欧美", value: "欧美" },
+ { label: "日本", value: "日本" },
+ { label: "韩国", value: "韩国" }
+ ];
+ const selectedCategory = ref("全部");
+ watch(selectedCategory, async () => {
+ offset.value = 0;
+ mvList.value = [];
+ hasMore.value = true;
+ await loadMvList();
+ });
+ const getAnimationDelay = (index2) => {
+ const currentPageIndex = index2 % limit.value;
+ return setAnimationDelay(currentPageIndex, 30);
+ };
+ onMounted(async () => {
+ await loadMvList();
+ });
+ const handleShowMv = async (item, index2) => {
+ store.commit("setIsPlay", false);
+ store.commit("setPlayMusic", false);
+ audioService.getCurrentSound()?.pause();
+ showMv.value = true;
+ currentIndex.value = index2;
+ playMvItem.value = item;
+ };
+ const playPrevMv = async (setLoading) => {
+ try {
+ if (currentIndex.value > 0) {
+ const prevItem = mvList.value[currentIndex.value - 1];
+ await handleShowMv(prevItem, currentIndex.value - 1);
+ }
+ } finally {
+ setLoading(false);
+ }
+ };
+ const playNextMv = async (setLoading) => {
+ try {
+ if (currentIndex.value < mvList.value.length - 1) {
+ const nextItem = mvList.value[currentIndex.value + 1];
+ await handleShowMv(nextItem, currentIndex.value + 1);
+ } else if (hasMore.value) {
+ await loadMvList();
+ if (mvList.value.length > currentIndex.value + 1) {
+ const nextItem = mvList.value[currentIndex.value + 1];
+ await handleShowMv(nextItem, currentIndex.value + 1);
+ } else {
+ showMv.value = false;
+ }
+ } else {
+ showMv.value = false;
+ }
+ } catch (error) {
+ console.error("加载更多MV失败:", error);
+ showMv.value = false;
+ } finally {
+ setLoading(false);
+ }
+ };
+ const loadMvList = async () => {
+ try {
+ if (!hasMore.value || loadingMore.value) return;
+ if (offset.value === 0) {
+ initLoading.value = true;
+ } else {
+ loadingMore.value = true;
+ }
+ const params = {
+ limit: limit.value,
+ offset: offset.value,
+ area: selectedCategory.value === "全部" ? "" : selectedCategory.value
+ };
+ const res = selectedCategory.value === "全部" ? await getTopMv(params) : await getAllMv(params);
+ const { data } = res.data;
+ mvList.value.push(...data);
+ hasMore.value = data.length === limit.value;
+ offset.value += limit.value;
+ } finally {
+ initLoading.value = false;
+ loadingMore.value = false;
+ }
+ };
+ const handleScroll = (e) => {
+ const target = e.target;
+ const { scrollTop, clientHeight, scrollHeight } = target;
+ const threshold = 100;
+ if (scrollHeight - (scrollTop + clientHeight) < threshold) {
+ loadMvList();
+ }
+ };
+ const isPrevDisabled = computed(() => currentIndex.value === 0);
+ return (_ctx, _cache) => {
+ const _component_n_scrollbar = Scrollbar;
+ const _component_n_image = NImage;
+ const _directive_loading = resolveDirective("loading");
+ return openBlock(), createElementBlock("div", _hoisted_1, [
+ createBaseVNode("div", _hoisted_2, [
+ createVNode(_component_n_scrollbar, { "x-scrollable": "" }, {
+ default: withCtx(() => [
+ createBaseVNode("div", _hoisted_3, [
+ (openBlock(), createElementBlock(Fragment, null, renderList(categories, (category, index2) => {
+ return createBaseVNode("span", {
+ key: category.value,
+ class: normalizeClass(["play-list-type-item", [
+ unref(setAnimationClass)("animate__bounceIn"),
+ { active: selectedCategory.value === category.value }
+ ]]),
+ style: normalizeStyle(getAnimationDelay(index2)),
+ onClick: ($event) => selectedCategory.value = category.value
+ }, toDisplayString(category.label), 15, _hoisted_4);
+ }), 64))
+ ])
+ ]),
+ _: 1
+ })
+ ]),
+ createVNode(_component_n_scrollbar, {
+ size: 100,
+ onScroll: handleScroll
+ }, {
+ default: withCtx(() => [
+ withDirectives((openBlock(), createElementBlock("div", {
+ class: normalizeClass(["mv-list-content", unref(setAnimationClass)("animate__bounceInLeft")])
+ }, [
+ (openBlock(true), createElementBlock(Fragment, null, renderList(mvList.value, (item, index2) => {
+ return openBlock(), createElementBlock("div", {
+ key: item.id,
+ class: normalizeClass(["mv-item", unref(setAnimationClass)("animate__bounceIn")]),
+ style: normalizeStyle(getAnimationDelay(index2))
+ }, [
+ createBaseVNode("div", {
+ class: "mv-item-img",
+ onClick: ($event) => handleShowMv(item, index2)
+ }, [
+ createVNode(_component_n_image, {
+ class: "mv-item-img-img",
+ src: unref(getImgUrl)(item.cover, "320y180"),
+ lazy: "",
+ "preview-disabled": ""
+ }, null, 8, ["src"]),
+ createBaseVNode("div", _hoisted_6, [
+ createBaseVNode("div", _hoisted_7, toDisplayString(unref(formatNumber)(item.playCount)), 1),
+ _cache[1] || (_cache[1] = createBaseVNode("i", { class: "iconfont icon-videofill" }, null, -1))
+ ])
+ ], 8, _hoisted_5),
+ createBaseVNode("div", _hoisted_8, toDisplayString(item.name), 1)
+ ], 6);
+ }), 128)),
+ loadingMore.value ? (openBlock(), createElementBlock("div", _hoisted_9, "加载中...")) : createCommentVNode("", true),
+ !hasMore.value && !initLoading.value ? (openBlock(), createElementBlock("div", _hoisted_10, "没有更多了")) : createCommentVNode("", true)
+ ], 2)), [
+ [_directive_loading, initLoading.value]
+ ])
+ ]),
+ _: 1
+ }),
+ createVNode(MvPlayer, {
+ show: showMv.value,
+ "onUpdate:show": _cache[0] || (_cache[0] = ($event) => showMv.value = $event),
+ "current-mv": playMvItem.value,
+ "is-prev-disabled": isPrevDisabled.value,
+ onNext: playNextMv,
+ onPrev: playPrevMv
+ }, null, 8, ["show", "current-mv", "is-prev-disabled"])
+ ]);
+ };
+ }
+});
+const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-7366dc5a"]]);
+export {
+ index as default
+};
diff --git a/out/renderer/assets/index-SvIREzLs.js.gz b/out/renderer/assets/index-SvIREzLs.js.gz
new file mode 100644
index 0000000..12f4ff8
Binary files /dev/null and b/out/renderer/assets/index-SvIREzLs.js.gz differ
diff --git a/out/renderer/assets/index-b8HibJP6.css b/out/renderer/assets/index-b8HibJP6.css
new file mode 100644
index 0000000..db907d8
--- /dev/null
+++ b/out/renderer/assets/index-b8HibJP6.css
@@ -0,0 +1,214 @@
+.mv-list[data-v-7366dc5a] {
+ display: flex;
+ height: 100%;
+ flex: 1 1 0%;
+ flex-direction: column;
+ overflow: hidden;
+}
+.mv-list-title[data-v-7366dc5a] {
+ padding-bottom: 0.5rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.mv-list-title[data-v-7366dc5a]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mv-list .play-list-type .title[data-v-7366dc5a] {
+ margin-bottom: 0.5rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.mv-list .play-list-type .title[data-v-7366dc5a]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mv-list .play-list-type .categories-wrapper[data-v-7366dc5a] {
+ display: flex;
+ align-items: center;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ white-space: nowrap;
+}
+.mv-list .play-list-type-item[data-v-7366dc5a] {
+ margin-right: 0.75rem;
+ display: inline-block;
+ cursor: pointer;
+ border-radius: 0.75rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.mv-list .play-list-type-item[data-v-7366dc5a]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mv-list .play-list-type-item[data-v-7366dc5a] {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}
+.mv-list .play-list-type-item[data-v-7366dc5a]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.mv-list .play-list-type-item[data-v-7366dc5a]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(240 253 244 / var(--tw-bg-opacity, 1));
+}
+.mv-list .play-list-type-item[data-v-7366dc5a]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(20 83 45 / var(--tw-bg-opacity, 1));
+}
+.mv-list .play-list-type-item.active[data-v-7366dc5a] {
+ --tw-border-opacity: 1;
+ border-color: rgb(34 197 94 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mv-list-content[data-v-7366dc5a] {
+ margin-top: 0.5rem;
+ display: grid;
+ gap: 1rem;
+ padding-bottom: 7rem;
+ padding-right: 1rem;
+ grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
+}
+.mv-list .mv-item[data-v-7366dc5a] {
+ border-radius: 0.5rem;
+ padding: 0.5rem;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+}
+.mv-list .mv-item[data-v-7366dc5a]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+}
+.mv-list .mv-item[data-v-7366dc5a] {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1));
+}
+.mv-list .mv-item[data-v-7366dc5a]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1));
+}
+.mv-list .mv-item-img[data-v-7366dc5a] {
+ position: relative;
+ overflow: hidden;
+ border-radius: 0.5rem;
+ aspect-ratio: 16/9;
+ line-height: 0;
+}
+.mv-list .mv-item-img:hover img[data-v-7366dc5a] {
+ -o-object-position: top;
+ object-position: top;
+ transition-property: all;
+ transition-duration: 300ms;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+}
+.mv-list .mv-item-img:hover img[data-v-7366dc5a]:hover {
+ --tw-scale-x: 1.1;
+ --tw-scale-y: 1.1;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+}
+.mv-list .mv-item-img-img[data-v-7366dc5a] {
+ height: 100%;
+ width: 100%;
+ overflow: hidden;
+ border-radius: 0.5rem;
+ -o-object-fit: cover;
+ object-fit: cover;
+}
+.mv-list .mv-item-img .top[data-v-7366dc5a] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ display: flex;
+ height: 100%;
+ width: 100%;
+ cursor: pointer;
+ align-items: center;
+ justify-content: center;
+ transition-property: all;
+ transition-duration: 300ms;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.6;
+ opacity: 0;
+}
+.mv-list .mv-item-img .top i[data-v-7366dc5a] {
+ font-size: 2.25rem;
+ line-height: 2.5rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.mv-list .mv-item-img .top .play-count[data-v-7366dc5a] {
+ position: absolute;
+ top: 0.5rem;
+ right: 0.5rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ --tw-text-opacity: 0.9;
+}
+.mv-list .mv-item-img .top[data-v-7366dc5a]:hover {
+ opacity: 1;
+}
+.mv-list .mv-item-title[data-v-7366dc5a] {
+ margin-top: 0.5rem;
+ overflow: hidden;
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 1;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1));
+}
+.mv-list .mv-item-title[data-v-7366dc5a]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+}
+.loading-more[data-v-7366dc5a] {
+ grid-column: 1 / -1;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ text-align: center;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.loading-more[data-v-7366dc5a]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
+.no-more[data-v-7366dc5a] {
+ grid-column: 1 / -1;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ text-align: center;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1));
+}
+.no-more[data-v-7366dc5a]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1));
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-b8HibJP6.css.gz b/out/renderer/assets/index-b8HibJP6.css.gz
new file mode 100644
index 0000000..1099eaa
Binary files /dev/null and b/out/renderer/assets/index-b8HibJP6.css.gz differ
diff --git a/out/renderer/assets/index-s6QFASec.css b/out/renderer/assets/index-s6QFASec.css
new file mode 100644
index 0000000..edc79b7
--- /dev/null
+++ b/out/renderer/assets/index-s6QFASec.css
@@ -0,0 +1,228 @@
+.list-page[data-v-f9f1189c] {
+ position: relative;
+ height: 100%;
+ width: 100%;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1))
+}.list-page[data-v-f9f1189c]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1))
+}
+.recommend[data-v-f9f1189c] {
+ height: 100%;
+ width: 100%
+}
+.recommend-title[data-v-f9f1189c] {
+ padding-bottom: 0.5rem;
+ font-size: 1.125rem;
+ line-height: 1.75rem;
+ font-weight: 700;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.recommend-title[data-v-f9f1189c]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.recommend-list[data-v-f9f1189c] {
+ display: grid;
+ -moz-column-gap: 2rem;
+ column-gap: 2rem;
+ row-gap: 1.5rem;
+ padding-bottom: 7rem;
+ padding-right: 1rem;
+ grid-template-columns: repeat(auto-fill, minmax(150px, 1fr))
+}
+.recommend-item[data-v-f9f1189c] {
+ display: flex;
+ flex-direction: column
+}
+.recommend-item-img[data-v-f9f1189c] {
+ position: relative;
+ aspect-ratio: 1 / 1;
+ width: 100%;
+ overflow: hidden;
+ border-radius: 0.75rem
+}
+.recommend-item-img-img[data-v-f9f1189c] {
+ display: block;
+ height: 100%;
+ width: 100%
+}
+.recommend-item-img img[data-v-f9f1189c] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ height: 100%;
+ width: 100%;
+ border-radius: 0.75rem;
+ -o-object-fit: cover;
+ object-fit: cover
+}
+.recommend-item-img:hover img[data-v-f9f1189c] {
+ transition-property: all;
+ transition-duration: 300ms;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1)
+}
+.recommend-item-img:hover img[data-v-f9f1189c]:hover {
+ --tw-scale-x: 1.1;
+ --tw-scale-y: 1.1;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))
+}
+.recommend-item-img .top[data-v-f9f1189c] {
+ position: absolute;
+ top: 0px;
+ left: 0px;
+ display: flex;
+ height: 100%;
+ width: 100%;
+ cursor: pointer;
+ align-items: center;
+ justify-content: center;
+ transition-property: all;
+ transition-duration: 300ms;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-bg-opacity: 0.5;
+ opacity: 0
+}
+.recommend-item-img .top i[data-v-f9f1189c] {
+ font-size: 3rem;
+ line-height: 1;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1));
+ opacity: 0;
+ transition-property: all;
+ transition-duration: 500ms;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1)
+}
+.recommend-item-img .top[data-v-f9f1189c]:hover {
+ opacity: 1
+}
+.recommend-item-img .top:hover i[data-v-f9f1189c] {
+ --tw-scale-x: 1.5;
+ --tw-scale-y: 1.5;
+ transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
+ opacity: 1
+}
+.recommend-item-img .top .play-count[data-v-f9f1189c] {
+ position: absolute;
+ top: 0.5rem;
+ left: 0.5rem;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.recommend-item-title[data-v-f9f1189c] {
+ margin-top: 0.5rem;
+ overflow: hidden;
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 1;
+ font-size: 0.875rem;
+ line-height: 1.25rem;
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.recommend-item-title[data-v-f9f1189c]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.loading-more[data-v-f9f1189c] {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.loading-more[data-v-f9f1189c]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.no-more[data-v-f9f1189c] {
+ padding-top: 1rem;
+ padding-bottom: 1rem;
+ text-align: center;
+ --tw-text-opacity: 1;
+ color: rgb(107 114 128 / var(--tw-text-opacity, 1))
+}
+.no-more[data-v-f9f1189c]:is(.dark *) {
+ --tw-text-opacity: 1;
+ color: rgb(156 163 175 / var(--tw-text-opacity, 1))
+}
+.mobile .recommend-title[data-v-f9f1189c] {
+ padding-left: 1rem;
+ padding-right: 1rem;
+ font-size: 1.25rem;
+ line-height: 1.75rem;
+ font-weight: 700
+}
+.mobile .recommend-list[data-v-f9f1189c] {
+ gap: 1rem;
+ padding-left: 1rem;
+ padding-right: 1rem;
+ grid-template-columns: repeat(auto-fill, minmax(150px, 1fr))
+}
+.play-list-type .categories-wrapper[data-v-f9f1189c] {
+ display: flex;
+ align-items: center;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ white-space: nowrap
+}
+.play-list-type-item[data-v-f9f1189c] {
+ margin-right: 0.75rem;
+ display: inline-block;
+ cursor: pointer;
+ border-radius: 0.75rem;
+ padding-top: 0.5rem;
+ padding-bottom: 0.5rem;
+ padding-left: 0.75rem;
+ padding-right: 0.75rem;
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+ --tw-bg-opacity: 1;
+ background-color: rgb(255 255 255 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(17 24 39 / var(--tw-text-opacity, 1))
+}
+.play-list-type-item[data-v-f9f1189c]:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(0 0 0 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.play-list-type-item[data-v-f9f1189c] {
+ border-width: 1px;
+ --tw-border-opacity: 1;
+ border-color: rgb(229 231 235 / var(--tw-border-opacity, 1))
+}
+.play-list-type-item[data-v-f9f1189c]:is(.dark *) {
+ --tw-border-opacity: 1;
+ border-color: rgb(55 65 81 / var(--tw-border-opacity, 1))
+}
+.play-list-type-item[data-v-f9f1189c]:hover {
+ --tw-bg-opacity: 1;
+ background-color: rgb(240 253 244 / var(--tw-bg-opacity, 1))
+}
+.play-list-type-item[data-v-f9f1189c]:hover:is(.dark *) {
+ --tw-bg-opacity: 1;
+ background-color: rgb(20 83 45 / var(--tw-bg-opacity, 1))
+}
+.play-list-type-item.active[data-v-f9f1189c] {
+ --tw-border-opacity: 1;
+ border-color: rgb(34 197 94 / var(--tw-border-opacity, 1));
+ --tw-bg-opacity: 1;
+ background-color: rgb(34 197 94 / var(--tw-bg-opacity, 1));
+ --tw-text-opacity: 1;
+ color: rgb(255 255 255 / var(--tw-text-opacity, 1))
+}
+.mobile .play-list-type[data-v-f9f1189c] {
+ margin-left: 0px;
+ margin-right: 0px;
+ width: 100%
+}
\ No newline at end of file
diff --git a/out/renderer/assets/index-s6QFASec.css.gz b/out/renderer/assets/index-s6QFASec.css.gz
new file mode 100644
index 0000000..c32b54c
Binary files /dev/null and b/out/renderer/assets/index-s6QFASec.css.gz differ
diff --git a/out/renderer/assets/login-BsPxQYi6.js b/out/renderer/assets/login-BsPxQYi6.js
new file mode 100644
index 0000000..c9341fa
--- /dev/null
+++ b/out/renderer/assets/login-BsPxQYi6.js
@@ -0,0 +1,38 @@
+import { as as inject, bi as throwError, bj as messageApiInjectionKey, ad as request } from "./index-DKaFsuse.js";
+function useMessage() {
+ const api = inject(messageApiInjectionKey, null);
+ if (api === null) {
+ throwError("use-message", "No outer founded. See prerequisite in https://www.naiveui.com/en-US/os-theme/components/message for more details. If you want to use `useMessage` outside setup, please check https://www.naiveui.com/zh-CN/os-theme/components/message#Q-&-A.");
+ }
+ return api;
+}
+function getQrKey() {
+ return request.get("/login/qr/key");
+}
+function createQr(key) {
+ return request.get("/login/qr/create", { params: { key, qrimg: true } });
+}
+function checkQr(key) {
+ return request.get("/login/qr/check", { params: { key } });
+}
+function getUserDetail() {
+ return request.get("/user/account");
+}
+function logout() {
+ return request.get("/logout");
+}
+function loginByCellphone(phone, password) {
+ return request.post("/login/cellphone", {
+ phone,
+ password
+ });
+}
+export {
+ checkQr as a,
+ getUserDetail as b,
+ createQr as c,
+ logout as d,
+ getQrKey as g,
+ loginByCellphone as l,
+ useMessage as u
+};
diff --git a/out/renderer/assets/login-BsPxQYi6.js.gz b/out/renderer/assets/login-BsPxQYi6.js.gz
new file mode 100644
index 0000000..dda92be
Binary files /dev/null and b/out/renderer/assets/login-BsPxQYi6.js.gz differ
diff --git a/out/renderer/assets/remixicon-BBpe-Xu7.woff b/out/renderer/assets/remixicon-BBpe-Xu7.woff
new file mode 100644
index 0000000..3195768
Binary files /dev/null and b/out/renderer/assets/remixicon-BBpe-Xu7.woff differ
diff --git a/out/renderer/assets/remixicon-BVJ9S1ev.eot b/out/renderer/assets/remixicon-BVJ9S1ev.eot
new file mode 100644
index 0000000..acd1589
Binary files /dev/null and b/out/renderer/assets/remixicon-BVJ9S1ev.eot differ
diff --git a/out/renderer/assets/remixicon-BVvFtaex.woff2 b/out/renderer/assets/remixicon-BVvFtaex.woff2
new file mode 100644
index 0000000..c6c8031
Binary files /dev/null and b/out/renderer/assets/remixicon-BVvFtaex.woff2 differ
diff --git a/out/renderer/assets/remixicon-C2wQ2gtc.svg b/out/renderer/assets/remixicon-C2wQ2gtc.svg
new file mode 100644
index 0000000..6e37973
--- /dev/null
+++ b/out/renderer/assets/remixicon-C2wQ2gtc.svg
@@ -0,0 +1,9196 @@
+
+
+
+
diff --git a/out/renderer/assets/remixicon-CfJD46dY.ttf b/out/renderer/assets/remixicon-CfJD46dY.ttf
new file mode 100644
index 0000000..1373ccd
Binary files /dev/null and b/out/renderer/assets/remixicon-CfJD46dY.ttf differ
diff --git a/out/renderer/assets/use-locale-DLWAOXez.js b/out/renderer/assets/use-locale-DLWAOXez.js
new file mode 100644
index 0000000..648f698
--- /dev/null
+++ b/out/renderer/assets/use-locale-DLWAOXez.js
@@ -0,0 +1,1476 @@
+import { o as onMounted, a as onBeforeUnmount, c9 as isBrowser, aL as createInjectionKey, as as inject, aZ as modalBodyInjectionKey, aX as drawerBodyInjectionKey, aY as popoverBodyInjectionKey, r as ref, J as on, aS as off, D as useMemo, d as defineComponent, $ as provide, br as getCurrentInstance, ca as getSlot, w as withDirectives, cb as getFirstVNode, cc as CssRender, at as useSsrAdapter, E as watch, A as toRef, aR as isMounted, l as h, b4 as zindexable, b1 as LazyTeleport, M as nextTick, cd as configProviderInjectionKey, G as computed } from "./index-DKaFsuse.js";
+let onceCbs = [];
+const paramsMap = /* @__PURE__ */ new WeakMap();
+function flushOnceCallbacks() {
+ onceCbs.forEach((cb) => cb(...paramsMap.get(cb)));
+ onceCbs = [];
+}
+function beforeNextFrameOnce(cb, ...params) {
+ paramsMap.set(cb, params);
+ if (onceCbs.includes(cb))
+ return;
+ onceCbs.push(cb) === 1 && requestAnimationFrame(flushOnceCallbacks);
+}
+let fontsReady;
+let isFontReady;
+const init = () => {
+ var _a, _b;
+ fontsReady = isBrowser ? (_b = (_a = document) === null || _a === void 0 ? void 0 : _a.fonts) === null || _b === void 0 ? void 0 : _b.ready : void 0;
+ isFontReady = false;
+ if (fontsReady !== void 0) {
+ void fontsReady.then(() => {
+ isFontReady = true;
+ });
+ } else {
+ isFontReady = true;
+ }
+};
+init();
+function onFontsReady(cb) {
+ if (isFontReady)
+ return;
+ let deactivated = false;
+ onMounted(() => {
+ if (!isFontReady) {
+ fontsReady === null || fontsReady === void 0 ? void 0 : fontsReady.then(() => {
+ if (deactivated)
+ return;
+ cb();
+ });
+ }
+ });
+ onBeforeUnmount(() => {
+ deactivated = true;
+ });
+}
+const internalSelectionMenuBodyInjectionKey = createInjectionKey("n-internal-select-menu-body");
+const teleportDisabled = "__disabled__";
+function useAdjustedTo(props) {
+ const modal = inject(modalBodyInjectionKey, null);
+ const drawer = inject(drawerBodyInjectionKey, null);
+ const popover = inject(popoverBodyInjectionKey, null);
+ const selectMenu = inject(internalSelectionMenuBodyInjectionKey, null);
+ const fullscreenElementRef = ref();
+ if (typeof document !== "undefined") {
+ fullscreenElementRef.value = document.fullscreenElement;
+ const handleFullscreenChange = () => {
+ fullscreenElementRef.value = document.fullscreenElement;
+ };
+ onMounted(() => {
+ on("fullscreenchange", document, handleFullscreenChange);
+ });
+ onBeforeUnmount(() => {
+ off("fullscreenchange", document, handleFullscreenChange);
+ });
+ }
+ return useMemo(() => {
+ var _a;
+ const {
+ to
+ } = props;
+ if (to !== void 0) {
+ if (to === false) return teleportDisabled;
+ if (to === true) return fullscreenElementRef.value || "body";
+ return to;
+ }
+ if (modal === null || modal === void 0 ? void 0 : modal.value) {
+ return (_a = modal.value.$el) !== null && _a !== void 0 ? _a : modal.value;
+ }
+ if (drawer === null || drawer === void 0 ? void 0 : drawer.value) return drawer.value;
+ if (popover === null || popover === void 0 ? void 0 : popover.value) return popover.value;
+ if (selectMenu === null || selectMenu === void 0 ? void 0 : selectMenu.value) return selectMenu.value;
+ return to !== null && to !== void 0 ? to : fullscreenElementRef.value || "body";
+ });
+}
+useAdjustedTo.tdkey = teleportDisabled;
+useAdjustedTo.propTo = {
+ type: [String, Object, Boolean],
+ default: void 0
+};
+let viewMeasurer = null;
+function ensureViewBoundingRect() {
+ if (viewMeasurer === null) {
+ viewMeasurer = document.getElementById("v-binder-view-measurer");
+ if (viewMeasurer === null) {
+ viewMeasurer = document.createElement("div");
+ viewMeasurer.id = "v-binder-view-measurer";
+ const { style: style2 } = viewMeasurer;
+ style2.position = "fixed";
+ style2.left = "0";
+ style2.right = "0";
+ style2.top = "0";
+ style2.bottom = "0";
+ style2.pointerEvents = "none";
+ style2.visibility = "hidden";
+ document.body.appendChild(viewMeasurer);
+ }
+ }
+ return viewMeasurer.getBoundingClientRect();
+}
+function getPointRect(x, y) {
+ const viewRect = ensureViewBoundingRect();
+ return {
+ top: y,
+ left: x,
+ height: 0,
+ width: 0,
+ right: viewRect.width - x,
+ bottom: viewRect.height - y
+ };
+}
+function getRect(el) {
+ const elRect = el.getBoundingClientRect();
+ const viewRect = ensureViewBoundingRect();
+ return {
+ left: elRect.left - viewRect.left,
+ top: elRect.top - viewRect.top,
+ bottom: viewRect.height + viewRect.top - elRect.bottom,
+ right: viewRect.width + viewRect.left - elRect.right,
+ width: elRect.width,
+ height: elRect.height
+ };
+}
+function getParentNode(node) {
+ if (node.nodeType === 9) {
+ return null;
+ }
+ return node.parentNode;
+}
+function getScrollParent(node) {
+ if (node === null)
+ return null;
+ const parentNode = getParentNode(node);
+ if (parentNode === null) {
+ return null;
+ }
+ if (parentNode.nodeType === 9) {
+ return document;
+ }
+ if (parentNode.nodeType === 1) {
+ const { overflow, overflowX, overflowY } = getComputedStyle(parentNode);
+ if (/(auto|scroll|overlay)/.test(overflow + overflowY + overflowX)) {
+ return parentNode;
+ }
+ }
+ return getScrollParent(parentNode);
+}
+const Binder = defineComponent({
+ name: "Binder",
+ props: {
+ syncTargetWithParent: Boolean,
+ syncTarget: {
+ type: Boolean,
+ default: true
+ }
+ },
+ setup(props) {
+ var _a;
+ provide("VBinder", (_a = getCurrentInstance()) === null || _a === void 0 ? void 0 : _a.proxy);
+ const VBinder = inject("VBinder", null);
+ const targetRef = ref(null);
+ const setTargetRef = (el) => {
+ targetRef.value = el;
+ if (VBinder && props.syncTargetWithParent) {
+ VBinder.setTargetRef(el);
+ }
+ };
+ let scrollableNodes = [];
+ const ensureScrollListener = () => {
+ let cursor = targetRef.value;
+ while (true) {
+ cursor = getScrollParent(cursor);
+ if (cursor === null)
+ break;
+ scrollableNodes.push(cursor);
+ }
+ for (const el of scrollableNodes) {
+ on("scroll", el, onScroll, true);
+ }
+ };
+ const removeScrollListeners = () => {
+ for (const el of scrollableNodes) {
+ off("scroll", el, onScroll, true);
+ }
+ scrollableNodes = [];
+ };
+ const followerScrollListeners = /* @__PURE__ */ new Set();
+ const addScrollListener = (listener) => {
+ if (followerScrollListeners.size === 0) {
+ ensureScrollListener();
+ }
+ if (!followerScrollListeners.has(listener)) {
+ followerScrollListeners.add(listener);
+ }
+ };
+ const removeScrollListener = (listener) => {
+ if (followerScrollListeners.has(listener)) {
+ followerScrollListeners.delete(listener);
+ }
+ if (followerScrollListeners.size === 0) {
+ removeScrollListeners();
+ }
+ };
+ const onScroll = () => {
+ beforeNextFrameOnce(onScrollRaf);
+ };
+ const onScrollRaf = () => {
+ followerScrollListeners.forEach((listener) => listener());
+ };
+ const followerResizeListeners = /* @__PURE__ */ new Set();
+ const addResizeListener = (listener) => {
+ if (followerResizeListeners.size === 0) {
+ on("resize", window, onResize);
+ }
+ if (!followerResizeListeners.has(listener)) {
+ followerResizeListeners.add(listener);
+ }
+ };
+ const removeResizeListener = (listener) => {
+ if (followerResizeListeners.has(listener)) {
+ followerResizeListeners.delete(listener);
+ }
+ if (followerResizeListeners.size === 0) {
+ off("resize", window, onResize);
+ }
+ };
+ const onResize = () => {
+ followerResizeListeners.forEach((listener) => listener());
+ };
+ onBeforeUnmount(() => {
+ off("resize", window, onResize);
+ removeScrollListeners();
+ });
+ return {
+ targetRef,
+ setTargetRef,
+ addScrollListener,
+ removeScrollListener,
+ addResizeListener,
+ removeResizeListener
+ };
+ },
+ render() {
+ return getSlot("binder", this.$slots);
+ }
+});
+const VTarget = defineComponent({
+ name: "Target",
+ setup() {
+ const { setTargetRef, syncTarget } = inject("VBinder");
+ const setTargetDirective = {
+ mounted: setTargetRef,
+ updated: setTargetRef
+ };
+ return {
+ syncTarget,
+ setTargetDirective
+ };
+ },
+ render() {
+ const { syncTarget, setTargetDirective } = this;
+ if (syncTarget) {
+ return withDirectives(getFirstVNode("follower", this.$slots), [
+ [setTargetDirective]
+ ]);
+ }
+ return getFirstVNode("follower", this.$slots);
+ }
+});
+const { c } = CssRender();
+const cssrAnchorMetaName = "vueuc-style";
+const oppositionPositions = {
+ top: "bottom",
+ bottom: "top",
+ left: "right",
+ right: "left"
+};
+const oppositeAligns = {
+ start: "end",
+ center: "center",
+ end: "start"
+};
+const propToCompare = {
+ top: "height",
+ bottom: "height",
+ left: "width",
+ right: "width"
+};
+const transformOrigins = {
+ "bottom-start": "top left",
+ bottom: "top center",
+ "bottom-end": "top right",
+ "top-start": "bottom left",
+ top: "bottom center",
+ "top-end": "bottom right",
+ "right-start": "top left",
+ right: "center left",
+ "right-end": "bottom left",
+ "left-start": "top right",
+ left: "center right",
+ "left-end": "bottom right"
+};
+const overlapTransformOrigin = {
+ "bottom-start": "bottom left",
+ bottom: "bottom center",
+ "bottom-end": "bottom right",
+ "top-start": "top left",
+ top: "top center",
+ "top-end": "top right",
+ "right-start": "top right",
+ right: "center right",
+ "right-end": "bottom right",
+ "left-start": "top left",
+ left: "center left",
+ "left-end": "bottom left"
+};
+const oppositeAlignCssPositionProps = {
+ "bottom-start": "right",
+ "bottom-end": "left",
+ "top-start": "right",
+ "top-end": "left",
+ "right-start": "bottom",
+ "right-end": "top",
+ "left-start": "bottom",
+ "left-end": "top"
+};
+const keepOffsetDirection = {
+ top: true,
+ bottom: false,
+ left: true,
+ right: false
+ // left--
+};
+const cssPositionToOppositeAlign = {
+ top: "end",
+ bottom: "start",
+ left: "end",
+ right: "start"
+};
+function getPlacementAndOffsetOfFollower(placement, targetRect, followerRect, shift, flip, overlap) {
+ if (!flip || overlap) {
+ return { placement, top: 0, left: 0 };
+ }
+ const [position, align] = placement.split("-");
+ let properAlign = align !== null && align !== void 0 ? align : "center";
+ let properOffset = {
+ top: 0,
+ left: 0
+ };
+ const deriveOffset = (oppositeAlignCssSizeProp, alignCssPositionProp, offsetVertically2) => {
+ let left = 0;
+ let top = 0;
+ const diff = followerRect[oppositeAlignCssSizeProp] - targetRect[alignCssPositionProp] - targetRect[oppositeAlignCssSizeProp];
+ if (diff > 0 && shift) {
+ if (offsetVertically2) {
+ top = keepOffsetDirection[alignCssPositionProp] ? diff : -diff;
+ } else {
+ left = keepOffsetDirection[alignCssPositionProp] ? diff : -diff;
+ }
+ }
+ return {
+ left,
+ top
+ };
+ };
+ const offsetVertically = position === "left" || position === "right";
+ if (properAlign !== "center") {
+ const oppositeAlignCssPositionProp = oppositeAlignCssPositionProps[placement];
+ const currentAlignCssPositionProp = oppositionPositions[oppositeAlignCssPositionProp];
+ const oppositeAlignCssSizeProp = propToCompare[oppositeAlignCssPositionProp];
+ if (followerRect[oppositeAlignCssSizeProp] > targetRect[oppositeAlignCssSizeProp]) {
+ if (
+ // current space is not enough
+ // ----------[ target ]---------|
+ // -------[ follower ]
+ targetRect[oppositeAlignCssPositionProp] + targetRect[oppositeAlignCssSizeProp] < followerRect[oppositeAlignCssSizeProp]
+ ) {
+ const followerOverTargetSize = (followerRect[oppositeAlignCssSizeProp] - targetRect[oppositeAlignCssSizeProp]) / 2;
+ if (targetRect[oppositeAlignCssPositionProp] < followerOverTargetSize || targetRect[currentAlignCssPositionProp] < followerOverTargetSize) {
+ if (targetRect[oppositeAlignCssPositionProp] < targetRect[currentAlignCssPositionProp]) {
+ properAlign = oppositeAligns[align];
+ properOffset = deriveOffset(oppositeAlignCssSizeProp, currentAlignCssPositionProp, offsetVertically);
+ } else {
+ properOffset = deriveOffset(oppositeAlignCssSizeProp, oppositeAlignCssPositionProp, offsetVertically);
+ }
+ } else {
+ properAlign = "center";
+ }
+ }
+ } else if (followerRect[oppositeAlignCssSizeProp] < targetRect[oppositeAlignCssSizeProp]) {
+ if (targetRect[currentAlignCssPositionProp] < 0 && // opposite align has larger space
+ // ------------[ target ]
+ // ----------------[follower]
+ targetRect[oppositeAlignCssPositionProp] > targetRect[currentAlignCssPositionProp]) {
+ properAlign = oppositeAligns[align];
+ }
+ }
+ } else {
+ const possibleAlternativeAlignCssPositionProp1 = position === "bottom" || position === "top" ? "left" : "top";
+ const possibleAlternativeAlignCssPositionProp2 = oppositionPositions[possibleAlternativeAlignCssPositionProp1];
+ const alternativeAlignCssSizeProp = propToCompare[possibleAlternativeAlignCssPositionProp1];
+ const followerOverTargetSize = (followerRect[alternativeAlignCssSizeProp] - targetRect[alternativeAlignCssSizeProp]) / 2;
+ if (
+ // center is not enough
+ // ----------- [ target ]--|
+ // -------[ follower ]
+ targetRect[possibleAlternativeAlignCssPositionProp1] < followerOverTargetSize || targetRect[possibleAlternativeAlignCssPositionProp2] < followerOverTargetSize
+ ) {
+ if (targetRect[possibleAlternativeAlignCssPositionProp1] > targetRect[possibleAlternativeAlignCssPositionProp2]) {
+ properAlign = cssPositionToOppositeAlign[possibleAlternativeAlignCssPositionProp1];
+ properOffset = deriveOffset(alternativeAlignCssSizeProp, possibleAlternativeAlignCssPositionProp1, offsetVertically);
+ } else {
+ properAlign = cssPositionToOppositeAlign[possibleAlternativeAlignCssPositionProp2];
+ properOffset = deriveOffset(alternativeAlignCssSizeProp, possibleAlternativeAlignCssPositionProp2, offsetVertically);
+ }
+ }
+ }
+ let properPosition = position;
+ if (
+ // space is not enough
+ targetRect[position] < followerRect[propToCompare[position]] && // opposite position's space is larger
+ targetRect[position] < targetRect[oppositionPositions[position]]
+ ) {
+ properPosition = oppositionPositions[position];
+ }
+ return {
+ placement: properAlign !== "center" ? `${properPosition}-${properAlign}` : properPosition,
+ left: properOffset.left,
+ top: properOffset.top
+ };
+}
+function getProperTransformOrigin(placement, overlap) {
+ if (overlap)
+ return overlapTransformOrigin[placement];
+ return transformOrigins[placement];
+}
+function getOffset(placement, offsetRect, targetRect, offsetTopToStandardPlacement, offsetLeftToStandardPlacement, overlap) {
+ if (overlap) {
+ switch (placement) {
+ case "bottom-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left)}px`,
+ transform: "translateY(-100%)"
+ };
+ case "bottom-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width)}px`,
+ transform: "translateX(-100%) translateY(-100%)"
+ };
+ case "top-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left)}px`,
+ transform: ""
+ };
+ case "top-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width)}px`,
+ transform: "translateX(-100%)"
+ };
+ case "right-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width)}px`,
+ transform: "translateX(-100%)"
+ };
+ case "right-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width)}px`,
+ transform: "translateX(-100%) translateY(-100%)"
+ };
+ case "left-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left)}px`,
+ transform: ""
+ };
+ case "left-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left)}px`,
+ transform: "translateY(-100%)"
+ };
+ case "top":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width / 2)}px`,
+ transform: "translateX(-50%)"
+ };
+ case "right":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height / 2)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width)}px`,
+ transform: "translateX(-100%) translateY(-50%)"
+ };
+ case "left":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height / 2)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left)}px`,
+ transform: "translateY(-50%)"
+ };
+ case "bottom":
+ default:
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width / 2)}px`,
+ transform: "translateX(-50%) translateY(-100%)"
+ };
+ }
+ }
+ switch (placement) {
+ case "bottom-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + offsetLeftToStandardPlacement)}px`,
+ transform: ""
+ };
+ case "bottom-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width + offsetLeftToStandardPlacement)}px`,
+ transform: "translateX(-100%)"
+ };
+ case "top-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + offsetLeftToStandardPlacement)}px`,
+ transform: "translateY(-100%)"
+ };
+ case "top-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width + offsetLeftToStandardPlacement)}px`,
+ transform: "translateX(-100%) translateY(-100%)"
+ };
+ case "right-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width + offsetLeftToStandardPlacement)}px`,
+ transform: ""
+ };
+ case "right-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width + offsetLeftToStandardPlacement)}px`,
+ transform: "translateY(-100%)"
+ };
+ case "left-start":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + offsetLeftToStandardPlacement)}px`,
+ transform: "translateX(-100%)"
+ };
+ case "left-end":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + offsetLeftToStandardPlacement)}px`,
+ transform: "translateX(-100%) translateY(-100%)"
+ };
+ case "top":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width / 2 + offsetLeftToStandardPlacement)}px`,
+ transform: "translateY(-100%) translateX(-50%)"
+ };
+ case "right":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height / 2 + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width + offsetLeftToStandardPlacement)}px`,
+ transform: "translateY(-50%)"
+ };
+ case "left":
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height / 2 + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + offsetLeftToStandardPlacement)}px`,
+ transform: "translateY(-50%) translateX(-100%)"
+ };
+ case "bottom":
+ default:
+ return {
+ top: `${Math.round(targetRect.top - offsetRect.top + targetRect.height + offsetTopToStandardPlacement)}px`,
+ left: `${Math.round(targetRect.left - offsetRect.left + targetRect.width / 2 + offsetLeftToStandardPlacement)}px`,
+ transform: "translateX(-50%)"
+ };
+ }
+}
+const style = c([
+ c(".v-binder-follower-container", {
+ position: "absolute",
+ left: "0",
+ right: "0",
+ top: "0",
+ height: "0",
+ pointerEvents: "none",
+ zIndex: "auto"
+ }),
+ c(".v-binder-follower-content", {
+ position: "absolute",
+ zIndex: "auto"
+ }, [
+ c("> *", {
+ pointerEvents: "all"
+ })
+ ])
+]);
+const VFollower = defineComponent({
+ name: "Follower",
+ inheritAttrs: false,
+ props: {
+ show: Boolean,
+ enabled: {
+ type: Boolean,
+ default: void 0
+ },
+ placement: {
+ type: String,
+ default: "bottom"
+ },
+ syncTrigger: {
+ type: Array,
+ default: ["resize", "scroll"]
+ },
+ to: [String, Object],
+ flip: {
+ type: Boolean,
+ default: true
+ },
+ internalShift: Boolean,
+ x: Number,
+ y: Number,
+ width: String,
+ minWidth: String,
+ containerClass: String,
+ teleportDisabled: Boolean,
+ zindexable: {
+ type: Boolean,
+ default: true
+ },
+ zIndex: Number,
+ overlap: Boolean
+ },
+ setup(props) {
+ const VBinder = inject("VBinder");
+ const mergedEnabledRef = useMemo(() => {
+ return props.enabled !== void 0 ? props.enabled : props.show;
+ });
+ const followerRef = ref(null);
+ const offsetContainerRef = ref(null);
+ const ensureListeners = () => {
+ const { syncTrigger } = props;
+ if (syncTrigger.includes("scroll")) {
+ VBinder.addScrollListener(syncPosition);
+ }
+ if (syncTrigger.includes("resize")) {
+ VBinder.addResizeListener(syncPosition);
+ }
+ };
+ const removeListeners = () => {
+ VBinder.removeScrollListener(syncPosition);
+ VBinder.removeResizeListener(syncPosition);
+ };
+ onMounted(() => {
+ if (mergedEnabledRef.value) {
+ syncPosition();
+ ensureListeners();
+ }
+ });
+ const ssrAdapter = useSsrAdapter();
+ style.mount({
+ id: "vueuc/binder",
+ head: true,
+ anchorMetaName: cssrAnchorMetaName,
+ ssr: ssrAdapter
+ });
+ onBeforeUnmount(() => {
+ removeListeners();
+ });
+ onFontsReady(() => {
+ if (mergedEnabledRef.value) {
+ syncPosition();
+ }
+ });
+ const syncPosition = () => {
+ if (!mergedEnabledRef.value) {
+ return;
+ }
+ const follower = followerRef.value;
+ if (follower === null)
+ return;
+ const target = VBinder.targetRef;
+ const { x, y, overlap } = props;
+ const targetRect = x !== void 0 && y !== void 0 ? getPointRect(x, y) : getRect(target);
+ follower.style.setProperty("--v-target-width", `${Math.round(targetRect.width)}px`);
+ follower.style.setProperty("--v-target-height", `${Math.round(targetRect.height)}px`);
+ const { width, minWidth, placement, internalShift, flip } = props;
+ follower.setAttribute("v-placement", placement);
+ if (overlap) {
+ follower.setAttribute("v-overlap", "");
+ } else {
+ follower.removeAttribute("v-overlap");
+ }
+ const { style: style2 } = follower;
+ if (width === "target") {
+ style2.width = `${targetRect.width}px`;
+ } else if (width !== void 0) {
+ style2.width = width;
+ } else {
+ style2.width = "";
+ }
+ if (minWidth === "target") {
+ style2.minWidth = `${targetRect.width}px`;
+ } else if (minWidth !== void 0) {
+ style2.minWidth = minWidth;
+ } else {
+ style2.minWidth = "";
+ }
+ const followerRect = getRect(follower);
+ const offsetContainerRect = getRect(offsetContainerRef.value);
+ const { left: offsetLeftToStandardPlacement, top: offsetTopToStandardPlacement, placement: properPlacement } = getPlacementAndOffsetOfFollower(placement, targetRect, followerRect, internalShift, flip, overlap);
+ const properTransformOrigin = getProperTransformOrigin(properPlacement, overlap);
+ const { left, top, transform } = getOffset(properPlacement, offsetContainerRect, targetRect, offsetTopToStandardPlacement, offsetLeftToStandardPlacement, overlap);
+ follower.setAttribute("v-placement", properPlacement);
+ follower.style.setProperty("--v-offset-left", `${Math.round(offsetLeftToStandardPlacement)}px`);
+ follower.style.setProperty("--v-offset-top", `${Math.round(offsetTopToStandardPlacement)}px`);
+ follower.style.transform = `translateX(${left}) translateY(${top}) ${transform}`;
+ follower.style.setProperty("--v-transform-origin", properTransformOrigin);
+ follower.style.transformOrigin = properTransformOrigin;
+ };
+ watch(mergedEnabledRef, (value) => {
+ if (value) {
+ ensureListeners();
+ syncOnNextTick();
+ } else {
+ removeListeners();
+ }
+ });
+ const syncOnNextTick = () => {
+ nextTick().then(syncPosition).catch((e) => console.error(e));
+ };
+ [
+ "placement",
+ "x",
+ "y",
+ "internalShift",
+ "flip",
+ "width",
+ "overlap",
+ "minWidth"
+ ].forEach((prop) => {
+ watch(toRef(props, prop), syncPosition);
+ });
+ ["teleportDisabled"].forEach((prop) => {
+ watch(toRef(props, prop), syncOnNextTick);
+ });
+ watch(toRef(props, "syncTrigger"), (value) => {
+ if (!value.includes("resize")) {
+ VBinder.removeResizeListener(syncPosition);
+ } else {
+ VBinder.addResizeListener(syncPosition);
+ }
+ if (!value.includes("scroll")) {
+ VBinder.removeScrollListener(syncPosition);
+ } else {
+ VBinder.addScrollListener(syncPosition);
+ }
+ });
+ const isMountedRef = isMounted();
+ const mergedToRef = useMemo(() => {
+ const { to } = props;
+ if (to !== void 0)
+ return to;
+ if (isMountedRef.value) {
+ return void 0;
+ }
+ return void 0;
+ });
+ return {
+ VBinder,
+ mergedEnabled: mergedEnabledRef,
+ offsetContainerRef,
+ followerRef,
+ mergedTo: mergedToRef,
+ syncPosition
+ };
+ },
+ render() {
+ return h(LazyTeleport, {
+ show: this.show,
+ to: this.mergedTo,
+ disabled: this.teleportDisabled
+ }, {
+ default: () => {
+ var _a, _b;
+ const vNode = h("div", {
+ class: ["v-binder-follower-container", this.containerClass],
+ ref: "offsetContainerRef"
+ }, [
+ h("div", {
+ class: "v-binder-follower-content",
+ ref: "followerRef"
+ }, (_b = (_a = this.$slots).default) === null || _b === void 0 ? void 0 : _b.call(_a))
+ ]);
+ if (this.zindexable) {
+ return withDirectives(vNode, [
+ [
+ zindexable,
+ {
+ enabled: this.mergedEnabled,
+ zIndex: this.zIndex
+ }
+ ]
+ ]);
+ }
+ return vNode;
+ }
+ });
+ }
+});
+const enUS$1 = {
+ name: "en-US",
+ global: {
+ undo: "Undo",
+ redo: "Redo",
+ confirm: "Confirm",
+ clear: "Clear"
+ },
+ Popconfirm: {
+ positiveText: "Confirm",
+ negativeText: "Cancel"
+ },
+ Cascader: {
+ placeholder: "Please Select",
+ loading: "Loading",
+ loadingRequiredMessage: (label) => `Please load all ${label}'s descendants before checking it.`
+ },
+ Time: {
+ dateFormat: "yyyy-MM-dd",
+ dateTimeFormat: "yyyy-MM-dd HH:mm:ss"
+ },
+ DatePicker: {
+ yearFormat: "yyyy",
+ monthFormat: "MMM",
+ dayFormat: "eeeeee",
+ yearTypeFormat: "yyyy",
+ monthTypeFormat: "yyyy-MM",
+ dateFormat: "yyyy-MM-dd",
+ dateTimeFormat: "yyyy-MM-dd HH:mm:ss",
+ quarterFormat: "yyyy-qqq",
+ weekFormat: "YYYY-w",
+ clear: "Clear",
+ now: "Now",
+ confirm: "Confirm",
+ selectTime: "Select Time",
+ selectDate: "Select Date",
+ datePlaceholder: "Select Date",
+ datetimePlaceholder: "Select Date and Time",
+ monthPlaceholder: "Select Month",
+ yearPlaceholder: "Select Year",
+ quarterPlaceholder: "Select Quarter",
+ weekPlaceholder: "Select Week",
+ startDatePlaceholder: "Start Date",
+ endDatePlaceholder: "End Date",
+ startDatetimePlaceholder: "Start Date and Time",
+ endDatetimePlaceholder: "End Date and Time",
+ startMonthPlaceholder: "Start Month",
+ endMonthPlaceholder: "End Month",
+ monthBeforeYear: true,
+ firstDayOfWeek: 6,
+ today: "Today"
+ },
+ DataTable: {
+ checkTableAll: "Select all in the table",
+ uncheckTableAll: "Unselect all in the table",
+ confirm: "Confirm",
+ clear: "Clear"
+ },
+ LegacyTransfer: {
+ sourceTitle: "Source",
+ targetTitle: "Target"
+ },
+ Transfer: {
+ selectAll: "Select all",
+ unselectAll: "Unselect all",
+ clearAll: "Clear",
+ total: (num) => `Total ${num} items`,
+ selected: (num) => `${num} items selected`
+ },
+ Empty: {
+ description: "No Data"
+ },
+ Select: {
+ placeholder: "Please Select"
+ },
+ TimePicker: {
+ placeholder: "Select Time",
+ positiveText: "OK",
+ negativeText: "Cancel",
+ now: "Now",
+ clear: "Clear"
+ },
+ Pagination: {
+ goto: "Goto",
+ selectionSuffix: "page"
+ },
+ DynamicTags: {
+ add: "Add"
+ },
+ Log: {
+ loading: "Loading"
+ },
+ Input: {
+ placeholder: "Please Input"
+ },
+ InputNumber: {
+ placeholder: "Please Input"
+ },
+ DynamicInput: {
+ create: "Create"
+ },
+ ThemeEditor: {
+ title: "Theme Editor",
+ clearAllVars: "Clear All Variables",
+ clearSearch: "Clear Search",
+ filterCompName: "Filter Component Name",
+ filterVarName: "Filter Variable Name",
+ import: "Import",
+ export: "Export",
+ restore: "Reset to Default"
+ },
+ Image: {
+ tipPrevious: "Previous picture (←)",
+ tipNext: "Next picture (→)",
+ tipCounterclockwise: "Counterclockwise",
+ tipClockwise: "Clockwise",
+ tipZoomOut: "Zoom out",
+ tipZoomIn: "Zoom in",
+ tipDownload: "Download",
+ tipClose: "Close (Esc)",
+ // TODO: translation
+ tipOriginalSize: "Zoom to original size"
+ }
+};
+function buildFormatLongFn(args) {
+ return (options = {}) => {
+ const width = options.width ? String(options.width) : args.defaultWidth;
+ const format = args.formats[width] || args.formats[args.defaultWidth];
+ return format;
+ };
+}
+function buildLocalizeFn(args) {
+ return (value, options) => {
+ const context = options?.context ? String(options.context) : "standalone";
+ let valuesArray;
+ if (context === "formatting" && args.formattingValues) {
+ const defaultWidth = args.defaultFormattingWidth || args.defaultWidth;
+ const width = options?.width ? String(options.width) : defaultWidth;
+ valuesArray = args.formattingValues[width] || args.formattingValues[defaultWidth];
+ } else {
+ const defaultWidth = args.defaultWidth;
+ const width = options?.width ? String(options.width) : args.defaultWidth;
+ valuesArray = args.values[width] || args.values[defaultWidth];
+ }
+ const index = args.argumentCallback ? args.argumentCallback(value) : value;
+ return valuesArray[index];
+ };
+}
+function buildMatchFn(args) {
+ return (string, options = {}) => {
+ const width = options.width;
+ const matchPattern = width && args.matchPatterns[width] || args.matchPatterns[args.defaultMatchWidth];
+ const matchResult = string.match(matchPattern);
+ if (!matchResult) {
+ return null;
+ }
+ const matchedString = matchResult[0];
+ const parsePatterns = width && args.parsePatterns[width] || args.parsePatterns[args.defaultParseWidth];
+ const key = Array.isArray(parsePatterns) ? findIndex(parsePatterns, (pattern) => pattern.test(matchedString)) : (
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any -- I challange you to fix the type
+ findKey(parsePatterns, (pattern) => pattern.test(matchedString))
+ );
+ let value;
+ value = args.valueCallback ? args.valueCallback(key) : key;
+ value = options.valueCallback ? (
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any -- I challange you to fix the type
+ options.valueCallback(value)
+ ) : value;
+ const rest = string.slice(matchedString.length);
+ return { value, rest };
+ };
+}
+function findKey(object, predicate) {
+ for (const key in object) {
+ if (Object.prototype.hasOwnProperty.call(object, key) && predicate(object[key])) {
+ return key;
+ }
+ }
+ return void 0;
+}
+function findIndex(array, predicate) {
+ for (let key = 0; key < array.length; key++) {
+ if (predicate(array[key])) {
+ return key;
+ }
+ }
+ return void 0;
+}
+function buildMatchPatternFn(args) {
+ return (string, options = {}) => {
+ const matchResult = string.match(args.matchPattern);
+ if (!matchResult) return null;
+ const matchedString = matchResult[0];
+ const parseResult = string.match(args.parsePattern);
+ if (!parseResult) return null;
+ let value = args.valueCallback ? args.valueCallback(parseResult[0]) : parseResult[0];
+ value = options.valueCallback ? options.valueCallback(value) : value;
+ const rest = string.slice(matchedString.length);
+ return { value, rest };
+ };
+}
+const formatDistanceLocale = {
+ lessThanXSeconds: {
+ one: "less than a second",
+ other: "less than {{count}} seconds"
+ },
+ xSeconds: {
+ one: "1 second",
+ other: "{{count}} seconds"
+ },
+ halfAMinute: "half a minute",
+ lessThanXMinutes: {
+ one: "less than a minute",
+ other: "less than {{count}} minutes"
+ },
+ xMinutes: {
+ one: "1 minute",
+ other: "{{count}} minutes"
+ },
+ aboutXHours: {
+ one: "about 1 hour",
+ other: "about {{count}} hours"
+ },
+ xHours: {
+ one: "1 hour",
+ other: "{{count}} hours"
+ },
+ xDays: {
+ one: "1 day",
+ other: "{{count}} days"
+ },
+ aboutXWeeks: {
+ one: "about 1 week",
+ other: "about {{count}} weeks"
+ },
+ xWeeks: {
+ one: "1 week",
+ other: "{{count}} weeks"
+ },
+ aboutXMonths: {
+ one: "about 1 month",
+ other: "about {{count}} months"
+ },
+ xMonths: {
+ one: "1 month",
+ other: "{{count}} months"
+ },
+ aboutXYears: {
+ one: "about 1 year",
+ other: "about {{count}} years"
+ },
+ xYears: {
+ one: "1 year",
+ other: "{{count}} years"
+ },
+ overXYears: {
+ one: "over 1 year",
+ other: "over {{count}} years"
+ },
+ almostXYears: {
+ one: "almost 1 year",
+ other: "almost {{count}} years"
+ }
+};
+const formatDistance = (token, count, options) => {
+ let result;
+ const tokenValue = formatDistanceLocale[token];
+ if (typeof tokenValue === "string") {
+ result = tokenValue;
+ } else if (count === 1) {
+ result = tokenValue.one;
+ } else {
+ result = tokenValue.other.replace("{{count}}", count.toString());
+ }
+ if (options?.addSuffix) {
+ if (options.comparison && options.comparison > 0) {
+ return "in " + result;
+ } else {
+ return result + " ago";
+ }
+ }
+ return result;
+};
+const formatRelativeLocale = {
+ lastWeek: "'last' eeee 'at' p",
+ yesterday: "'yesterday at' p",
+ today: "'today at' p",
+ tomorrow: "'tomorrow at' p",
+ nextWeek: "eeee 'at' p",
+ other: "P"
+};
+const formatRelative = (token, _date, _baseDate, _options) => formatRelativeLocale[token];
+const eraValues = {
+ narrow: ["B", "A"],
+ abbreviated: ["BC", "AD"],
+ wide: ["Before Christ", "Anno Domini"]
+};
+const quarterValues = {
+ narrow: ["1", "2", "3", "4"],
+ abbreviated: ["Q1", "Q2", "Q3", "Q4"],
+ wide: ["1st quarter", "2nd quarter", "3rd quarter", "4th quarter"]
+};
+const monthValues = {
+ narrow: ["J", "F", "M", "A", "M", "J", "J", "A", "S", "O", "N", "D"],
+ abbreviated: [
+ "Jan",
+ "Feb",
+ "Mar",
+ "Apr",
+ "May",
+ "Jun",
+ "Jul",
+ "Aug",
+ "Sep",
+ "Oct",
+ "Nov",
+ "Dec"
+ ],
+ wide: [
+ "January",
+ "February",
+ "March",
+ "April",
+ "May",
+ "June",
+ "July",
+ "August",
+ "September",
+ "October",
+ "November",
+ "December"
+ ]
+};
+const dayValues = {
+ narrow: ["S", "M", "T", "W", "T", "F", "S"],
+ short: ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"],
+ abbreviated: ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"],
+ wide: [
+ "Sunday",
+ "Monday",
+ "Tuesday",
+ "Wednesday",
+ "Thursday",
+ "Friday",
+ "Saturday"
+ ]
+};
+const dayPeriodValues = {
+ narrow: {
+ am: "a",
+ pm: "p",
+ midnight: "mi",
+ noon: "n",
+ morning: "morning",
+ afternoon: "afternoon",
+ evening: "evening",
+ night: "night"
+ },
+ abbreviated: {
+ am: "AM",
+ pm: "PM",
+ midnight: "midnight",
+ noon: "noon",
+ morning: "morning",
+ afternoon: "afternoon",
+ evening: "evening",
+ night: "night"
+ },
+ wide: {
+ am: "a.m.",
+ pm: "p.m.",
+ midnight: "midnight",
+ noon: "noon",
+ morning: "morning",
+ afternoon: "afternoon",
+ evening: "evening",
+ night: "night"
+ }
+};
+const formattingDayPeriodValues = {
+ narrow: {
+ am: "a",
+ pm: "p",
+ midnight: "mi",
+ noon: "n",
+ morning: "in the morning",
+ afternoon: "in the afternoon",
+ evening: "in the evening",
+ night: "at night"
+ },
+ abbreviated: {
+ am: "AM",
+ pm: "PM",
+ midnight: "midnight",
+ noon: "noon",
+ morning: "in the morning",
+ afternoon: "in the afternoon",
+ evening: "in the evening",
+ night: "at night"
+ },
+ wide: {
+ am: "a.m.",
+ pm: "p.m.",
+ midnight: "midnight",
+ noon: "noon",
+ morning: "in the morning",
+ afternoon: "in the afternoon",
+ evening: "in the evening",
+ night: "at night"
+ }
+};
+const ordinalNumber = (dirtyNumber, _options) => {
+ const number = Number(dirtyNumber);
+ const rem100 = number % 100;
+ if (rem100 > 20 || rem100 < 10) {
+ switch (rem100 % 10) {
+ case 1:
+ return number + "st";
+ case 2:
+ return number + "nd";
+ case 3:
+ return number + "rd";
+ }
+ }
+ return number + "th";
+};
+const localize = {
+ ordinalNumber,
+ era: buildLocalizeFn({
+ values: eraValues,
+ defaultWidth: "wide"
+ }),
+ quarter: buildLocalizeFn({
+ values: quarterValues,
+ defaultWidth: "wide",
+ argumentCallback: (quarter) => quarter - 1
+ }),
+ month: buildLocalizeFn({
+ values: monthValues,
+ defaultWidth: "wide"
+ }),
+ day: buildLocalizeFn({
+ values: dayValues,
+ defaultWidth: "wide"
+ }),
+ dayPeriod: buildLocalizeFn({
+ values: dayPeriodValues,
+ defaultWidth: "wide",
+ formattingValues: formattingDayPeriodValues,
+ defaultFormattingWidth: "wide"
+ })
+};
+const matchOrdinalNumberPattern = /^(\d+)(th|st|nd|rd)?/i;
+const parseOrdinalNumberPattern = /\d+/i;
+const matchEraPatterns = {
+ narrow: /^(b|a)/i,
+ abbreviated: /^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,
+ wide: /^(before christ|before common era|anno domini|common era)/i
+};
+const parseEraPatterns = {
+ any: [/^b/i, /^(a|c)/i]
+};
+const matchQuarterPatterns = {
+ narrow: /^[1234]/i,
+ abbreviated: /^q[1234]/i,
+ wide: /^[1234](th|st|nd|rd)? quarter/i
+};
+const parseQuarterPatterns = {
+ any: [/1/i, /2/i, /3/i, /4/i]
+};
+const matchMonthPatterns = {
+ narrow: /^[jfmasond]/i,
+ abbreviated: /^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,
+ wide: /^(january|february|march|april|may|june|july|august|september|october|november|december)/i
+};
+const parseMonthPatterns = {
+ narrow: [
+ /^j/i,
+ /^f/i,
+ /^m/i,
+ /^a/i,
+ /^m/i,
+ /^j/i,
+ /^j/i,
+ /^a/i,
+ /^s/i,
+ /^o/i,
+ /^n/i,
+ /^d/i
+ ],
+ any: [
+ /^ja/i,
+ /^f/i,
+ /^mar/i,
+ /^ap/i,
+ /^may/i,
+ /^jun/i,
+ /^jul/i,
+ /^au/i,
+ /^s/i,
+ /^o/i,
+ /^n/i,
+ /^d/i
+ ]
+};
+const matchDayPatterns = {
+ narrow: /^[smtwf]/i,
+ short: /^(su|mo|tu|we|th|fr|sa)/i,
+ abbreviated: /^(sun|mon|tue|wed|thu|fri|sat)/i,
+ wide: /^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i
+};
+const parseDayPatterns = {
+ narrow: [/^s/i, /^m/i, /^t/i, /^w/i, /^t/i, /^f/i, /^s/i],
+ any: [/^su/i, /^m/i, /^tu/i, /^w/i, /^th/i, /^f/i, /^sa/i]
+};
+const matchDayPeriodPatterns = {
+ narrow: /^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,
+ any: /^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i
+};
+const parseDayPeriodPatterns = {
+ any: {
+ am: /^a/i,
+ pm: /^p/i,
+ midnight: /^mi/i,
+ noon: /^no/i,
+ morning: /morning/i,
+ afternoon: /afternoon/i,
+ evening: /evening/i,
+ night: /night/i
+ }
+};
+const match = {
+ ordinalNumber: buildMatchPatternFn({
+ matchPattern: matchOrdinalNumberPattern,
+ parsePattern: parseOrdinalNumberPattern,
+ valueCallback: (value) => parseInt(value, 10)
+ }),
+ era: buildMatchFn({
+ matchPatterns: matchEraPatterns,
+ defaultMatchWidth: "wide",
+ parsePatterns: parseEraPatterns,
+ defaultParseWidth: "any"
+ }),
+ quarter: buildMatchFn({
+ matchPatterns: matchQuarterPatterns,
+ defaultMatchWidth: "wide",
+ parsePatterns: parseQuarterPatterns,
+ defaultParseWidth: "any",
+ valueCallback: (index) => index + 1
+ }),
+ month: buildMatchFn({
+ matchPatterns: matchMonthPatterns,
+ defaultMatchWidth: "wide",
+ parsePatterns: parseMonthPatterns,
+ defaultParseWidth: "any"
+ }),
+ day: buildMatchFn({
+ matchPatterns: matchDayPatterns,
+ defaultMatchWidth: "wide",
+ parsePatterns: parseDayPatterns,
+ defaultParseWidth: "any"
+ }),
+ dayPeriod: buildMatchFn({
+ matchPatterns: matchDayPeriodPatterns,
+ defaultMatchWidth: "any",
+ parsePatterns: parseDayPeriodPatterns,
+ defaultParseWidth: "any"
+ })
+};
+const dateFormats = {
+ full: "EEEE, MMMM do, y",
+ long: "MMMM do, y",
+ medium: "MMM d, y",
+ short: "MM/dd/yyyy"
+};
+const timeFormats = {
+ full: "h:mm:ss a zzzz",
+ long: "h:mm:ss a z",
+ medium: "h:mm:ss a",
+ short: "h:mm a"
+};
+const dateTimeFormats = {
+ full: "{{date}} 'at' {{time}}",
+ long: "{{date}} 'at' {{time}}",
+ medium: "{{date}}, {{time}}",
+ short: "{{date}}, {{time}}"
+};
+const formatLong = {
+ date: buildFormatLongFn({
+ formats: dateFormats,
+ defaultWidth: "full"
+ }),
+ time: buildFormatLongFn({
+ formats: timeFormats,
+ defaultWidth: "full"
+ }),
+ dateTime: buildFormatLongFn({
+ formats: dateTimeFormats,
+ defaultWidth: "full"
+ })
+};
+const enUS = {
+ code: "en-US",
+ formatDistance,
+ formatLong,
+ formatRelative,
+ localize,
+ match,
+ options: {
+ weekStartsOn: 0,
+ firstWeekContainsDate: 1
+ }
+};
+const dateEnUs = {
+ name: "en-US",
+ locale: enUS
+};
+function useLocale(ns) {
+ const {
+ mergedLocaleRef,
+ mergedDateLocaleRef
+ } = inject(configProviderInjectionKey, null) || {};
+ const localeRef = computed(() => {
+ var _a, _b;
+ return (_b = (_a = mergedLocaleRef === null || mergedLocaleRef === void 0 ? void 0 : mergedLocaleRef.value) === null || _a === void 0 ? void 0 : _a[ns]) !== null && _b !== void 0 ? _b : enUS$1[ns];
+ });
+ const dateLocaleRef = computed(() => {
+ var _a;
+ return (_a = mergedDateLocaleRef === null || mergedDateLocaleRef === void 0 ? void 0 : mergedDateLocaleRef.value) !== null && _a !== void 0 ? _a : dateEnUs;
+ });
+ return {
+ dateLocaleRef,
+ localeRef
+ };
+}
+export {
+ Binder as B,
+ VTarget as V,
+ c as a,
+ beforeNextFrameOnce as b,
+ cssrAnchorMetaName as c,
+ useAdjustedTo as d,
+ VFollower as e,
+ useLocale as u
+};
diff --git a/out/renderer/assets/use-locale-DLWAOXez.js.gz b/out/renderer/assets/use-locale-DLWAOXez.js.gz
new file mode 100644
index 0000000..b02f128
Binary files /dev/null and b/out/renderer/assets/use-locale-DLWAOXez.js.gz differ
diff --git a/src/assets/wechat.png b/out/renderer/assets/wechat-DjfpYhZS.png
similarity index 100%
rename from src/assets/wechat.png
rename to out/renderer/assets/wechat-DjfpYhZS.png
diff --git a/out/renderer/index.html b/out/renderer/index.html
new file mode 100644
index 0000000..baa0aa5
--- /dev/null
+++ b/out/renderer/index.html
@@ -0,0 +1,53 @@
+
+
+
+
+
+
+
+
+ 网抑云音乐 | AlgerKong | AlgerMusicPlayer
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Total Page View Loading Total Visits
+ Loading Site Total Visitors
+ Loading
+
+
+
diff --git a/out/renderer/index.html.gz b/out/renderer/index.html.gz
new file mode 100644
index 0000000..3957911
Binary files /dev/null and b/out/renderer/index.html.gz differ
diff --git a/package.json b/package.json
index 48f8f4e..8f876ba 100644
--- a/package.json
+++ b/package.json
@@ -1,32 +1,48 @@
{
- "name": "alger-music",
- "version": "2.5.0",
- "description": "这是一个用于音乐播放的应用程序。",
+ "name": "AlgerMusicPlayer",
+ "version": "3.0.0",
+ "description": "Alger Music Player",
"author": "Alger ",
- "main": "app.js",
+ "main": "./out/main/index.js",
+ "homepage": "https://github.com/algerkong/AlgerMusicPlayer",
"scripts": {
- "dev": "vite",
- "build": "cross-env NODE_ENV=production vite build",
- "serve": "vite preview",
- "start": "cross-env NODE_ENV=development electron .",
- "lint": "eslint --ext .vue,.js,.jsx,.ts,.tsx ./ --max-warnings 0",
- "b:win:x64": "cross-env NODE_ENV=production electron-builder --config ./build/win64.json",
- "b:win:x86": "cross-env NODE_ENV=production electron-builder --config ./build/win32.json",
- "b:win:arm": "cross-env NODE_ENV=production electron-builder --config ./build/winarm64.json",
- "b:mac": "cross-env NODE_ENV=production npm run build && electron-builder --config ./build/mac.json",
- "b:win": "cross-env NODE_ENV=production npm run build && npm run b:win:x64 && npm run b:win:x86 && npm run b:win:arm"
+ "format": "prettier --write .",
+ "lint": "eslint . --ext .js,.jsx,.cjs,.mjs,.ts,.tsx,.cts,.mts,.vue --fix",
+ "typecheck:node": "tsc --noEmit -p tsconfig.node.json --composite false",
+ "typecheck:web": "vue-tsc --noEmit -p tsconfig.web.json --composite false",
+ "typecheck": "npm run typecheck:node && npm run typecheck:web",
+ "start": "electron-vite preview",
+ "dev": "electron-vite dev",
+ "build": "npm run typecheck && electron-vite build",
+ "postinstall": "electron-builder install-app-deps",
+ "build:unpack": "npm run build && electron-builder --dir",
+ "build:win": "npm run build && electron-builder --win",
+ "build:mac": "npm run build && electron-builder --mac",
+ "build:linux": "npm run build && electron-builder --linux"
},
"dependencies": {
- "@types/howler": "^2.2.12",
+ "@electron-toolkit/preload": "^3.0.0",
+ "@electron-toolkit/utils": "^3.0.0",
+ "@unblockneteasemusic/server": "^0.27.8-patch.1",
"electron-store": "^8.1.0",
- "howler": "^2.2.4"
+ "electron-updater": "^6.1.7",
+
+ "netease-cloud-music-api-alger": "^4.25.0"
},
- "devDependencies": {
+ "devDependencies": {
+ "marked": "^15.0.4",
+ "@electron-toolkit/eslint-config": "^1.0.2",
+ "@electron-toolkit/eslint-config-ts": "^2.0.0",
+ "@electron-toolkit/tsconfig": "^1.0.1",
+ "@rushstack/eslint-patch": "^1.10.3",
"@tailwindcss/postcss7-compat": "^2.2.4",
- "@typescript-eslint/eslint-plugin": "^6.21.0",
- "@typescript-eslint/parser": "^6.21.0",
- "@vitejs/plugin-vue": "^5.1.3",
+ "@types/howler": "^2.2.12",
+ "@types/node": "^20.14.8",
+ "@typescript-eslint/eslint-plugin": "^7.0.0",
+ "@typescript-eslint/parser": "^7.0.0",
+ "@vitejs/plugin-vue": "^5.0.5",
"@vue/compiler-sfc": "^3.5.0",
+ "@vue/eslint-config-prettier": "^9.0.0",
"@vue/eslint-config-typescript": "^13.0.0",
"@vue/runtime-core": "^3.5.0",
"@vueuse/core": "^11.0.3",
@@ -34,33 +50,78 @@
"autoprefixer": "^10.4.20",
"axios": "^1.7.7",
"cross-env": "^7.0.3",
- "electron": "^32.2.7",
- "electron-builder": "^25.0.5",
- "eslint": "^8.56.0",
+ "electron": "^31.0.2",
+ "electron-builder": "^24.13.3",
+ "electron-vite": "^2.3.0",
+ "eslint": "^8.57.0",
"eslint-config-airbnb-base": "^15.0.0",
"eslint-config-prettier": "^9.0.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-simple-import-sort": "^12.0.0",
- "eslint-plugin-vue": "^9.21.1",
+ "eslint-plugin-vue": "^9.26.0",
"eslint-plugin-vue-scoped-css": "^2.7.2",
+ "howler": "^2.2.4",
"lodash": "^4.17.21",
"naive-ui": "^2.39.0",
"postcss": "^8.4.49",
- "prettier": "^3.3.3",
+ "prettier": "^3.3.2",
"remixicon": "^4.2.0",
"sass": "^1.82.0",
"tailwindcss": "^3.4.15",
- "typescript": "^5.5.4",
+ "typescript": "^5.5.2",
"unplugin-auto-import": "^0.18.2",
"unplugin-vue-components": "^0.27.4",
"vfonts": "^0.1.0",
- "vite": "^5.4.3",
+ "vite": "^5.3.1",
"vite-plugin-compression": "^0.5.1",
"vite-plugin-vue-devtools": "7.4.0",
- "vue": "^3.5.0",
+ "vue": "^3.4.30",
"vue-router": "^4.4.3",
- "vue-tsc": "^2.1.4",
+ "vue-tsc": "^2.0.22",
"vuex": "^4.1.0"
+ },
+ "build": {
+ "appId": "com.alger.music",
+ "productName": "AlgerMusicPlayer",
+ "mac": {
+ "icon": "resources/icon.icns",
+ "target": [
+ {
+ "target": "dmg",
+ "arch": [
+ "x64",
+ "arm64"
+ ]
+ },
+ {
+ "target": "zip",
+ "arch": [
+ "x64",
+ "arm64"
+ ]
+ }
+ ]
+ },
+ "win": {
+ "icon": "resources/favicon.ico",
+ "target": [
+ "nsis",
+ "zip"
+ ]
+ },
+ "linux": {
+ "icon": "resources/icon.png",
+ "target": [
+ "AppImage",
+ "deb"
+ ]
+ },
+ "nsis": {
+ "oneClick": false,
+ "allowToChangeInstallationDirectory": true,
+ "installerIcon": "resources/favicon.ico",
+ "uninstallerIcon": "resources/favicon.ico"
+ }
}
}
diff --git a/postcss.config.js b/postcss.config.js
index 33ad091..5cbc2c7 100644
--- a/postcss.config.js
+++ b/postcss.config.js
@@ -1,6 +1,6 @@
module.exports = {
plugins: {
tailwindcss: {},
- autoprefixer: {},
- },
-}
+ autoprefixer: {}
+ }
+};
diff --git a/public/css/animate.css b/public/css/animate.css
deleted file mode 100644
index 76d2fe1..0000000
--- a/public/css/animate.css
+++ /dev/null
@@ -1,7 +0,0 @@
-@charset "UTF-8";/*!
- * animate.css - https://animate.style/
- * Version - 4.1.1
- * Licensed under the MIT license - http://opensource.org/licenses/MIT
- *
- * Copyright (c) 2020 Animate.css
- */:root{--animate-duration:1s;--animate-delay:1s;--animate-repeat:1}.animate__animated{-webkit-animation-duration:1s;animation-duration:1s;-webkit-animation-duration:var(--animate-duration);animation-duration:var(--animate-duration);-webkit-animation-fill-mode:both;animation-fill-mode:both}.animate__animated.animate__infinite{-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite}.animate__animated.animate__repeat-1{-webkit-animation-iteration-count:1;animation-iteration-count:1;-webkit-animation-iteration-count:var(--animate-repeat);animation-iteration-count:var(--animate-repeat)}.animate__animated.animate__repeat-2{-webkit-animation-iteration-count:2;animation-iteration-count:2;-webkit-animation-iteration-count:calc(var(--animate-repeat)*2);animation-iteration-count:calc(var(--animate-repeat)*2)}.animate__animated.animate__repeat-3{-webkit-animation-iteration-count:3;animation-iteration-count:3;-webkit-animation-iteration-count:calc(var(--animate-repeat)*3);animation-iteration-count:calc(var(--animate-repeat)*3)}.animate__animated.animate__delay-1s{-webkit-animation-delay:1s;animation-delay:1s;-webkit-animation-delay:var(--animate-delay);animation-delay:var(--animate-delay)}.animate__animated.animate__delay-2s{-webkit-animation-delay:2s;animation-delay:2s;-webkit-animation-delay:calc(var(--animate-delay)*2);animation-delay:calc(var(--animate-delay)*2)}.animate__animated.animate__delay-3s{-webkit-animation-delay:3s;animation-delay:3s;-webkit-animation-delay:calc(var(--animate-delay)*3);animation-delay:calc(var(--animate-delay)*3)}.animate__animated.animate__delay-4s{-webkit-animation-delay:4s;animation-delay:4s;-webkit-animation-delay:calc(var(--animate-delay)*4);animation-delay:calc(var(--animate-delay)*4)}.animate__animated.animate__delay-5s{-webkit-animation-delay:5s;animation-delay:5s;-webkit-animation-delay:calc(var(--animate-delay)*5);animation-delay:calc(var(--animate-delay)*5)}.animate__animated.animate__faster{-webkit-animation-duration:.5s;animation-duration:.5s;-webkit-animation-duration:calc(var(--animate-duration)/2);animation-duration:calc(var(--animate-duration)/2)}.animate__animated.animate__fast{-webkit-animation-duration:.8s;animation-duration:.8s;-webkit-animation-duration:calc(var(--animate-duration)*0.8);animation-duration:calc(var(--animate-duration)*0.8)}.animate__animated.animate__slow{-webkit-animation-duration:2s;animation-duration:2s;-webkit-animation-duration:calc(var(--animate-duration)*2);animation-duration:calc(var(--animate-duration)*2)}.animate__animated.animate__slower{-webkit-animation-duration:3s;animation-duration:3s;-webkit-animation-duration:calc(var(--animate-duration)*3);animation-duration:calc(var(--animate-duration)*3)}@media (prefers-reduced-motion:reduce),print{.animate__animated{-webkit-animation-duration:1ms!important;animation-duration:1ms!important;-webkit-transition-duration:1ms!important;transition-duration:1ms!important;-webkit-animation-iteration-count:1!important;animation-iteration-count:1!important}.animate__animated[class*=Out]{opacity:0}}@-webkit-keyframes bounce{0%,20%,53%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0);transform:translateZ(0)}40%,43%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-30px,0) scaleY(1.1);transform:translate3d(0,-30px,0) scaleY(1.1)}70%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-15px,0) scaleY(1.05);transform:translate3d(0,-15px,0) scaleY(1.05)}80%{-webkit-transition-timing-function:cubic-bezier(.215,.61,.355,1);transition-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0) scaleY(.95);transform:translateZ(0) scaleY(.95)}90%{-webkit-transform:translate3d(0,-4px,0) scaleY(1.02);transform:translate3d(0,-4px,0) scaleY(1.02)}}@keyframes bounce{0%,20%,53%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0);transform:translateZ(0)}40%,43%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-30px,0) scaleY(1.1);transform:translate3d(0,-30px,0) scaleY(1.1)}70%{-webkit-animation-timing-function:cubic-bezier(.755,.05,.855,.06);animation-timing-function:cubic-bezier(.755,.05,.855,.06);-webkit-transform:translate3d(0,-15px,0) scaleY(1.05);transform:translate3d(0,-15px,0) scaleY(1.05)}80%{-webkit-transition-timing-function:cubic-bezier(.215,.61,.355,1);transition-timing-function:cubic-bezier(.215,.61,.355,1);-webkit-transform:translateZ(0) scaleY(.95);transform:translateZ(0) scaleY(.95)}90%{-webkit-transform:translate3d(0,-4px,0) scaleY(1.02);transform:translate3d(0,-4px,0) scaleY(1.02)}}.animate__bounce{-webkit-animation-name:bounce;animation-name:bounce;-webkit-transform-origin:center bottom;transform-origin:center bottom}@-webkit-keyframes flash{0%,50%,to{opacity:1}25%,75%{opacity:0}}@keyframes flash{0%,50%,to{opacity:1}25%,75%{opacity:0}}.animate__flash{-webkit-animation-name:flash;animation-name:flash}@-webkit-keyframes pulse{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}50%{-webkit-transform:scale3d(1.05,1.05,1.05);transform:scale3d(1.05,1.05,1.05)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes pulse{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}50%{-webkit-transform:scale3d(1.05,1.05,1.05);transform:scale3d(1.05,1.05,1.05)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.animate__pulse{-webkit-animation-name:pulse;animation-name:pulse;-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}@-webkit-keyframes rubberBand{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}30%{-webkit-transform:scale3d(1.25,.75,1);transform:scale3d(1.25,.75,1)}40%{-webkit-transform:scale3d(.75,1.25,1);transform:scale3d(.75,1.25,1)}50%{-webkit-transform:scale3d(1.15,.85,1);transform:scale3d(1.15,.85,1)}65%{-webkit-transform:scale3d(.95,1.05,1);transform:scale3d(.95,1.05,1)}75%{-webkit-transform:scale3d(1.05,.95,1);transform:scale3d(1.05,.95,1)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes rubberBand{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}30%{-webkit-transform:scale3d(1.25,.75,1);transform:scale3d(1.25,.75,1)}40%{-webkit-transform:scale3d(.75,1.25,1);transform:scale3d(.75,1.25,1)}50%{-webkit-transform:scale3d(1.15,.85,1);transform:scale3d(1.15,.85,1)}65%{-webkit-transform:scale3d(.95,1.05,1);transform:scale3d(.95,1.05,1)}75%{-webkit-transform:scale3d(1.05,.95,1);transform:scale3d(1.05,.95,1)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.animate__rubberBand{-webkit-animation-name:rubberBand;animation-name:rubberBand}@-webkit-keyframes shakeX{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}20%,40%,60%,80%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}}@keyframes shakeX{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(-10px,0,0);transform:translate3d(-10px,0,0)}20%,40%,60%,80%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}}.animate__shakeX{-webkit-animation-name:shakeX;animation-name:shakeX}@-webkit-keyframes shakeY{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}20%,40%,60%,80%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}}@keyframes shakeY{0%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}10%,30%,50%,70%,90%{-webkit-transform:translate3d(0,-10px,0);transform:translate3d(0,-10px,0)}20%,40%,60%,80%{-webkit-transform:translate3d(0,10px,0);transform:translate3d(0,10px,0)}}.animate__shakeY{-webkit-animation-name:shakeY;animation-name:shakeY}@-webkit-keyframes headShake{0%{-webkit-transform:translateX(0);transform:translateX(0)}6.5%{-webkit-transform:translateX(-6px) rotateY(-9deg);transform:translateX(-6px) rotateY(-9deg)}18.5%{-webkit-transform:translateX(5px) rotateY(7deg);transform:translateX(5px) rotateY(7deg)}31.5%{-webkit-transform:translateX(-3px) rotateY(-5deg);transform:translateX(-3px) rotateY(-5deg)}43.5%{-webkit-transform:translateX(2px) rotateY(3deg);transform:translateX(2px) rotateY(3deg)}50%{-webkit-transform:translateX(0);transform:translateX(0)}}@keyframes headShake{0%{-webkit-transform:translateX(0);transform:translateX(0)}6.5%{-webkit-transform:translateX(-6px) rotateY(-9deg);transform:translateX(-6px) rotateY(-9deg)}18.5%{-webkit-transform:translateX(5px) rotateY(7deg);transform:translateX(5px) rotateY(7deg)}31.5%{-webkit-transform:translateX(-3px) rotateY(-5deg);transform:translateX(-3px) rotateY(-5deg)}43.5%{-webkit-transform:translateX(2px) rotateY(3deg);transform:translateX(2px) rotateY(3deg)}50%{-webkit-transform:translateX(0);transform:translateX(0)}}.animate__headShake{-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out;-webkit-animation-name:headShake;animation-name:headShake}@-webkit-keyframes swing{20%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}40%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}60%{-webkit-transform:rotate(5deg);transform:rotate(5deg)}80%{-webkit-transform:rotate(-5deg);transform:rotate(-5deg)}to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}@keyframes swing{20%{-webkit-transform:rotate(15deg);transform:rotate(15deg)}40%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}60%{-webkit-transform:rotate(5deg);transform:rotate(5deg)}80%{-webkit-transform:rotate(-5deg);transform:rotate(-5deg)}to{-webkit-transform:rotate(0deg);transform:rotate(0deg)}}.animate__swing{-webkit-transform-origin:top center;transform-origin:top center;-webkit-animation-name:swing;animation-name:swing}@-webkit-keyframes tada{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}10%,20%{-webkit-transform:scale3d(.9,.9,.9) rotate(-3deg);transform:scale3d(.9,.9,.9) rotate(-3deg)}30%,50%,70%,90%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(3deg);transform:scale3d(1.1,1.1,1.1) rotate(3deg)}40%,60%,80%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(-3deg);transform:scale3d(1.1,1.1,1.1) rotate(-3deg)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes tada{0%{-webkit-transform:scaleX(1);transform:scaleX(1)}10%,20%{-webkit-transform:scale3d(.9,.9,.9) rotate(-3deg);transform:scale3d(.9,.9,.9) rotate(-3deg)}30%,50%,70%,90%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(3deg);transform:scale3d(1.1,1.1,1.1) rotate(3deg)}40%,60%,80%{-webkit-transform:scale3d(1.1,1.1,1.1) rotate(-3deg);transform:scale3d(1.1,1.1,1.1) rotate(-3deg)}to{-webkit-transform:scaleX(1);transform:scaleX(1)}}.animate__tada{-webkit-animation-name:tada;animation-name:tada}@-webkit-keyframes wobble{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}15%{-webkit-transform:translate3d(-25%,0,0) rotate(-5deg);transform:translate3d(-25%,0,0) rotate(-5deg)}30%{-webkit-transform:translate3d(20%,0,0) rotate(3deg);transform:translate3d(20%,0,0) rotate(3deg)}45%{-webkit-transform:translate3d(-15%,0,0) rotate(-3deg);transform:translate3d(-15%,0,0) rotate(-3deg)}60%{-webkit-transform:translate3d(10%,0,0) rotate(2deg);transform:translate3d(10%,0,0) rotate(2deg)}75%{-webkit-transform:translate3d(-5%,0,0) rotate(-1deg);transform:translate3d(-5%,0,0) rotate(-1deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes wobble{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}15%{-webkit-transform:translate3d(-25%,0,0) rotate(-5deg);transform:translate3d(-25%,0,0) rotate(-5deg)}30%{-webkit-transform:translate3d(20%,0,0) rotate(3deg);transform:translate3d(20%,0,0) rotate(3deg)}45%{-webkit-transform:translate3d(-15%,0,0) rotate(-3deg);transform:translate3d(-15%,0,0) rotate(-3deg)}60%{-webkit-transform:translate3d(10%,0,0) rotate(2deg);transform:translate3d(10%,0,0) rotate(2deg)}75%{-webkit-transform:translate3d(-5%,0,0) rotate(-1deg);transform:translate3d(-5%,0,0) rotate(-1deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__wobble{-webkit-animation-name:wobble;animation-name:wobble}@-webkit-keyframes jello{0%,11.1%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}22.2%{-webkit-transform:skewX(-12.5deg) skewY(-12.5deg);transform:skewX(-12.5deg) skewY(-12.5deg)}33.3%{-webkit-transform:skewX(6.25deg) skewY(6.25deg);transform:skewX(6.25deg) skewY(6.25deg)}44.4%{-webkit-transform:skewX(-3.125deg) skewY(-3.125deg);transform:skewX(-3.125deg) skewY(-3.125deg)}55.5%{-webkit-transform:skewX(1.5625deg) skewY(1.5625deg);transform:skewX(1.5625deg) skewY(1.5625deg)}66.6%{-webkit-transform:skewX(-.78125deg) skewY(-.78125deg);transform:skewX(-.78125deg) skewY(-.78125deg)}77.7%{-webkit-transform:skewX(.390625deg) skewY(.390625deg);transform:skewX(.390625deg) skewY(.390625deg)}88.8%{-webkit-transform:skewX(-.1953125deg) skewY(-.1953125deg);transform:skewX(-.1953125deg) skewY(-.1953125deg)}}@keyframes jello{0%,11.1%,to{-webkit-transform:translateZ(0);transform:translateZ(0)}22.2%{-webkit-transform:skewX(-12.5deg) skewY(-12.5deg);transform:skewX(-12.5deg) skewY(-12.5deg)}33.3%{-webkit-transform:skewX(6.25deg) skewY(6.25deg);transform:skewX(6.25deg) skewY(6.25deg)}44.4%{-webkit-transform:skewX(-3.125deg) skewY(-3.125deg);transform:skewX(-3.125deg) skewY(-3.125deg)}55.5%{-webkit-transform:skewX(1.5625deg) skewY(1.5625deg);transform:skewX(1.5625deg) skewY(1.5625deg)}66.6%{-webkit-transform:skewX(-.78125deg) skewY(-.78125deg);transform:skewX(-.78125deg) skewY(-.78125deg)}77.7%{-webkit-transform:skewX(.390625deg) skewY(.390625deg);transform:skewX(.390625deg) skewY(.390625deg)}88.8%{-webkit-transform:skewX(-.1953125deg) skewY(-.1953125deg);transform:skewX(-.1953125deg) skewY(-.1953125deg)}}.animate__jello{-webkit-animation-name:jello;animation-name:jello;-webkit-transform-origin:center;transform-origin:center}@-webkit-keyframes heartBeat{0%{-webkit-transform:scale(1);transform:scale(1)}14%{-webkit-transform:scale(1.3);transform:scale(1.3)}28%{-webkit-transform:scale(1);transform:scale(1)}42%{-webkit-transform:scale(1.3);transform:scale(1.3)}70%{-webkit-transform:scale(1);transform:scale(1)}}@keyframes heartBeat{0%{-webkit-transform:scale(1);transform:scale(1)}14%{-webkit-transform:scale(1.3);transform:scale(1.3)}28%{-webkit-transform:scale(1);transform:scale(1)}42%{-webkit-transform:scale(1.3);transform:scale(1.3)}70%{-webkit-transform:scale(1);transform:scale(1)}}.animate__heartBeat{-webkit-animation-name:heartBeat;animation-name:heartBeat;-webkit-animation-duration:1.3s;animation-duration:1.3s;-webkit-animation-duration:calc(var(--animate-duration)*1.3);animation-duration:calc(var(--animate-duration)*1.3);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}@-webkit-keyframes backInDown{0%{-webkit-transform:translateY(-1200px) scale(.7);transform:translateY(-1200px) scale(.7);opacity:.7}80%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}@keyframes backInDown{0%{-webkit-transform:translateY(-1200px) scale(.7);transform:translateY(-1200px) scale(.7);opacity:.7}80%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}.animate__backInDown{-webkit-animation-name:backInDown;animation-name:backInDown}@-webkit-keyframes backInLeft{0%{-webkit-transform:translateX(-2000px) scale(.7);transform:translateX(-2000px) scale(.7);opacity:.7}80%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}@keyframes backInLeft{0%{-webkit-transform:translateX(-2000px) scale(.7);transform:translateX(-2000px) scale(.7);opacity:.7}80%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}.animate__backInLeft{-webkit-animation-name:backInLeft;animation-name:backInLeft}@-webkit-keyframes backInRight{0%{-webkit-transform:translateX(2000px) scale(.7);transform:translateX(2000px) scale(.7);opacity:.7}80%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}@keyframes backInRight{0%{-webkit-transform:translateX(2000px) scale(.7);transform:translateX(2000px) scale(.7);opacity:.7}80%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}.animate__backInRight{-webkit-animation-name:backInRight;animation-name:backInRight}@-webkit-keyframes backInUp{0%{-webkit-transform:translateY(1200px) scale(.7);transform:translateY(1200px) scale(.7);opacity:.7}80%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}@keyframes backInUp{0%{-webkit-transform:translateY(1200px) scale(.7);transform:translateY(1200px) scale(.7);opacity:.7}80%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:scale(1);transform:scale(1);opacity:1}}.animate__backInUp{-webkit-animation-name:backInUp;animation-name:backInUp}@-webkit-keyframes backOutDown{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:translateY(700px) scale(.7);transform:translateY(700px) scale(.7);opacity:.7}}@keyframes backOutDown{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:translateY(700px) scale(.7);transform:translateY(700px) scale(.7);opacity:.7}}.animate__backOutDown{-webkit-animation-name:backOutDown;animation-name:backOutDown}@-webkit-keyframes backOutLeft{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:translateX(-2000px) scale(.7);transform:translateX(-2000px) scale(.7);opacity:.7}}@keyframes backOutLeft{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:translateX(-2000px) scale(.7);transform:translateX(-2000px) scale(.7);opacity:.7}}.animate__backOutLeft{-webkit-animation-name:backOutLeft;animation-name:backOutLeft}@-webkit-keyframes backOutRight{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:translateX(2000px) scale(.7);transform:translateX(2000px) scale(.7);opacity:.7}}@keyframes backOutRight{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateX(0) scale(.7);transform:translateX(0) scale(.7);opacity:.7}to{-webkit-transform:translateX(2000px) scale(.7);transform:translateX(2000px) scale(.7);opacity:.7}}.animate__backOutRight{-webkit-animation-name:backOutRight;animation-name:backOutRight}@-webkit-keyframes backOutUp{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:translateY(-700px) scale(.7);transform:translateY(-700px) scale(.7);opacity:.7}}@keyframes backOutUp{0%{-webkit-transform:scale(1);transform:scale(1);opacity:1}20%{-webkit-transform:translateY(0) scale(.7);transform:translateY(0) scale(.7);opacity:.7}to{-webkit-transform:translateY(-700px) scale(.7);transform:translateY(-700px) scale(.7);opacity:.7}}.animate__backOutUp{-webkit-animation-name:backOutUp;animation-name:backOutUp}@-webkit-keyframes bounceIn{0%,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}20%{-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}40%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}60%{opacity:1;-webkit-transform:scale3d(1.03,1.03,1.03);transform:scale3d(1.03,1.03,1.03)}80%{-webkit-transform:scale3d(.97,.97,.97);transform:scale3d(.97,.97,.97)}to{opacity:1;-webkit-transform:scaleX(1);transform:scaleX(1)}}@keyframes bounceIn{0%,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}20%{-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}40%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}60%{opacity:1;-webkit-transform:scale3d(1.03,1.03,1.03);transform:scale3d(1.03,1.03,1.03)}80%{-webkit-transform:scale3d(.97,.97,.97);transform:scale3d(.97,.97,.97)}to{opacity:1;-webkit-transform:scaleX(1);transform:scaleX(1)}}.animate__bounceIn{-webkit-animation-duration:.75s;animation-duration:.75s;-webkit-animation-duration:calc(var(--animate-duration)*0.75);animation-duration:calc(var(--animate-duration)*0.75);-webkit-animation-name:bounceIn;animation-name:bounceIn}@-webkit-keyframes bounceInDown{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(0,-3000px,0) scaleY(3);transform:translate3d(0,-3000px,0) scaleY(3)}60%{opacity:1;-webkit-transform:translate3d(0,25px,0) scaleY(.9);transform:translate3d(0,25px,0) scaleY(.9)}75%{-webkit-transform:translate3d(0,-10px,0) scaleY(.95);transform:translate3d(0,-10px,0) scaleY(.95)}90%{-webkit-transform:translate3d(0,5px,0) scaleY(.985);transform:translate3d(0,5px,0) scaleY(.985)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInDown{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(0,-3000px,0) scaleY(3);transform:translate3d(0,-3000px,0) scaleY(3)}60%{opacity:1;-webkit-transform:translate3d(0,25px,0) scaleY(.9);transform:translate3d(0,25px,0) scaleY(.9)}75%{-webkit-transform:translate3d(0,-10px,0) scaleY(.95);transform:translate3d(0,-10px,0) scaleY(.95)}90%{-webkit-transform:translate3d(0,5px,0) scaleY(.985);transform:translate3d(0,5px,0) scaleY(.985)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__bounceInDown{-webkit-animation-name:bounceInDown;animation-name:bounceInDown}@-webkit-keyframes bounceInLeft{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(-3000px,0,0) scaleX(3);transform:translate3d(-3000px,0,0) scaleX(3)}60%{opacity:1;-webkit-transform:translate3d(25px,0,0) scaleX(1);transform:translate3d(25px,0,0) scaleX(1)}75%{-webkit-transform:translate3d(-10px,0,0) scaleX(.98);transform:translate3d(-10px,0,0) scaleX(.98)}90%{-webkit-transform:translate3d(5px,0,0) scaleX(.995);transform:translate3d(5px,0,0) scaleX(.995)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInLeft{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(-3000px,0,0) scaleX(3);transform:translate3d(-3000px,0,0) scaleX(3)}60%{opacity:1;-webkit-transform:translate3d(25px,0,0) scaleX(1);transform:translate3d(25px,0,0) scaleX(1)}75%{-webkit-transform:translate3d(-10px,0,0) scaleX(.98);transform:translate3d(-10px,0,0) scaleX(.98)}90%{-webkit-transform:translate3d(5px,0,0) scaleX(.995);transform:translate3d(5px,0,0) scaleX(.995)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__bounceInLeft{-webkit-animation-name:bounceInLeft;animation-name:bounceInLeft}@-webkit-keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(3000px,0,0) scaleX(3);transform:translate3d(3000px,0,0) scaleX(3)}60%{opacity:1;-webkit-transform:translate3d(-25px,0,0) scaleX(1);transform:translate3d(-25px,0,0) scaleX(1)}75%{-webkit-transform:translate3d(10px,0,0) scaleX(.98);transform:translate3d(10px,0,0) scaleX(.98)}90%{-webkit-transform:translate3d(-5px,0,0) scaleX(.995);transform:translate3d(-5px,0,0) scaleX(.995)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(3000px,0,0) scaleX(3);transform:translate3d(3000px,0,0) scaleX(3)}60%{opacity:1;-webkit-transform:translate3d(-25px,0,0) scaleX(1);transform:translate3d(-25px,0,0) scaleX(1)}75%{-webkit-transform:translate3d(10px,0,0) scaleX(.98);transform:translate3d(10px,0,0) scaleX(.98)}90%{-webkit-transform:translate3d(-5px,0,0) scaleX(.995);transform:translate3d(-5px,0,0) scaleX(.995)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__bounceInRight{-webkit-animation-name:bounceInRight;animation-name:bounceInRight}@-webkit-keyframes bounceInUp{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(0,3000px,0) scaleY(5);transform:translate3d(0,3000px,0) scaleY(5)}60%{opacity:1;-webkit-transform:translate3d(0,-20px,0) scaleY(.9);transform:translate3d(0,-20px,0) scaleY(.9)}75%{-webkit-transform:translate3d(0,10px,0) scaleY(.95);transform:translate3d(0,10px,0) scaleY(.95)}90%{-webkit-transform:translate3d(0,-5px,0) scaleY(.985);transform:translate3d(0,-5px,0) scaleY(.985)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInUp{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(0,3000px,0) scaleY(5);transform:translate3d(0,3000px,0) scaleY(5)}60%{opacity:1;-webkit-transform:translate3d(0,-20px,0) scaleY(.9);transform:translate3d(0,-20px,0) scaleY(.9)}75%{-webkit-transform:translate3d(0,10px,0) scaleY(.95);transform:translate3d(0,10px,0) scaleY(.95)}90%{-webkit-transform:translate3d(0,-5px,0) scaleY(.985);transform:translate3d(0,-5px,0) scaleY(.985)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__bounceInUp{-webkit-animation-name:bounceInUp;animation-name:bounceInUp}@-webkit-keyframes bounceOut{20%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}to{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}}@keyframes bounceOut{20%{-webkit-transform:scale3d(.9,.9,.9);transform:scale3d(.9,.9,.9)}50%,55%{opacity:1;-webkit-transform:scale3d(1.1,1.1,1.1);transform:scale3d(1.1,1.1,1.1)}to{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}}.animate__bounceOut{-webkit-animation-duration:.75s;animation-duration:.75s;-webkit-animation-duration:calc(var(--animate-duration)*0.75);animation-duration:calc(var(--animate-duration)*0.75);-webkit-animation-name:bounceOut;animation-name:bounceOut}@-webkit-keyframes bounceOutDown{20%{-webkit-transform:translate3d(0,10px,0) scaleY(.985);transform:translate3d(0,10px,0) scaleY(.985)}40%,45%{opacity:1;-webkit-transform:translate3d(0,-20px,0) scaleY(.9);transform:translate3d(0,-20px,0) scaleY(.9)}to{opacity:0;-webkit-transform:translate3d(0,2000px,0) scaleY(3);transform:translate3d(0,2000px,0) scaleY(3)}}@keyframes bounceOutDown{20%{-webkit-transform:translate3d(0,10px,0) scaleY(.985);transform:translate3d(0,10px,0) scaleY(.985)}40%,45%{opacity:1;-webkit-transform:translate3d(0,-20px,0) scaleY(.9);transform:translate3d(0,-20px,0) scaleY(.9)}to{opacity:0;-webkit-transform:translate3d(0,2000px,0) scaleY(3);transform:translate3d(0,2000px,0) scaleY(3)}}.animate__bounceOutDown{-webkit-animation-name:bounceOutDown;animation-name:bounceOutDown}@-webkit-keyframes bounceOutLeft{20%{opacity:1;-webkit-transform:translate3d(20px,0,0) scaleX(.9);transform:translate3d(20px,0,0) scaleX(.9)}to{opacity:0;-webkit-transform:translate3d(-2000px,0,0) scaleX(2);transform:translate3d(-2000px,0,0) scaleX(2)}}@keyframes bounceOutLeft{20%{opacity:1;-webkit-transform:translate3d(20px,0,0) scaleX(.9);transform:translate3d(20px,0,0) scaleX(.9)}to{opacity:0;-webkit-transform:translate3d(-2000px,0,0) scaleX(2);transform:translate3d(-2000px,0,0) scaleX(2)}}.animate__bounceOutLeft{-webkit-animation-name:bounceOutLeft;animation-name:bounceOutLeft}@-webkit-keyframes bounceOutRight{20%{opacity:1;-webkit-transform:translate3d(-20px,0,0) scaleX(.9);transform:translate3d(-20px,0,0) scaleX(.9)}to{opacity:0;-webkit-transform:translate3d(2000px,0,0) scaleX(2);transform:translate3d(2000px,0,0) scaleX(2)}}@keyframes bounceOutRight{20%{opacity:1;-webkit-transform:translate3d(-20px,0,0) scaleX(.9);transform:translate3d(-20px,0,0) scaleX(.9)}to{opacity:0;-webkit-transform:translate3d(2000px,0,0) scaleX(2);transform:translate3d(2000px,0,0) scaleX(2)}}.animate__bounceOutRight{-webkit-animation-name:bounceOutRight;animation-name:bounceOutRight}@-webkit-keyframes bounceOutUp{20%{-webkit-transform:translate3d(0,-10px,0) scaleY(.985);transform:translate3d(0,-10px,0) scaleY(.985)}40%,45%{opacity:1;-webkit-transform:translate3d(0,20px,0) scaleY(.9);transform:translate3d(0,20px,0) scaleY(.9)}to{opacity:0;-webkit-transform:translate3d(0,-2000px,0) scaleY(3);transform:translate3d(0,-2000px,0) scaleY(3)}}@keyframes bounceOutUp{20%{-webkit-transform:translate3d(0,-10px,0) scaleY(.985);transform:translate3d(0,-10px,0) scaleY(.985)}40%,45%{opacity:1;-webkit-transform:translate3d(0,20px,0) scaleY(.9);transform:translate3d(0,20px,0) scaleY(.9)}to{opacity:0;-webkit-transform:translate3d(0,-2000px,0) scaleY(3);transform:translate3d(0,-2000px,0) scaleY(3)}}.animate__bounceOutUp{-webkit-animation-name:bounceOutUp;animation-name:bounceOutUp}@-webkit-keyframes fadeIn{0%{opacity:0}to{opacity:1}}@keyframes fadeIn{0%{opacity:0}to{opacity:1}}.animate__fadeIn{-webkit-animation-name:fadeIn;animation-name:fadeIn}@-webkit-keyframes fadeInDown{0%{opacity:0;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInDown{0%{opacity:0;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInDown{-webkit-animation-name:fadeInDown;animation-name:fadeInDown}@-webkit-keyframes fadeInDownBig{0%{opacity:0;-webkit-transform:translate3d(0,-2000px,0);transform:translate3d(0,-2000px,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInDownBig{0%{opacity:0;-webkit-transform:translate3d(0,-2000px,0);transform:translate3d(0,-2000px,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInDownBig{-webkit-animation-name:fadeInDownBig;animation-name:fadeInDownBig}@-webkit-keyframes fadeInLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInLeft{-webkit-animation-name:fadeInLeft;animation-name:fadeInLeft}@-webkit-keyframes fadeInLeftBig{0%{opacity:0;-webkit-transform:translate3d(-2000px,0,0);transform:translate3d(-2000px,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInLeftBig{0%{opacity:0;-webkit-transform:translate3d(-2000px,0,0);transform:translate3d(-2000px,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInLeftBig{-webkit-animation-name:fadeInLeftBig;animation-name:fadeInLeftBig}@-webkit-keyframes fadeInRight{0%{opacity:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInRight{0%{opacity:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInRight{-webkit-animation-name:fadeInRight;animation-name:fadeInRight}@-webkit-keyframes fadeInRightBig{0%{opacity:0;-webkit-transform:translate3d(2000px,0,0);transform:translate3d(2000px,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInRightBig{0%{opacity:0;-webkit-transform:translate3d(2000px,0,0);transform:translate3d(2000px,0,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInRightBig{-webkit-animation-name:fadeInRightBig;animation-name:fadeInRightBig}@-webkit-keyframes fadeInUp{0%{opacity:0;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInUp{0%{opacity:0;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInUp{-webkit-animation-name:fadeInUp;animation-name:fadeInUp}@-webkit-keyframes fadeInUpBig{0%{opacity:0;-webkit-transform:translate3d(0,2000px,0);transform:translate3d(0,2000px,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInUpBig{0%{opacity:0;-webkit-transform:translate3d(0,2000px,0);transform:translate3d(0,2000px,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInUpBig{-webkit-animation-name:fadeInUpBig;animation-name:fadeInUpBig}@-webkit-keyframes fadeInTopLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,-100%,0);transform:translate3d(-100%,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInTopLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,-100%,0);transform:translate3d(-100%,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInTopLeft{-webkit-animation-name:fadeInTopLeft;animation-name:fadeInTopLeft}@-webkit-keyframes fadeInTopRight{0%{opacity:0;-webkit-transform:translate3d(100%,-100%,0);transform:translate3d(100%,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInTopRight{0%{opacity:0;-webkit-transform:translate3d(100%,-100%,0);transform:translate3d(100%,-100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInTopRight{-webkit-animation-name:fadeInTopRight;animation-name:fadeInTopRight}@-webkit-keyframes fadeInBottomLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,100%,0);transform:translate3d(-100%,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInBottomLeft{0%{opacity:0;-webkit-transform:translate3d(-100%,100%,0);transform:translate3d(-100%,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInBottomLeft{-webkit-animation-name:fadeInBottomLeft;animation-name:fadeInBottomLeft}@-webkit-keyframes fadeInBottomRight{0%{opacity:0;-webkit-transform:translate3d(100%,100%,0);transform:translate3d(100%,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes fadeInBottomRight{0%{opacity:0;-webkit-transform:translate3d(100%,100%,0);transform:translate3d(100%,100%,0)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__fadeInBottomRight{-webkit-animation-name:fadeInBottomRight;animation-name:fadeInBottomRight}@-webkit-keyframes fadeOut{0%{opacity:1}to{opacity:0}}@keyframes fadeOut{0%{opacity:1}to{opacity:0}}.animate__fadeOut{-webkit-animation-name:fadeOut;animation-name:fadeOut}@-webkit-keyframes fadeOutDown{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@keyframes fadeOutDown{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}.animate__fadeOutDown{-webkit-animation-name:fadeOutDown;animation-name:fadeOutDown}@-webkit-keyframes fadeOutDownBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,2000px,0);transform:translate3d(0,2000px,0)}}@keyframes fadeOutDownBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,2000px,0);transform:translate3d(0,2000px,0)}}.animate__fadeOutDownBig{-webkit-animation-name:fadeOutDownBig;animation-name:fadeOutDownBig}@-webkit-keyframes fadeOutLeft{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@keyframes fadeOutLeft{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}.animate__fadeOutLeft{-webkit-animation-name:fadeOutLeft;animation-name:fadeOutLeft}@-webkit-keyframes fadeOutLeftBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(-2000px,0,0);transform:translate3d(-2000px,0,0)}}@keyframes fadeOutLeftBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(-2000px,0,0);transform:translate3d(-2000px,0,0)}}.animate__fadeOutLeftBig{-webkit-animation-name:fadeOutLeftBig;animation-name:fadeOutLeftBig}@-webkit-keyframes fadeOutRight{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@keyframes fadeOutRight{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}.animate__fadeOutRight{-webkit-animation-name:fadeOutRight;animation-name:fadeOutRight}@-webkit-keyframes fadeOutRightBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(2000px,0,0);transform:translate3d(2000px,0,0)}}@keyframes fadeOutRightBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(2000px,0,0);transform:translate3d(2000px,0,0)}}.animate__fadeOutRightBig{-webkit-animation-name:fadeOutRightBig;animation-name:fadeOutRightBig}@-webkit-keyframes fadeOutUp{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@keyframes fadeOutUp{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}.animate__fadeOutUp{-webkit-animation-name:fadeOutUp;animation-name:fadeOutUp}@-webkit-keyframes fadeOutUpBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,-2000px,0);transform:translate3d(0,-2000px,0)}}@keyframes fadeOutUpBig{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(0,-2000px,0);transform:translate3d(0,-2000px,0)}}.animate__fadeOutUpBig{-webkit-animation-name:fadeOutUpBig;animation-name:fadeOutUpBig}@-webkit-keyframes fadeOutTopLeft{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(-100%,-100%,0);transform:translate3d(-100%,-100%,0)}}@keyframes fadeOutTopLeft{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(-100%,-100%,0);transform:translate3d(-100%,-100%,0)}}.animate__fadeOutTopLeft{-webkit-animation-name:fadeOutTopLeft;animation-name:fadeOutTopLeft}@-webkit-keyframes fadeOutTopRight{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(100%,-100%,0);transform:translate3d(100%,-100%,0)}}@keyframes fadeOutTopRight{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(100%,-100%,0);transform:translate3d(100%,-100%,0)}}.animate__fadeOutTopRight{-webkit-animation-name:fadeOutTopRight;animation-name:fadeOutTopRight}@-webkit-keyframes fadeOutBottomRight{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(100%,100%,0);transform:translate3d(100%,100%,0)}}@keyframes fadeOutBottomRight{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(100%,100%,0);transform:translate3d(100%,100%,0)}}.animate__fadeOutBottomRight{-webkit-animation-name:fadeOutBottomRight;animation-name:fadeOutBottomRight}@-webkit-keyframes fadeOutBottomLeft{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(-100%,100%,0);transform:translate3d(-100%,100%,0)}}@keyframes fadeOutBottomLeft{0%{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}to{opacity:0;-webkit-transform:translate3d(-100%,100%,0);transform:translate3d(-100%,100%,0)}}.animate__fadeOutBottomLeft{-webkit-animation-name:fadeOutBottomLeft;animation-name:fadeOutBottomLeft}@-webkit-keyframes flip{0%{-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}40%{-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}50%{-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}80%{-webkit-transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}to{-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}}@keyframes flip{0%{-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);transform:perspective(400px) scaleX(1) translateZ(0) rotateY(-1turn);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}40%{-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-190deg);-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}50%{-webkit-transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);transform:perspective(400px) scaleX(1) translateZ(150px) rotateY(-170deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}80%{-webkit-transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);transform:perspective(400px) scale3d(.95,.95,.95) translateZ(0) rotateY(0deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}to{-webkit-transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);transform:perspective(400px) scaleX(1) translateZ(0) rotateY(0deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}}.animate__animated.animate__flip{-webkit-backface-visibility:visible;backface-visibility:visible;-webkit-animation-name:flip;animation-name:flip}@-webkit-keyframes flipInX{0%{-webkit-transform:perspective(400px) rotateX(90deg);transform:perspective(400px) rotateX(90deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in;opacity:0}40%{-webkit-transform:perspective(400px) rotateX(-20deg);transform:perspective(400px) rotateX(-20deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}60%{-webkit-transform:perspective(400px) rotateX(10deg);transform:perspective(400px) rotateX(10deg);opacity:1}80%{-webkit-transform:perspective(400px) rotateX(-5deg);transform:perspective(400px) rotateX(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}@keyframes flipInX{0%{-webkit-transform:perspective(400px) rotateX(90deg);transform:perspective(400px) rotateX(90deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in;opacity:0}40%{-webkit-transform:perspective(400px) rotateX(-20deg);transform:perspective(400px) rotateX(-20deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}60%{-webkit-transform:perspective(400px) rotateX(10deg);transform:perspective(400px) rotateX(10deg);opacity:1}80%{-webkit-transform:perspective(400px) rotateX(-5deg);transform:perspective(400px) rotateX(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}.animate__flipInX{-webkit-backface-visibility:visible!important;backface-visibility:visible!important;-webkit-animation-name:flipInX;animation-name:flipInX}@-webkit-keyframes flipInY{0%{-webkit-transform:perspective(400px) rotateY(90deg);transform:perspective(400px) rotateY(90deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in;opacity:0}40%{-webkit-transform:perspective(400px) rotateY(-20deg);transform:perspective(400px) rotateY(-20deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}60%{-webkit-transform:perspective(400px) rotateY(10deg);transform:perspective(400px) rotateY(10deg);opacity:1}80%{-webkit-transform:perspective(400px) rotateY(-5deg);transform:perspective(400px) rotateY(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}@keyframes flipInY{0%{-webkit-transform:perspective(400px) rotateY(90deg);transform:perspective(400px) rotateY(90deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in;opacity:0}40%{-webkit-transform:perspective(400px) rotateY(-20deg);transform:perspective(400px) rotateY(-20deg);-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}60%{-webkit-transform:perspective(400px) rotateY(10deg);transform:perspective(400px) rotateY(10deg);opacity:1}80%{-webkit-transform:perspective(400px) rotateY(-5deg);transform:perspective(400px) rotateY(-5deg)}to{-webkit-transform:perspective(400px);transform:perspective(400px)}}.animate__flipInY{-webkit-backface-visibility:visible!important;backface-visibility:visible!important;-webkit-animation-name:flipInY;animation-name:flipInY}@-webkit-keyframes flipOutX{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateX(-20deg);transform:perspective(400px) rotateX(-20deg);opacity:1}to{-webkit-transform:perspective(400px) rotateX(90deg);transform:perspective(400px) rotateX(90deg);opacity:0}}@keyframes flipOutX{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateX(-20deg);transform:perspective(400px) rotateX(-20deg);opacity:1}to{-webkit-transform:perspective(400px) rotateX(90deg);transform:perspective(400px) rotateX(90deg);opacity:0}}.animate__flipOutX{-webkit-animation-duration:.75s;animation-duration:.75s;-webkit-animation-duration:calc(var(--animate-duration)*0.75);animation-duration:calc(var(--animate-duration)*0.75);-webkit-animation-name:flipOutX;animation-name:flipOutX;-webkit-backface-visibility:visible!important;backface-visibility:visible!important}@-webkit-keyframes flipOutY{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateY(-15deg);transform:perspective(400px) rotateY(-15deg);opacity:1}to{-webkit-transform:perspective(400px) rotateY(90deg);transform:perspective(400px) rotateY(90deg);opacity:0}}@keyframes flipOutY{0%{-webkit-transform:perspective(400px);transform:perspective(400px)}30%{-webkit-transform:perspective(400px) rotateY(-15deg);transform:perspective(400px) rotateY(-15deg);opacity:1}to{-webkit-transform:perspective(400px) rotateY(90deg);transform:perspective(400px) rotateY(90deg);opacity:0}}.animate__flipOutY{-webkit-animation-duration:.75s;animation-duration:.75s;-webkit-animation-duration:calc(var(--animate-duration)*0.75);animation-duration:calc(var(--animate-duration)*0.75);-webkit-backface-visibility:visible!important;backface-visibility:visible!important;-webkit-animation-name:flipOutY;animation-name:flipOutY}@-webkit-keyframes lightSpeedInRight{0%{-webkit-transform:translate3d(100%,0,0) skewX(-30deg);transform:translate3d(100%,0,0) skewX(-30deg);opacity:0}60%{-webkit-transform:skewX(20deg);transform:skewX(20deg);opacity:1}80%{-webkit-transform:skewX(-5deg);transform:skewX(-5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes lightSpeedInRight{0%{-webkit-transform:translate3d(100%,0,0) skewX(-30deg);transform:translate3d(100%,0,0) skewX(-30deg);opacity:0}60%{-webkit-transform:skewX(20deg);transform:skewX(20deg);opacity:1}80%{-webkit-transform:skewX(-5deg);transform:skewX(-5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__lightSpeedInRight{-webkit-animation-name:lightSpeedInRight;animation-name:lightSpeedInRight;-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}@-webkit-keyframes lightSpeedInLeft{0%{-webkit-transform:translate3d(-100%,0,0) skewX(30deg);transform:translate3d(-100%,0,0) skewX(30deg);opacity:0}60%{-webkit-transform:skewX(-20deg);transform:skewX(-20deg);opacity:1}80%{-webkit-transform:skewX(5deg);transform:skewX(5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes lightSpeedInLeft{0%{-webkit-transform:translate3d(-100%,0,0) skewX(30deg);transform:translate3d(-100%,0,0) skewX(30deg);opacity:0}60%{-webkit-transform:skewX(-20deg);transform:skewX(-20deg);opacity:1}80%{-webkit-transform:skewX(5deg);transform:skewX(5deg)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__lightSpeedInLeft{-webkit-animation-name:lightSpeedInLeft;animation-name:lightSpeedInLeft;-webkit-animation-timing-function:ease-out;animation-timing-function:ease-out}@-webkit-keyframes lightSpeedOutRight{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) skewX(30deg);transform:translate3d(100%,0,0) skewX(30deg);opacity:0}}@keyframes lightSpeedOutRight{0%{opacity:1}to{-webkit-transform:translate3d(100%,0,0) skewX(30deg);transform:translate3d(100%,0,0) skewX(30deg);opacity:0}}.animate__lightSpeedOutRight{-webkit-animation-name:lightSpeedOutRight;animation-name:lightSpeedOutRight;-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}@-webkit-keyframes lightSpeedOutLeft{0%{opacity:1}to{-webkit-transform:translate3d(-100%,0,0) skewX(-30deg);transform:translate3d(-100%,0,0) skewX(-30deg);opacity:0}}@keyframes lightSpeedOutLeft{0%{opacity:1}to{-webkit-transform:translate3d(-100%,0,0) skewX(-30deg);transform:translate3d(-100%,0,0) skewX(-30deg);opacity:0}}.animate__lightSpeedOutLeft{-webkit-animation-name:lightSpeedOutLeft;animation-name:lightSpeedOutLeft;-webkit-animation-timing-function:ease-in;animation-timing-function:ease-in}@-webkit-keyframes rotateIn{0%{-webkit-transform:rotate(-200deg);transform:rotate(-200deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}@keyframes rotateIn{0%{-webkit-transform:rotate(-200deg);transform:rotate(-200deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}.animate__rotateIn{-webkit-animation-name:rotateIn;animation-name:rotateIn;-webkit-transform-origin:center;transform-origin:center}@-webkit-keyframes rotateInDownLeft{0%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}@keyframes rotateInDownLeft{0%{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}.animate__rotateInDownLeft{-webkit-animation-name:rotateInDownLeft;animation-name:rotateInDownLeft;-webkit-transform-origin:left bottom;transform-origin:left bottom}@-webkit-keyframes rotateInDownRight{0%{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}@keyframes rotateInDownRight{0%{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}.animate__rotateInDownRight{-webkit-animation-name:rotateInDownRight;animation-name:rotateInDownRight;-webkit-transform-origin:right bottom;transform-origin:right bottom}@-webkit-keyframes rotateInUpLeft{0%{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}@keyframes rotateInUpLeft{0%{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}.animate__rotateInUpLeft{-webkit-animation-name:rotateInUpLeft;animation-name:rotateInUpLeft;-webkit-transform-origin:left bottom;transform-origin:left bottom}@-webkit-keyframes rotateInUpRight{0%{-webkit-transform:rotate(-90deg);transform:rotate(-90deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}@keyframes rotateInUpRight{0%{-webkit-transform:rotate(-90deg);transform:rotate(-90deg);opacity:0}to{-webkit-transform:translateZ(0);transform:translateZ(0);opacity:1}}.animate__rotateInUpRight{-webkit-animation-name:rotateInUpRight;animation-name:rotateInUpRight;-webkit-transform-origin:right bottom;transform-origin:right bottom}@-webkit-keyframes rotateOut{0%{opacity:1}to{-webkit-transform:rotate(200deg);transform:rotate(200deg);opacity:0}}@keyframes rotateOut{0%{opacity:1}to{-webkit-transform:rotate(200deg);transform:rotate(200deg);opacity:0}}.animate__rotateOut{-webkit-animation-name:rotateOut;animation-name:rotateOut;-webkit-transform-origin:center;transform-origin:center}@-webkit-keyframes rotateOutDownLeft{0%{opacity:1}to{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}}@keyframes rotateOutDownLeft{0%{opacity:1}to{-webkit-transform:rotate(45deg);transform:rotate(45deg);opacity:0}}.animate__rotateOutDownLeft{-webkit-animation-name:rotateOutDownLeft;animation-name:rotateOutDownLeft;-webkit-transform-origin:left bottom;transform-origin:left bottom}@-webkit-keyframes rotateOutDownRight{0%{opacity:1}to{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}}@keyframes rotateOutDownRight{0%{opacity:1}to{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}}.animate__rotateOutDownRight{-webkit-animation-name:rotateOutDownRight;animation-name:rotateOutDownRight;-webkit-transform-origin:right bottom;transform-origin:right bottom}@-webkit-keyframes rotateOutUpLeft{0%{opacity:1}to{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}}@keyframes rotateOutUpLeft{0%{opacity:1}to{-webkit-transform:rotate(-45deg);transform:rotate(-45deg);opacity:0}}.animate__rotateOutUpLeft{-webkit-animation-name:rotateOutUpLeft;animation-name:rotateOutUpLeft;-webkit-transform-origin:left bottom;transform-origin:left bottom}@-webkit-keyframes rotateOutUpRight{0%{opacity:1}to{-webkit-transform:rotate(90deg);transform:rotate(90deg);opacity:0}}@keyframes rotateOutUpRight{0%{opacity:1}to{-webkit-transform:rotate(90deg);transform:rotate(90deg);opacity:0}}.animate__rotateOutUpRight{-webkit-animation-name:rotateOutUpRight;animation-name:rotateOutUpRight;-webkit-transform-origin:right bottom;transform-origin:right bottom}@-webkit-keyframes hinge{0%{-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}20%,60%{-webkit-transform:rotate(80deg);transform:rotate(80deg);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}40%,80%{-webkit-transform:rotate(60deg);transform:rotate(60deg);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out;opacity:1}to{-webkit-transform:translate3d(0,700px,0);transform:translate3d(0,700px,0);opacity:0}}@keyframes hinge{0%{-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}20%,60%{-webkit-transform:rotate(80deg);transform:rotate(80deg);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out}40%,80%{-webkit-transform:rotate(60deg);transform:rotate(60deg);-webkit-animation-timing-function:ease-in-out;animation-timing-function:ease-in-out;opacity:1}to{-webkit-transform:translate3d(0,700px,0);transform:translate3d(0,700px,0);opacity:0}}.animate__hinge{-webkit-animation-duration:2s;animation-duration:2s;-webkit-animation-duration:calc(var(--animate-duration)*2);animation-duration:calc(var(--animate-duration)*2);-webkit-animation-name:hinge;animation-name:hinge;-webkit-transform-origin:top left;transform-origin:top left}@-webkit-keyframes jackInTheBox{0%{opacity:0;-webkit-transform:scale(.1) rotate(30deg);transform:scale(.1) rotate(30deg);-webkit-transform-origin:center bottom;transform-origin:center bottom}50%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}70%{-webkit-transform:rotate(3deg);transform:rotate(3deg)}to{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}@keyframes jackInTheBox{0%{opacity:0;-webkit-transform:scale(.1) rotate(30deg);transform:scale(.1) rotate(30deg);-webkit-transform-origin:center bottom;transform-origin:center bottom}50%{-webkit-transform:rotate(-10deg);transform:rotate(-10deg)}70%{-webkit-transform:rotate(3deg);transform:rotate(3deg)}to{opacity:1;-webkit-transform:scale(1);transform:scale(1)}}.animate__jackInTheBox{-webkit-animation-name:jackInTheBox;animation-name:jackInTheBox}@-webkit-keyframes rollIn{0%{opacity:0;-webkit-transform:translate3d(-100%,0,0) rotate(-120deg);transform:translate3d(-100%,0,0) rotate(-120deg)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes rollIn{0%{opacity:0;-webkit-transform:translate3d(-100%,0,0) rotate(-120deg);transform:translate3d(-100%,0,0) rotate(-120deg)}to{opacity:1;-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__rollIn{-webkit-animation-name:rollIn;animation-name:rollIn}@-webkit-keyframes rollOut{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(100%,0,0) rotate(120deg);transform:translate3d(100%,0,0) rotate(120deg)}}@keyframes rollOut{0%{opacity:1}to{opacity:0;-webkit-transform:translate3d(100%,0,0) rotate(120deg);transform:translate3d(100%,0,0) rotate(120deg)}}.animate__rollOut{-webkit-animation-name:rollOut;animation-name:rollOut}@-webkit-keyframes zoomIn{0%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes zoomIn{0%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}50%{opacity:1}}.animate__zoomIn{-webkit-animation-name:zoomIn;animation-name:zoomIn}@-webkit-keyframes zoomInDown{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);transform:scale3d(.475,.475,.475) translate3d(0,60px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomInDown{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);transform:scale3d(.1,.1,.1) translate3d(0,-1000px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);transform:scale3d(.475,.475,.475) translate3d(0,60px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomInDown{-webkit-animation-name:zoomInDown;animation-name:zoomInDown}@-webkit-keyframes zoomInLeft{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(10px,0,0);transform:scale3d(.475,.475,.475) translate3d(10px,0,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomInLeft{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);transform:scale3d(.1,.1,.1) translate3d(-1000px,0,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(10px,0,0);transform:scale3d(.475,.475,.475) translate3d(10px,0,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomInLeft{-webkit-animation-name:zoomInLeft;animation-name:zoomInLeft}@-webkit-keyframes zoomInRight{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomInRight{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);transform:scale3d(.1,.1,.1) translate3d(1000px,0,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);transform:scale3d(.475,.475,.475) translate3d(-10px,0,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomInRight{-webkit-animation-name:zoomInRight;animation-name:zoomInRight}@-webkit-keyframes zoomInUp{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomInUp{0%{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);transform:scale3d(.1,.1,.1) translate3d(0,1000px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}60%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomInUp{-webkit-animation-name:zoomInUp;animation-name:zoomInUp}@-webkit-keyframes zoomOut{0%{opacity:1}50%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}to{opacity:0}}@keyframes zoomOut{0%{opacity:1}50%{opacity:0;-webkit-transform:scale3d(.3,.3,.3);transform:scale3d(.3,.3,.3)}to{opacity:0}}.animate__zoomOut{-webkit-animation-name:zoomOut;animation-name:zoomOut}@-webkit-keyframes zoomOutDown{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}to{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomOutDown{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);transform:scale3d(.475,.475,.475) translate3d(0,-60px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}to{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);transform:scale3d(.1,.1,.1) translate3d(0,2000px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomOutDown{-webkit-animation-name:zoomOutDown;animation-name:zoomOutDown;-webkit-transform-origin:center bottom;transform-origin:center bottom}@-webkit-keyframes zoomOutLeft{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(42px,0,0);transform:scale3d(.475,.475,.475) translate3d(42px,0,0)}to{opacity:0;-webkit-transform:scale(.1) translate3d(-2000px,0,0);transform:scale(.1) translate3d(-2000px,0,0)}}@keyframes zoomOutLeft{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(42px,0,0);transform:scale3d(.475,.475,.475) translate3d(42px,0,0)}to{opacity:0;-webkit-transform:scale(.1) translate3d(-2000px,0,0);transform:scale(.1) translate3d(-2000px,0,0)}}.animate__zoomOutLeft{-webkit-animation-name:zoomOutLeft;animation-name:zoomOutLeft;-webkit-transform-origin:left center;transform-origin:left center}@-webkit-keyframes zoomOutRight{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(-42px,0,0);transform:scale3d(.475,.475,.475) translate3d(-42px,0,0)}to{opacity:0;-webkit-transform:scale(.1) translate3d(2000px,0,0);transform:scale(.1) translate3d(2000px,0,0)}}@keyframes zoomOutRight{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(-42px,0,0);transform:scale3d(.475,.475,.475) translate3d(-42px,0,0)}to{opacity:0;-webkit-transform:scale(.1) translate3d(2000px,0,0);transform:scale(.1) translate3d(2000px,0,0)}}.animate__zoomOutRight{-webkit-animation-name:zoomOutRight;animation-name:zoomOutRight;-webkit-transform-origin:right center;transform-origin:right center}@-webkit-keyframes zoomOutUp{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);transform:scale3d(.475,.475,.475) translate3d(0,60px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}to{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}@keyframes zoomOutUp{40%{opacity:1;-webkit-transform:scale3d(.475,.475,.475) translate3d(0,60px,0);transform:scale3d(.475,.475,.475) translate3d(0,60px,0);-webkit-animation-timing-function:cubic-bezier(.55,.055,.675,.19);animation-timing-function:cubic-bezier(.55,.055,.675,.19)}to{opacity:0;-webkit-transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);transform:scale3d(.1,.1,.1) translate3d(0,-2000px,0);-webkit-animation-timing-function:cubic-bezier(.175,.885,.32,1);animation-timing-function:cubic-bezier(.175,.885,.32,1)}}.animate__zoomOutUp{-webkit-animation-name:zoomOutUp;animation-name:zoomOutUp;-webkit-transform-origin:center bottom;transform-origin:center bottom}@-webkit-keyframes slideInDown{0%{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInDown{0%{-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__slideInDown{-webkit-animation-name:slideInDown;animation-name:slideInDown}@-webkit-keyframes slideInLeft{0%{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInLeft{0%{-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__slideInLeft{-webkit-animation-name:slideInLeft;animation-name:slideInLeft}@-webkit-keyframes slideInRight{0%{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInRight{0%{-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__slideInRight{-webkit-animation-name:slideInRight;animation-name:slideInRight}@-webkit-keyframes slideInUp{0%{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes slideInUp{0%{-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0);visibility:visible}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.animate__slideInUp{-webkit-animation-name:slideInUp;animation-name:slideInUp}@-webkit-keyframes slideOutDown{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}@keyframes slideOutDown{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(0,100%,0);transform:translate3d(0,100%,0)}}.animate__slideOutDown{-webkit-animation-name:slideOutDown;animation-name:slideOutDown}@-webkit-keyframes slideOutLeft{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}@keyframes slideOutLeft{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(-100%,0,0);transform:translate3d(-100%,0,0)}}.animate__slideOutLeft{-webkit-animation-name:slideOutLeft;animation-name:slideOutLeft}@-webkit-keyframes slideOutRight{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}@keyframes slideOutRight{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(100%,0,0);transform:translate3d(100%,0,0)}}.animate__slideOutRight{-webkit-animation-name:slideOutRight;animation-name:slideOutRight}@-webkit-keyframes slideOutUp{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}@keyframes slideOutUp{0%{-webkit-transform:translateZ(0);transform:translateZ(0)}to{visibility:hidden;-webkit-transform:translate3d(0,-100%,0);transform:translate3d(0,-100%,0)}}.animate__slideOutUp{-webkit-animation-name:slideOutUp;animation-name:slideOutUp}
\ No newline at end of file
diff --git a/public/css/base.css b/public/css/base.css
deleted file mode 100644
index deec8cf..0000000
--- a/public/css/base.css
+++ /dev/null
@@ -1,7 +0,0 @@
-body{
- background-color: #000;
-}
-
-.n-popover:has(.music-play){
- border-radius: 1.5rem !important;
-}
\ No newline at end of file
diff --git a/public/icon/iconfont.js b/public/icon/iconfont.js
deleted file mode 100644
index d905a33..0000000
--- a/public/icon/iconfont.js
+++ /dev/null
@@ -1 +0,0 @@
-window._iconfont_svg_string_2685283='',function(a){var c=(c=document.getElementsByTagName("script"))[c.length-1],l=c.getAttribute("data-injectcss"),c=c.getAttribute("data-disable-injectsvg");if(!c){var o,i,t,h,s,d=function(c,l){l.parentNode.insertBefore(c,l)};if(l&&!a.__iconfont__svg__cssinject__){a.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(c){console&&console.log(c)}}o=function(){var c,l=document.createElement("div");l.innerHTML=a._iconfont_svg_string_2685283,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(c=document.body).firstChild?d(l,c.firstChild):c.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(o,0):(i=function(){document.removeEventListener("DOMContentLoaded",i,!1),o()},document.addEventListener("DOMContentLoaded",i,!1)):document.attachEvent&&(t=o,h=a.document,s=!1,e(),h.onreadystatechange=function(){"complete"==h.readyState&&(h.onreadystatechange=null,p())})}function p(){s||(s=!0,t())}function e(){try{h.documentElement.doScroll("left")}catch(c){return void setTimeout(e,50)}p()}}(window);
\ No newline at end of file
diff --git a/public/icon1.png b/public/icon1.png
deleted file mode 100644
index dd34e79..0000000
Binary files a/public/icon1.png and /dev/null differ
diff --git a/public/favicon.ico b/resources/favicon.ico
similarity index 100%
rename from public/favicon.ico
rename to resources/favicon.ico
diff --git a/public/icon.icns b/resources/icon.icns
similarity index 100%
rename from public/icon.icns
rename to resources/icon.icns
diff --git a/src/assets/logo.png b/resources/icon.png
similarity index 100%
rename from src/assets/logo.png
rename to resources/icon.png
diff --git a/public/icon_16x16.png b/resources/icon_16x16.png
similarity index 100%
rename from public/icon_16x16.png
rename to resources/icon_16x16.png
diff --git a/public/manifest.json b/resources/manifest.json
similarity index 100%
rename from public/manifest.json
rename to resources/manifest.json
diff --git a/src/electron.d.ts b/src/electron.d.ts
deleted file mode 100644
index 393602f..0000000
--- a/src/electron.d.ts
+++ /dev/null
@@ -1,10 +0,0 @@
-declare global {
- interface Window {
- electronAPI: {
- minimize: () => void;
- maximize: () => void;
- close: () => void;
- dragStart: () => void;
- };
- }
-}
diff --git a/src/main/index.ts b/src/main/index.ts
new file mode 100644
index 0000000..65ee5cc
--- /dev/null
+++ b/src/main/index.ts
@@ -0,0 +1,205 @@
+import { electronApp, is, optimizer } from '@electron-toolkit/utils';
+import { app, BrowserWindow, globalShortcut, ipcMain, Menu, nativeImage, shell, Tray } from 'electron';
+import Store from 'electron-store';
+import { join } from 'path';
+import set from './set.json';
+// 导入所有图标
+const iconPath = join(__dirname, '../../resources');
+const icon = nativeImage.createFromPath(
+ process.platform === 'darwin'
+ ? join(iconPath, 'icon.icns')
+ : process.platform === 'win32'
+ ? join(iconPath, 'favicon.ico')
+ : join(iconPath, 'icon.png')
+);
+
+import { loadLyricWindow } from './lyric';
+import { startMusicApi } from './server';
+
+let mainWindow: BrowserWindow;
+function createWindow(): void {
+ startMusicApi();
+ // Create the browser window.
+ mainWindow = new BrowserWindow({
+ width: 1200,
+ height: 780,
+ show: false,
+ frame: false,
+ autoHideMenuBar: true,
+ icon,
+ webPreferences: {
+ preload: join(__dirname, '../preload/index.js'),
+ sandbox: false,
+ contextIsolation: true
+ }
+ });
+
+ mainWindow.setMinimumSize(1200, 780);
+
+ mainWindow.on('ready-to-show', () => {
+ mainWindow.show();
+ });
+
+ mainWindow.webContents.setWindowOpenHandler((details) => {
+ shell.openExternal(details.url);
+ return { action: 'deny' };
+ });
+
+ // HMR for renderer base on electron-vite cli.
+ // Load the remote URL for development or the local html file for production.
+ if (is.dev && process.env.ELECTRON_RENDERER_URL) {
+ mainWindow.webContents.openDevTools({ mode: 'detach' });
+ mainWindow.loadURL(process.env.ELECTRON_RENDERER_URL);
+ } else {
+ mainWindow.webContents.openDevTools({ mode: 'detach' });
+ mainWindow.loadFile(join(__dirname, '../renderer/index.html'));
+ }
+
+ // 创建托盘图标
+ const trayIcon = nativeImage.createFromPath(join(iconPath, 'icon_16x16.png')).resize({ width: 16, height: 16 });
+ const tray = new Tray(trayIcon);
+
+ // 创建一个上下文菜单
+ const contextMenu = Menu.buildFromTemplate([
+ {
+ label: '显示',
+ click: () => {
+ mainWindow.show();
+ },
+ },
+ {
+ label: '退出',
+ click: () => {
+ mainWindow.destroy();
+ app.quit();
+ },
+ },
+ ]);
+
+ // 设置系统托盘图标的上下文菜单
+ tray.setContextMenu(contextMenu);
+
+ // 当系统托盘图标被点击时,切换窗口的显示/隐藏
+ tray.on('click', () => {
+ if (mainWindow.isVisible()) {
+ mainWindow.hide();
+ } else {
+ mainWindow.show();
+ }
+ });
+
+ loadLyricWindow(ipcMain, mainWindow);
+}
+
+// This method will be called when Electron has finished
+// initialization and is ready to create browser windows.
+// Some APIs can only be used after this event occurs.
+app.whenReady().then(() => {
+ // Set app user model id for windows
+ electronApp.setAppUserModelId('com.alger.music');
+
+ // Default open or close DevTools by F12 in development
+ // and ignore CommandOrControl + R in production.
+ // see https://github.com/alex8088/electron-toolkit/tree/master/packages/utils
+ app.on('browser-window-created', (_, window) => {
+ optimizer.watchWindowShortcuts(window);
+ });
+
+ // IPC test
+ ipcMain.on('ping', () => console.log('pong'));
+
+ createWindow();
+
+ app.on('activate', function () {
+ // On macOS it's common to re-create a window in the app when the
+ // dock icon is clicked and there are no other windows open.
+ if (BrowserWindow.getAllWindows().length === 0) createWindow();
+ });
+});
+
+app.on('ready', () => {
+ globalShortcut.register('CommandOrControl+Alt+Shift+M', () => {
+ if (mainWindow.isVisible()) {
+ mainWindow.hide();
+ } else {
+ mainWindow.show();
+ }
+ });
+});
+
+// Quit when all windows are closed, except on macOS. There, it's common
+// for applications and their menu bar to stay active until the user quits
+// explicitly with Cmd + Q.
+app.on('window-all-closed', () => {
+ if (process.platform !== 'darwin') {
+ app.quit();
+ }
+});
+
+ipcMain.on('minimize-window', (event) => {
+ const win = BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.minimize();
+ }
+});
+
+ipcMain.on('maximize-window', (event) => {
+ const win = BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ if (win.isMaximized()) {
+ win.unmaximize();
+ } else {
+ win.maximize();
+ }
+ }
+});
+
+ipcMain.on('close-window', (event) => {
+ const win = BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.destroy();
+ app.quit();
+ }
+});
+
+ipcMain.on('drag-start', (event) => {
+ const win = BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.webContents.beginFrameSubscription((frameBuffer) => {
+ event.reply('frame-buffer', frameBuffer);
+ });
+ }
+});
+
+ipcMain.on('mini-tray', (event) => {
+ const win = BrowserWindow.fromWebContents(event.sender);
+ if (win) {
+ win.hide();
+ }
+});
+
+// 重启
+ipcMain.on('restart', () => {
+ app.relaunch();
+ app.exit(0);
+});
+
+const store = new Store({
+ name: 'config', // 配置文件名
+ defaults: {
+ set: set
+ }
+});
+
+// 定义ipcRenderer监听事件
+ipcMain.on('set-store-value', (_, key, value) => {
+ store.set(key, value);
+});
+
+ipcMain.on('get-store-value', (_, key) => {
+ const value = store.get(key);
+ _.returnValue = value || '';
+});
+
+// In this file you can include the rest of your app"s specific main process
+// code. You can also put them in separate files and require them here.
diff --git a/electron/lyric.js b/src/main/lyric.ts
similarity index 52%
rename from electron/lyric.js
rename to src/main/lyric.ts
index c35e308..d684d23 100644
--- a/electron/lyric.js
+++ b/src/main/lyric.ts
@@ -1,23 +1,29 @@
-const { BrowserWindow, screen } = require('electron');
-const path = require('path');
-const Store = require('electron-store');
-const config = require('./config');
+import { BrowserWindow, IpcMain, screen } from 'electron';
+import Store from 'electron-store';
+import path, { join } from 'path';
const store = new Store();
-let lyricWindow = null;
+let lyricWindow: BrowserWindow | null = null;
const createWin = () => {
console.log('Creating lyric window');
// 获取保存的窗口位置
- const windowBounds = store.get('lyricWindowBounds') || {};
+ const windowBounds =
+ (store.get('lyricWindowBounds') as {
+ x?: number;
+ y?: number;
+ width?: number;
+ height?: number;
+ }) || {};
const { x, y, width, height } = windowBounds;
// 获取屏幕尺寸
const { width: screenWidth, height: screenHeight } = screen.getPrimaryDisplay().workAreaSize;
// 验证保存的位置是否有效
- const validPosition = x !== undefined && y !== undefined && x >= 0 && y >= 0 && x < screenWidth && y < screenHeight;
+ const validPosition =
+ x !== undefined && y !== undefined && x >= 0 && y >= 0 && x < screenWidth && y < screenHeight;
lyricWindow = new BrowserWindow({
width: width || 800,
@@ -30,63 +36,79 @@ const createWin = () => {
hasShadow: false,
alwaysOnTop: true,
webPreferences: {
- nodeIntegration: false,
- contextIsolation: true,
- preload: `${__dirname}/preload.js`,
- webSecurity: false,
- },
+ preload: join(__dirname, '../preload/index.js'),
+ sandbox: false,
+ contextIsolation: true
+ }
});
// 监听窗口关闭事件
lyricWindow.on('closed', () => {
- console.log('Lyric window closed');
- lyricWindow = null;
+ if (lyricWindow) {
+ lyricWindow.destroy();
+ lyricWindow = null;
+ }
});
+
+ return lyricWindow;
};
-const loadLyricWindow = (ipcMain, mainWin) => {
- ipcMain.on('open-lyric', () => {
- console.log('Received open-lyric request');
- if (lyricWindow) {
- console.log('Lyric window exists, focusing');
- if (lyricWindow.isMinimized()) lyricWindow.restore();
+export const loadLyricWindow = (ipcMain: IpcMain, mainWin: BrowserWindow): void => {
+ const showLyricWindow = () => {
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ if (lyricWindow.isMinimized()) {
+ lyricWindow.restore();
+ }
lyricWindow.focus();
lyricWindow.show();
+ return true;
+ }
+ return false;
+ };
+
+ ipcMain.on('open-lyric', () => {
+ console.log('Received open-lyric request');
+
+ if (showLyricWindow()) {
return;
}
console.log('Creating new lyric window');
- createWin();
- if (process.env.NODE_ENV === 'development') {
- lyricWindow.webContents.openDevTools({ mode: 'detach' });
- lyricWindow.loadURL(`http://localhost:${config.development.lyricPort}/#/lyric`);
- } else {
- const distPath = path.resolve(__dirname, config.production.distPath);
- lyricWindow.loadURL(`file://${distPath}/index.html#/lyric`);
+ const win = createWin();
+
+ if (!win) {
+ console.error('Failed to create lyric window');
+ return;
}
- lyricWindow.setMinimumSize(600, 200);
- lyricWindow.setSkipTaskbar(true);
+ if (process.env.NODE_ENV === 'development') {
+ win.webContents.openDevTools({ mode: 'detach' });
+ win.loadURL(`${process.env.ELECTRON_RENDERER_URL}/#/lyric`);
+ } else {
+ const distPath = path.resolve(__dirname, '../renderer');
+ win.loadURL(`file://${distPath}/index.html#/lyric`);
+ }
- lyricWindow.once('ready-to-show', () => {
+ win.setMinimumSize(600, 200);
+ win.setSkipTaskbar(true);
+
+ win.once('ready-to-show', () => {
console.log('Lyric window ready to show');
- lyricWindow.show();
+ win.show();
});
});
- ipcMain.on('send-lyric', (e, data) => {
+ ipcMain.on('send-lyric', (_, data) => {
if (lyricWindow && !lyricWindow.isDestroyed()) {
try {
lyricWindow.webContents.send('receive-lyric', data);
} catch (error) {
console.error('Error processing lyric data:', error);
}
- } else {
- console.log('Cannot send lyric: window not available or destroyed');
}
});
- ipcMain.on('top-lyric', (e, data) => {
+ ipcMain.on('top-lyric', (_, data) => {
if (lyricWindow && !lyricWindow.isDestroyed()) {
lyricWindow.setAlwaysOnTop(data);
}
@@ -96,22 +118,27 @@ const loadLyricWindow = (ipcMain, mainWin) => {
if (lyricWindow && !lyricWindow.isDestroyed()) {
lyricWindow.webContents.send('lyric-window-close');
mainWin.webContents.send('lyric-control-back', 'close');
- lyricWindow.close();
+ lyricWindow.destroy();
lyricWindow = null;
}
});
+ // 处理鼠标事件
ipcMain.on('mouseenter-lyric', () => {
- lyricWindow.setIgnoreMouseEvents(true);
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.setIgnoreMouseEvents(true);
+ }
});
ipcMain.on('mouseleave-lyric', () => {
- lyricWindow.setIgnoreMouseEvents(false);
+ if (lyricWindow && !lyricWindow.isDestroyed()) {
+ lyricWindow.setIgnoreMouseEvents(false);
+ }
});
// 处理拖动移动
- ipcMain.on('lyric-drag-move', (e, { deltaX, deltaY }) => {
- if (!lyricWindow) return;
+ ipcMain.on('lyric-drag-move', (_, { deltaX, deltaY }) => {
+ if (!lyricWindow || lyricWindow.isDestroyed()) return;
const [currentX, currentY] = lyricWindow.getPosition();
const { width: screenWidth, height: screenHeight } = screen.getPrimaryDisplay().workAreaSize;
@@ -127,30 +154,23 @@ const loadLyricWindow = (ipcMain, mainWin) => {
store.set('lyricWindowBounds', {
...lyricWindow.getBounds(),
x: newX,
- y: newY,
+ y: newY
});
});
// 添加鼠标穿透事件处理
- ipcMain.on('set-ignore-mouse', (e, shouldIgnore) => {
- if (!lyricWindow) return;
+ ipcMain.on('set-ignore-mouse', (_, shouldIgnore) => {
+ if (!lyricWindow || lyricWindow.isDestroyed()) return;
- if (shouldIgnore) {
- // 设置鼠标穿透,但保留拖动区域可交互
- lyricWindow.setIgnoreMouseEvents(true, { forward: true });
- } else {
- // 取消鼠标穿透
- lyricWindow.setIgnoreMouseEvents(false);
- }
+ lyricWindow.setIgnoreMouseEvents(shouldIgnore, { forward: true });
});
// 添加播放控制处理
- ipcMain.on('control-back', (e, command) => {
- console.log('Received control-back request:', command);
- mainWin.webContents.send('lyric-control-back', command);
+ ipcMain.on('control-back', (_, command) => {
+ console.log('command', command);
+ if (mainWin && !mainWin.isDestroyed()) {
+ console.log('Sending control-back command:', command);
+ mainWin.webContents.send('lyric-control-back', command);
+ }
});
};
-
-module.exports = {
- loadLyricWindow,
-};
diff --git a/src/main/server.ts b/src/main/server.ts
new file mode 100644
index 0000000..2824657
--- /dev/null
+++ b/src/main/server.ts
@@ -0,0 +1,32 @@
+import { ipcMain } from 'electron';
+import Store from 'electron-store';
+import fs from 'fs';
+import os from 'os';
+import path from 'path';
+
+import { unblockMusic } from './unblockMusic';
+
+const store = new Store();
+if (!fs.existsSync(path.resolve(os.tmpdir(), 'anonymous_token'))) {
+ fs.writeFileSync(path.resolve(os.tmpdir(), 'anonymous_token'), '', 'utf-8');
+}
+
+// 处理解锁音乐请求
+ipcMain.handle('unblock-music', async (_, id) => {
+ return unblockMusic(id);
+});
+
+import server from 'netease-cloud-music-api-alger/server';
+
+
+async function startMusicApi(): Promise {
+ console.log('MUSIC API STARTED');
+
+ const port = (store.get('set') as any).musicApiPort || 30488;
+
+ await server.serveNcmApi({
+ port
+ });
+}
+
+export { startMusicApi };
diff --git a/electron/set.json b/src/main/set.json
similarity index 55%
rename from electron/set.json
rename to src/main/set.json
index b43145a..21ca816 100644
--- a/electron/set.json
+++ b/src/main/set.json
@@ -3,5 +3,6 @@
"noAnimate": false,
"animationSpeed": 1,
"author": "Alger",
- "authorUrl": "https://github.com/algerkong"
+ "authorUrl": "https://github.com/algerkong",
+ "musicApiPort": 30488
}
diff --git a/src/main/unblockMusic.ts b/src/main/unblockMusic.ts
new file mode 100644
index 0000000..3b33407
--- /dev/null
+++ b/src/main/unblockMusic.ts
@@ -0,0 +1,23 @@
+import match from '@unblockneteasemusic/server';
+
+const unblockMusic = async (id: any): Promise => {
+ return new Promise((resolve, reject) => {
+ match(parseInt(id, 10), ['qq', 'migu', 'kugou', 'joox'])
+ .then((data) => {
+ resolve({
+ data: {
+ data,
+ params: {
+ id,
+ type: 'song'
+ }
+ }
+ });
+ })
+ .catch((err) => {
+ reject(err);
+ });
+ });
+};
+
+export { unblockMusic };
diff --git a/src/preload/index.d.ts b/src/preload/index.d.ts
new file mode 100644
index 0000000..e4586d4
--- /dev/null
+++ b/src/preload/index.d.ts
@@ -0,0 +1,18 @@
+import { ElectronAPI } from '@electron-toolkit/preload';
+
+declare global {
+ interface Window {
+ electron: ElectronAPI;
+ api: {
+ sendLyric: (data: string) => void;
+ openLyric: () => void;
+ minimize: () => void;
+ maximize: () => void;
+ close: () => void;
+ dragStart: (data: string) => void;
+ miniTray: () => void;
+ restart: () => void;
+ unblockMusic: (id: number) => Promise;
+ };
+ }
+}
diff --git a/src/preload/index.ts b/src/preload/index.ts
new file mode 100644
index 0000000..efa9cf6
--- /dev/null
+++ b/src/preload/index.ts
@@ -0,0 +1,32 @@
+import { electronAPI } from '@electron-toolkit/preload';
+import { contextBridge, ipcRenderer } from 'electron';
+
+// Custom APIs for renderer
+const api = {
+ minimize: () => ipcRenderer.send('minimize-window'),
+ maximize: () => ipcRenderer.send('maximize-window'),
+ close: () => ipcRenderer.send('close-window'),
+ dragStart: (data) => ipcRenderer.send('drag-start', data),
+ miniTray: () => ipcRenderer.send('mini-tray'),
+ restart: () => ipcRenderer.send('restart'),
+ openLyric: () => ipcRenderer.send('open-lyric'),
+ sendLyric: (data) => ipcRenderer.send('send-lyric', data),
+ unblockMusic: (id) => ipcRenderer.invoke('unblock-music', id)
+};
+
+// Use `contextBridge` APIs to expose Electron APIs to
+// renderer only if context isolation is enabled, otherwise
+// just add to the DOM global.
+if (process.contextIsolated) {
+ try {
+ contextBridge.exposeInMainWorld('electron', electronAPI);
+ contextBridge.exposeInMainWorld('api', api);
+ } catch (error) {
+ console.error(error);
+ }
+} else {
+ // @ts-ignore (define in dts)
+ window.electron = electronAPI;
+ // @ts-ignore (define in dts)
+ window.api = api;
+}
diff --git a/src/App.vue b/src/renderer/App.vue
similarity index 87%
rename from src/App.vue
rename to src/renderer/App.vue
index 1b6e6e1..86da091 100644
--- a/src/App.vue
+++ b/src/renderer/App.vue
@@ -13,8 +13,8 @@
diff --git a/src/components/MusicList.vue b/src/renderer/components/MusicList.vue
similarity index 98%
rename from src/components/MusicList.vue
rename to src/renderer/components/MusicList.vue
index 30a3d89..bbc951e 100644
--- a/src/components/MusicList.vue
+++ b/src/renderer/components/MusicList.vue
@@ -98,8 +98,8 @@ const props = withDefaults(
}>(),
{
loading: false,
- cover: true,
- },
+ cover: true
+ }
);
const emit = defineEmits(['update:show', 'update:loading']);
@@ -122,7 +122,7 @@ const formatDetail = computed(() => (detail: any) => {
const song = {
artists: detail.ar,
name: detail.al.name,
- id: detail.al.id,
+ id: detail.al.id
};
detail.song = song;
@@ -138,9 +138,9 @@ const handlePlay = () => {
...item,
picUrl: item.al.picUrl,
song: {
- artists: item.ar,
- },
- })),
+ artists: item.ar
+ }
+ }))
);
};
@@ -204,7 +204,7 @@ watch(
if (!props.cover) {
loadingList.value = false;
}
- },
+ }
);
// 监听 songList 变化,重置分页状态
@@ -218,7 +218,7 @@ watch(
}
loadingList.value = false;
},
- { immediate: true },
+ { immediate: true }
);
diff --git a/src/components/MvPlayer.vue b/src/renderer/components/MvPlayer.vue
similarity index 92%
rename from src/components/MvPlayer.vue
rename to src/renderer/components/MvPlayer.vue
index 71b52ae..a341581 100644
--- a/src/components/MvPlayer.vue
+++ b/src/renderer/components/MvPlayer.vue
@@ -1,7 +1,11 @@
-
+
@@ -96,14 +102,22 @@
-
+
{{ volume === 0 ? '取消静音' : '静音' }}
-
+
@@ -111,7 +125,11 @@
-
+
@@ -124,7 +142,9 @@
-
+
@@ -181,7 +201,7 @@ import { IMvItem } from '@/type/mv';
type PlayMode = 'single' | 'auto';
const PLAY_MODE = {
Single: 'single' as PlayMode,
- Auto: 'auto' as PlayMode,
+ Auto: 'auto' as PlayMode
} as const;
const props = withDefaults(
@@ -193,8 +213,8 @@ const props = withDefaults(
{
show: false,
currentMv: undefined,
- noList: false,
- },
+ noList: false
+ }
);
const emit = defineEmits<{
@@ -310,7 +330,7 @@ watch(
if (newMv) {
await loadMvUrl(newMv);
}
- },
+ }
);
const autoPlayBlocked = ref(false);
@@ -383,11 +403,21 @@ const checkFullscreenAPI = () => {
(videoContainerRef.value as any)?.webkitRequestFullscreen ||
(videoContainerRef.value as any)?.mozRequestFullScreen ||
(videoContainerRef.value as any)?.msRequestFullscreen,
- exitFullscreen: doc.exitFullscreen || doc.webkitExitFullscreen || doc.mozCancelFullScreen || doc.msExitFullscreen,
+ exitFullscreen:
+ doc.exitFullscreen ||
+ doc.webkitExitFullscreen ||
+ doc.mozCancelFullScreen ||
+ doc.msExitFullscreen,
fullscreenElement:
- doc.fullscreenElement || doc.webkitFullscreenElement || doc.mozFullScreenElement || doc.msFullscreenElement,
+ doc.fullscreenElement ||
+ doc.webkitFullscreenElement ||
+ doc.mozFullScreenElement ||
+ doc.msFullscreenElement,
fullscreenEnabled:
- doc.fullscreenEnabled || doc.webkitFullscreenEnabled || doc.mozFullScreenEnabled || doc.msFullscreenEnabled,
+ doc.fullscreenEnabled ||
+ doc.webkitFullscreenEnabled ||
+ doc.mozFullScreenEnabled ||
+ doc.msFullscreenEnabled
};
};
diff --git a/src/components/PlaylistType.vue b/src/renderer/components/PlaylistType.vue
similarity index 91%
rename from src/components/PlaylistType.vue
rename to src/renderer/components/PlaylistType.vue
index 1a3f3b4..ccc76d4 100644
--- a/src/components/PlaylistType.vue
+++ b/src/renderer/components/PlaylistType.vue
@@ -13,7 +13,7 @@
? 'animate__bounceIn'
: !isShowAllPlaylistCategory
? 'animate__backOutLeft'
- : 'animate__bounceIn',
+ : 'animate__bounceIn'
) +
' ' +
'type-item-' +
@@ -27,7 +27,11 @@
{{ !isShowAllPlaylistCategory ? '显示全部' : '隐藏一些' }}
@@ -63,8 +67,8 @@ const getAnimationDelay = computed(() => {
watch(isShowAllPlaylistCategory, (newVal) => {
if (!newVal) {
- const elements = playlistCategory.value?.sub.map((item, index) =>
- document.querySelector(`.type-item-${index}`),
+ const elements = playlistCategory.value?.sub.map((_, index) =>
+ document.querySelector(`.type-item-${index}`)
) as HTMLElement[];
elements
.slice(20)
@@ -75,7 +79,7 @@ watch(isShowAllPlaylistCategory, (newVal) => {
() => {
(element as HTMLElement).style.position = 'absolute';
},
- index * DELAY_TIME + 400,
+ index * DELAY_TIME + 400
);
}
});
@@ -90,7 +94,7 @@ watch(isShowAllPlaylistCategory, (newVal) => {
}
});
},
- (playlistCategory.value?.sub.length || 0 - 19) * DELAY_TIME,
+ (playlistCategory.value?.sub.length || 0 - 19) * DELAY_TIME
);
} else {
document.querySelectorAll('.play-list-type-item').forEach((element) => {
@@ -112,8 +116,8 @@ const handleClickPlaylistType = (type: string) => {
router.push({
path: '/list',
query: {
- type,
- },
+ type
+ }
});
};
diff --git a/src/components/RecommendAlbum.vue b/src/renderer/components/RecommendAlbum.vue
similarity index 96%
rename from src/components/RecommendAlbum.vue
rename to src/renderer/components/RecommendAlbum.vue
index 93e483f..1b27909 100644
--- a/src/components/RecommendAlbum.vue
+++ b/src/renderer/components/RecommendAlbum.vue
@@ -38,6 +38,7 @@ import { getNewAlbum } from '@/api/home';
import { getAlbum } from '@/api/list';
import type { IAlbumNew } from '@/type/album';
import { getImgUrl, setAnimationClass, setAnimationDelay } from '@/utils';
+import MusicList from '@/components/MusicList.vue';
const albumData = ref
();
const loadAlbumList = async () => {
@@ -65,9 +66,9 @@ const handleClick = async (item: any) => {
...res.data.album,
creator: {
avatarUrl: res.data.album.artist.img1v1Url,
- nickname: `${res.data.album.artist.name} - ${res.data.album.company}`,
+ nickname: `${res.data.album.artist.name} - ${res.data.album.company}`
},
- description: res.data.album.description,
+ description: res.data.album.description
};
loadingList.value = false;
};
diff --git a/src/components/RecommendSinger.vue b/src/renderer/components/RecommendSinger.vue
similarity index 85%
rename from src/components/RecommendSinger.vue
rename to src/renderer/components/RecommendSinger.vue
index d0ca935..1c01f5b 100644
--- a/src/components/RecommendSinger.vue
+++ b/src/renderer/components/RecommendSinger.vue
@@ -10,7 +10,9 @@
:style="setAnimationDelay(0, 100)"
>
每日推荐
-
+
{{ item.name }}
@@ -34,8 +40,13 @@
:class="setAnimationClass('animate__backInRight')"
:style="setAnimationDelay(index + 1, 100)"
>
-
-
{{ item.musicSize }}首
+
+
+ {{ item.musicSize }}首
+
@@ -68,6 +79,7 @@ import router from '@/router';
import { IDayRecommend } from '@/type/day_recommend';
import type { IHotSinger } from '@/type/singer';
import { getImgUrl, setAnimationClass, setAnimationDelay, setBackgroundImg } from '@/utils';
+import MusicList from '@/components/MusicList.vue';
const store = useStore();
@@ -88,13 +100,13 @@ const loadData = async () => {
// 第二个请求:获取每日推荐
try {
const {
- data: { data: dayRecommend },
+ data: { data: dayRecommend }
} = await getDayRecommend();
// 处理数据
if (dayRecommend) {
singerData.artists = singerData.artists.slice(0, 4);
}
- dayRecommendData.value = dayRecommend;
+ dayRecommendData.value = dayRecommend as unknown as IDayRecommend;
} catch (error) {
console.error('error', error);
}
@@ -109,8 +121,8 @@ const toSearchSinger = (keyword: string) => {
router.push({
path: '/search',
query: {
- keyword,
- },
+ keyword
+ }
});
};
diff --git a/src/components/RecommendSonglist.vue b/src/renderer/components/RecommendSonglist.vue
similarity index 92%
rename from src/components/RecommendSonglist.vue
rename to src/renderer/components/RecommendSonglist.vue
index aef0150..514dcf0 100644
--- a/src/components/RecommendSonglist.vue
+++ b/src/renderer/components/RecommendSonglist.vue
@@ -9,7 +9,10 @@
>
-
+
diff --git a/src/components/common/InstallAppModal.vue b/src/renderer/components/common/InstallAppModal.vue
similarity index 81%
rename from src/components/common/InstallAppModal.vue
rename to src/renderer/components/common/InstallAppModal.vue
index 996bd09..2ac4fe1 100644
--- a/src/components/common/InstallAppModal.vue
+++ b/src/renderer/components/common/InstallAppModal.vue
@@ -1,5 +1,11 @@
-
+