diff --git a/manifest.json b/manifest.json index 079af25..e28db7a 100644 --- a/manifest.json +++ b/manifest.json @@ -2,7 +2,7 @@ "name" : "test1", "appid" : "__UNI__923FD9E", "description" : "", - "versionName" : "1.0.0", + "versionName" : "1.1.1", "versionCode" : "1", "transformPx" : false, /* 5+App特有相关 */ @@ -53,7 +53,47 @@ "dSYMs" : false }, /* SDK配置 */ - "sdkConfigs" : {} + "sdkConfigs" : {}, + "icons" : { + "android" : { + "hdpi" : "unpackage/res/icons/72x72.png", + "xhdpi" : "unpackage/res/icons/96x96.png", + "xxhdpi" : "unpackage/res/icons/144x144.png", + "xxxhdpi" : "unpackage/res/icons/192x192.png" + }, + "ios" : { + "appstore" : "unpackage/res/icons/1024x1024.png", + "ipad" : { + "app" : "unpackage/res/icons/76x76.png", + "app@2x" : "unpackage/res/icons/152x152.png", + "notification" : "unpackage/res/icons/20x20.png", + "notification@2x" : "unpackage/res/icons/40x40.png", + "proapp@2x" : "unpackage/res/icons/167x167.png", + "settings" : "unpackage/res/icons/29x29.png", + "settings@2x" : "unpackage/res/icons/58x58.png", + "spotlight" : "unpackage/res/icons/40x40.png", + "spotlight@2x" : "unpackage/res/icons/80x80.png" + }, + "iphone" : { + "app@2x" : "unpackage/res/icons/120x120.png", + "app@3x" : "unpackage/res/icons/180x180.png", + "notification@2x" : "unpackage/res/icons/40x40.png", + "notification@3x" : "unpackage/res/icons/60x60.png", + "settings@2x" : "unpackage/res/icons/58x58.png", + "settings@3x" : "unpackage/res/icons/87x87.png", + "spotlight@2x" : "unpackage/res/icons/80x80.png", + "spotlight@3x" : "unpackage/res/icons/120x120.png" + } + } + }, + "splashscreen" : { + "androidStyle" : "default", + "android" : { + "hdpi" : "C:/Users/ADMIN/Pictures/480-762.png", + "xhdpi" : "C:/Users/ADMIN/Pictures/720-1242.png", + "xxhdpi" : "C:/Users/ADMIN/Pictures/1080-1882.png" + } + } } }, /* 快应用特有相关 */ diff --git a/pages.json b/pages.json index 57bec78..59b75b2 100644 --- a/pages.json +++ b/pages.json @@ -99,6 +99,18 @@ "softinputMode": "adjustResize" } } + }, + { + "path": "pages/CloudDbDetail/CloudDbDetail", + "style": { + "navigationBarTitleText": "数据库详情", + "navigationStyle": "custom", + "app-plus": { + "titleNView": false, + "bounce": "none", + "softinputMode": "adjustResize" + } + } } ], "uniIdRouter" : {}, diff --git a/pages/CloudDatabase/CloudDatabase.css b/pages/CloudDatabase/CloudDatabase.css index ffa7f69..6ecd123 100644 --- a/pages/CloudDatabase/CloudDatabase.css +++ b/pages/CloudDatabase/CloudDatabase.css @@ -850,4 +850,91 @@ color: #999; margin-bottom: 20rpx; text-align: center; +} + +/* ===== 加载动画 ===== */ +.loading-area { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 60rpx 0; + gap: 16rpx; +} + +.loading-spinner { + width: 56rpx; + height: 56rpx; + border: 4rpx solid #e8e8e8; + border-top-color: #3b86ff; + border-radius: 50%; + animation: spin 0.8s linear infinite; +} + +@keyframes spin { + to { + transform: rotate(360deg); + } +} + +.loading-text { + font-size: 24rpx; + color: #999; +} + +/* ===== 数据库标签 ===== */ +.db-tag { + display: inline-block; + font-size: 20rpx; + font-weight: 500; + padding: 2rpx 12rpx; + border-radius: 8rpx; + margin-left: 10rpx; + vertical-align: middle; +} + +.db-tag.tag-personal { + color: #3b86ff; + background: rgba(59, 134, 255, 0.08); + border: 1rpx solid rgba(59, 134, 255, 0.2); +} + +.db-tag.tag-team { + color: #67c23a; + background: rgba(103, 194, 58, 0.08); + border: 1rpx solid rgba(103, 194, 58, 0.2); +} + +/* ===== 上传数据库弹窗 ===== */ +.upload-db-hint { + font-size: 22rpx; + color: #999; + margin-bottom: 20rpx; + text-align: center; +} + +.upload-file-area { + padding: 40rpx; + border: 2rpx dashed #d0d0d0; + border-radius: 16rpx; + background: #f9fafb; + text-align: center; + margin-bottom: 20rpx; +} + +.upload-file-area:active { + border-color: #3b86ff; + background: rgba(59, 134, 255, 0.03); +} + +.selected-file { + font-size: 26rpx; + color: #3b86ff; + font-weight: 500; + word-break: break-all; +} + +.upload-hint { + font-size: 24rpx; + color: #bbb; } \ No newline at end of file diff --git a/pages/CloudDatabase/CloudDatabase.vue b/pages/CloudDatabase/CloudDatabase.vue index 7bbfed0..339e389 100644 --- a/pages/CloudDatabase/CloudDatabase.vue +++ b/pages/CloudDatabase/CloudDatabase.vue @@ -150,24 +150,39 @@ - - + + - + - 新建{{ currentCategory === 'user' ? '个人' : '团队' }}数据表 - 表名称 + 新建个人数据库 + 数据库名称 - - - 描述 - - + - 取消 - 确认 + 取消 + 确认 + + + + + + + + + + + 上传数据库文件 + 支持 .db / .sqlite / .sqlite3 格式的 SQLite 数据库文件 + + {{ uploadDbFileName }} + 点击选择数据库文件 + + + 取消 + 确认上传 @@ -182,15 +197,15 @@ {{ navbarTitle }} - 完成 + - + @@ -258,31 +273,46 @@ 云端数据库 + {{ !isDbLoading && personalDatabases.length > 0 ? '(' + personalDatabases.length + ')' : '' }} - + + + 上传数据库 + + - 新建表 + 新建数据库 - + + + + 加载中... + + - 暂无数据表 + 暂无数据库 - + - {{ table.name }} - {{ table.desc || '无描述' }} + + {{ db.database_name }} + + {{ db.team_id ? '团队共享' : '个人私有' }} + + + {{ db.table_count || 0 }} 张表 · {{ getAccessLevelLabel(db.access_level) }} - {{ table.rowCount || 0 }} 条记录 + {{ formatDbTime(db.modified_time) }} @@ -376,30 +406,32 @@ 团队云端数据库 - - - - 新建表 - - - + + + + 加载中... + + - 暂无团队数据表 + 暂无团队数据库 - + - {{ table.name }} - {{ table.desc || '无描述' }} + + {{ db.database_name }} + 团队共享 + + {{ db.table_count || 0 }} 张表 · {{ getAccessLevelLabel(db.access_level) }} - {{ table.rowCount || 0 }} 条记录 + {{ formatDbTime(db.modified_time) }} @@ -420,6 +452,7 @@ import { getToken } from '@/utils/user-info.js'; + import { chooseFile } from '@/uni_modules/lime-choose-file'; import { getUserInfo, getCloudFileList, @@ -436,7 +469,11 @@ removeTeamMember, uploadCloudFile, deleteCloudFile, - deleteTeam + deleteTeam, + getCloudDbList, + createCloudDb, + uploadCloudDbFile, + deleteCloudDb } from '@/utils/cloud-api.js'; const userToken = ref(''); @@ -1075,31 +1112,7 @@ // 选择文件并上传 const chooseAndUploadFile = () => { - // #ifdef APP-PLUS - // App 端使用系统文件选择器 - plus.io.chooseFile( - (res) => { - // plus.io.chooseFile 返回格式可能是 { files: [...] } 或直接是数组 - const files = Array.isArray(res) ? res : (res.files || []); - if (files.length === 0) { - uni.showToast({ - title: '未选择文件', - icon: 'none' - }); - return; - } - doUploadFiles(files); - }, - (err) => { - if (err.code !== 11) { // 11 是用户取消 - console.error('选择文件失败:', err); - } - } - ); - // #endif - // #ifndef APP-PLUS - // 小程序/H5 端使用 uni.chooseFile(H5 可能不支持) - uni.chooseFile({ + chooseFile({ count: 10, type: 'all', success: (res) => { @@ -1120,7 +1133,6 @@ console.error('选择文件失败:', err); } }); - // #endif }; // 执行上传 @@ -1152,88 +1164,160 @@ } }; - // ========== 数据库表 ========== - const personalTables = ref([{ - id: '1', - name: 'users', - desc: '用户信息表', - rowCount: 128 - }, - { - id: '2', - name: 'messages', - desc: '聊天记录表', - rowCount: 2048 - }, - { - id: '3', - name: 'settings', - desc: '用户配置表', - rowCount: 56 - } - ]); - const teamTables = ref([{ - id: 't1', - name: 'team_tasks', - desc: '团队任务表', - rowCount: 32 - }, - { - id: 't2', - name: 'team_docs', - desc: '团队文档表', - rowCount: 15 - } - ]); + // ========== 云端数据库 ========== + const allDatabases = ref([]); // API 返回的全部数据库列表 + const isDbLoading = ref(false); // 数据库加载中 + // 个人展示全部数据库(个人私有 + 归属团队的),团队只展示属于当前选中团队的 + const personalDatabases = computed(() => allDatabases.value); + const teamDatabases = computed(() => allDatabases.value.filter(db => db.team_id && String(db.team_id) === String(currentTeamId.value))); - const showNewTable = ref(false); - const newTableName = ref(''); - const newTableDesc = ref(''); + const showNewDb = ref(false); + const newDbName = ref(''); - const openNewTableModal = () => { - showNewTable.value = true; - newTableName.value = ''; - newTableDesc.value = ''; + // 获取数据库列表 + const fetchDbList = async () => { + isDbLoading.value = true; + try { + const token = getToken(); + const list = await getCloudDbList(token); + allDatabases.value = list || []; + } catch (error) { + console.error('获取数据库列表失败:', error); + allDatabases.value = []; + } finally { + isDbLoading.value = false; + } }; - const closeNewTableModal = () => { - showNewTable.value = false; - newTableName.value = ''; - newTableDesc.value = ''; + + const openNewDbModal = () => { + showNewDb.value = true; + newDbName.value = ''; }; - const confirmCreateTable = () => { - const name = newTableName.value.trim(); + const closeNewDbModal = () => { + showNewDb.value = false; + newDbName.value = ''; + }; + const confirmCreateDb = async () => { + const name = newDbName.value.trim(); if (!name) { - uni.showToast({ - title: '请输入表名称', - icon: 'none' - }); + uni.showToast({ title: '请输入数据库名称', icon: 'none' }); return; } - const newTable = { - id: Date.now().toString(), - name: name, - desc: newTableDesc.value.trim() || '无描述', - rowCount: 0 - }; - if (currentCategory.value === 'user') { - personalTables.value.push(newTable); - } else { - teamTables.value.push(newTable); + uni.showLoading({ title: '创建中...' }); + try { + const token = getToken(); + await createCloudDb(token, name); + uni.hideLoading(); + uni.showToast({ title: '创建成功', icon: 'success' }); + closeNewDbModal(); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + console.error('创建数据库失败:', error); + uni.showToast({ title: '创建失败,请重试', icon: 'error' }); } - uni.showToast({ - title: '创建成功', - icon: 'success' - }); - closeNewTableModal(); }; - const handleTableClick = (table) => { - uni.showToast({ - title: `进入数据表:${table.name}`, - icon: 'none' + // ========== 上传数据库文件 ========== + const showUploadDb = ref(false); + const uploadDbFileName = ref(''); + const uploadDbFilePath = ref(''); + + const openUploadDbModal = () => { + showUploadDb.value = true; + uploadDbFileName.value = ''; + uploadDbFilePath.value = ''; + }; + const closeUploadDbModal = () => { + showUploadDb.value = false; + }; + + const handlePickDbFile = () => { + chooseFile({ + count: 1, + type: 'all', + success: (res) => { + const file = res.tempFiles[0]; + uploadDbFileName.value = file.name || 'unknown'; + uploadDbFilePath.value = file.path; + }, + fail: (err) => { + console.error('选择文件失败:', err); + uni.showToast({ title: '选择文件失败', icon: 'none' }); + } }); }; + const confirmUploadDb = async () => { + if (!uploadDbFilePath.value) { + uni.showToast({ title: '请选择数据库文件', icon: 'none' }); + return; + } + // 校验文件后缀 + const ext = uploadDbFileName.value.split('.').pop()?.toLowerCase(); + const allowedExts = ['db', 'sqlite', 'sqlite3']; + if (!allowedExts.includes(ext)) { + uni.showToast({ title: '仅支持 .db / .sqlite / .sqlite3 文件', icon: 'none' }); + return; + } + uni.showLoading({ title: '上传中...' }); + try { + const token = getToken(); + await uploadCloudDbFile(token, uploadDbFilePath.value); + uni.hideLoading(); + uni.showToast({ title: '上传成功', icon: 'success' }); + closeUploadDbModal(); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + console.error('上传数据库失败:', error); + uni.showToast({ title: '上传失败,请重试', icon: 'error' }); + } + }; + + const handleDeleteDb = (db) => { + uni.showModal({ + title: '删除数据库', + content: `确定要删除数据库"${db.database_name}"吗?此操作不可恢复。`, + success: async (res) => { + if (res.confirm) { + uni.showLoading({ title: '删除中...' }); + try { + const token = getToken(); + await deleteCloudDb(token, db.database_id); + uni.hideLoading(); + uni.showToast({ title: '删除成功', icon: 'success' }); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + console.error('删除数据库失败:', error); + uni.showToast({ title: '删除失败,请重试', icon: 'error' }); + } + } + } + }); + }; + + const handleDbClick = (db) => { + uni.navigateTo({ + url: `/pages/CloudDbDetail/CloudDbDetail?databaseId=${db.database_id}&databaseName=${encodeURIComponent(db.database_name)}&teamId=${db.team_id || ''}` + }); + }; + + const formatDbTime = (timestamp) => { + if (!timestamp) return ''; + const date = new Date(timestamp * 1000); + const y = date.getFullYear(); + const m = String(date.getMonth() + 1).padStart(2, '0'); + const d = String(date.getDate()).padStart(2, '0'); + return `${y}-${m}-${d}`; + }; + + const getAccessLevelLabel = (level) => { + const labels = { 0: '无权限', 1: '只读', 2: '读写', 3: '管理' }; + return labels[level] || '未知'; + }; + // ========== 团队管理 ========== const showTeamManage = ref(false); const teamGroups = ref([]); @@ -1568,6 +1652,7 @@ onMounted(async () => { await fetchFileList(); await fetchTeamList(); + await fetchDbList(); }); diff --git a/pages/CloudDbDetail/CloudDbDetail.css b/pages/CloudDbDetail/CloudDbDetail.css new file mode 100644 index 0000000..7b04730 --- /dev/null +++ b/pages/CloudDbDetail/CloudDbDetail.css @@ -0,0 +1,546 @@ +/* ========== 通用 ========== */ +.status-bar { + height: var(--status-bar-height); + background-color: #ffffff; +} + +.page-container { + display: flex; + flex-direction: column; + height: 100vh; + background-color: #f5f6fa; +} + +/* ========== 导航栏 ========== */ +.cloud-db-header { + background-color: #ffffff; + flex-shrink: 0; + position: relative; + z-index: 10; +} + +.custom-navbar { + display: flex; + align-items: center; + justify-content: space-between; + height: 88rpx; + padding: 0 30rpx; +} + +.navbar-left { + display: flex; + align-items: center; + min-width: 120rpx; +} + +.custom-navbar-icon { + font-size: 40rpx; + color: #333; +} + +.navbar-title { + font-size: 34rpx; + font-weight: 600; + color: #333; + flex: 1; + text-align: center; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +.navbar-right { + min-width: 120rpx; + display: flex; + justify-content: flex-end; +} + +/* 下拉菜单 */ +.menu-card { + position: absolute; + top: 88rpx; + right: 20rpx; + background: #fff; + border-radius: 16rpx; + box-shadow: 0 8rpx 32rpx rgba(0,0,0,0.12); + z-index: 500; + overflow: hidden; + min-width: 200rpx; +} + +.menu-card-item { + padding: 24rpx 36rpx; + font-size: 28rpx; + color: #333; + text-align: center; +} + +.menu-card-item:active { + background-color: #f5f6fa; +} + +.solid-line { + height: 1rpx; + background-color: #eee; + margin: 0 20rpx; +} + +/* ========== 数据库信息栏 ========== */ +.db-info-bar { + display: flex; + align-items: center; + gap: 24rpx; + padding: 20rpx 30rpx; + background: #fff; + border-bottom: 1rpx solid #f0f0f0; +} + +.db-info-text { + font-size: 24rpx; + color: #999; +} + +/* ========== 内容区域 ========== */ +.cloud-db-content { + flex: 1; + overflow-y: auto; +} + +.section-block { + margin: 20rpx; + background: #fff; + border-radius: 20rpx; + overflow: hidden; +} + +.section-header { + display: flex; + align-items: center; + justify-content: space-between; + padding: 24rpx 30rpx; + border-bottom: 1rpx solid #f5f6fa; +} + +.section-title { + display: flex; + align-items: center; + gap: 12rpx; + font-size: 30rpx; + font-weight: 600; + color: #333; +} + +.section-title .iconfont { + font-size: 36rpx; + color: #3b86ff; +} + +.section-actions { + display: flex; + align-items: center; + gap: 16rpx; +} + +.row-count { + font-size: 24rpx; + color: #999; +} + +.section-divider { + height: 1rpx; + background-color: #f0f0f0; + margin: 0 20rpx; +} + +.section-body { + padding: 16rpx 0; +} + +/* ========== 空状态 ========== */ +.empty-tip { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 60rpx 0; + color: #ccc; + font-size: 26rpx; +} + +.empty-tip .iconfont { + font-size: 80rpx; + margin-bottom: 16rpx; +} + +/* ========== 表列表 ========== */ +.table-list { + padding: 0 30rpx; +} + +.table-item { + display: flex; + align-items: center; + padding: 24rpx 0; + border-bottom: 1rpx solid #f5f6fa; +} + +.table-item:last-child { + border-bottom: none; +} + +.table-item:active { + background-color: #fafbfc; + margin: 0 -30rpx; + padding-left: 30rpx; + padding-right: 30rpx; +} + +.table-icon { + width: 72rpx; + height: 72rpx; + border-radius: 16rpx; + background: rgba(59, 134, 255, 0.08); + display: flex; + align-items: center; + justify-content: center; + margin-right: 20rpx; + flex-shrink: 0; +} + +.table-info { + flex: 1; + overflow: hidden; +} + +.table-name { + font-size: 30rpx; + font-weight: 500; + color: #333; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +.table-desc { + font-size: 24rpx; + color: #999; + margin-top: 4rpx; +} + +.table-meta { + display: flex; + align-items: center; + gap: 8rpx; + flex-shrink: 0; +} + +/* ========== 数据表格 ========== */ +.data-table-wrapper { + padding: 0; +} + +.data-table-scroll { + width: 100%; +} + +.data-table { + min-width: 100%; +} + +.data-row { + display: flex; + flex-direction: row; + border-bottom: 1rpx solid #f0f0f0; +} + +.data-row:last-child { + border-bottom: none; +} + +.data-header { + background-color: #f8f9fb; +} + +.data-cell { + padding: 16rpx 20rpx; + font-size: 26rpx; + color: #333; + min-width: 160rpx; + max-width: 300rpx; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + border-right: 1rpx solid #f0f0f0; + flex-shrink: 0; +} + +.data-cell:last-child { + border-right: none; +} + +.data-header .data-cell { + font-weight: 600; + color: #666; + font-size: 24rpx; +} + +.index-cell { + min-width: 80rpx !important; + max-width: 80rpx !important; + text-align: center; + color: #999; + font-size: 24rpx; +} + +.data-row:active { + background-color: #f5f7fa; +} + +/* ========== 弹窗通用 ========== */ +.popup-overlay { + position: fixed; + top: 0; + left: 0; + right: 0; + bottom: 0; + background: rgba(0, 0, 0, 0.5); + display: flex; + align-items: center; + justify-content: center; + z-index: 900; +} + +.popup-card { + width: 640rpx; + background: #fff; + border-radius: 24rpx; + padding: 40rpx 36rpx 30rpx; + position: relative; +} + +.close-popup-card { + position: absolute; + top: 20rpx; + right: 20rpx; + width: 48rpx; + height: 48rpx; + display: flex; + align-items: center; + justify-content: center; +} + +.close-popup-card .iconfont { + font-size: 36rpx; + color: #999; +} + +.popup-title { + font-size: 34rpx; + font-weight: 600; + color: #333; + text-align: center; + margin-bottom: 30rpx; +} + +.new-folder-name { + font-size: 26rpx; + color: #666; + margin-bottom: 12rpx; +} + +.create-folder-name { + margin-bottom: 24rpx; +} + +.create-folder-name input { + width: 100%; + height: 80rpx; + border: 2rpx solid #e0e0e0; + border-radius: 12rpx; + padding: 0 20rpx; + font-size: 28rpx; + box-sizing: border-box; + background: #f8f9fb; +} + +.upload-file-area { + width: 100%; + height: 120rpx; + border: 2rpx dashed #d0d0d0; + border-radius: 12rpx; + display: flex; + align-items: center; + justify-content: center; + margin-bottom: 24rpx; + background: #fafbfc; +} + +.selected-file { + font-size: 26rpx; + color: #3b86ff; +} + +.upload-hint { + font-size: 24rpx; + color: #999; +} + +.option-wrapper { + display: flex; + gap: 20rpx; + margin-top: 10rpx; +} + +.opt-btn { + flex: 1; + height: 80rpx; + border-radius: 12rpx; + display: flex; + align-items: center; + justify-content: center; + font-size: 30rpx; +} + +.opt-cancel { + background: #f5f6fa; + color: #666; +} + +.opt-confirm { + background: #3b86ff; + color: #fff; +} + +/* ========== 权限管理 ========== */ +.permission-body { + max-height: 600rpx; + margin-bottom: 20rpx; +} + +.permission-list { + padding: 0 10rpx; +} + +.permission-item { + display: flex; + align-items: center; + padding: 20rpx 10rpx; + border-bottom: 1rpx solid #f0f0f0; +} + +.perm-info { + flex: 1; + display: flex; + flex-direction: column; + gap: 4rpx; +} + +.perm-name { + font-size: 28rpx; + color: #333; +} + +.perm-type { + font-size: 22rpx; + color: #999; +} + +.perm-level { + font-size: 24rpx; + color: #3b86ff; + background: rgba(59, 134, 255, 0.08); + padding: 6rpx 16rpx; + border-radius: 8rpx; + margin: 0 16rpx; +} + +.perm-actions { + display: flex; + gap: 12rpx; +} + +.perm-action-btn { + font-size: 24rpx; + color: #3b86ff; + padding: 8rpx 16rpx; + border: 1rpx solid #3b86ff; + border-radius: 8rpx; +} + +.perm-action-btn.delete { + color: #f56c6c; + border-color: #f56c6c; +} + +.close-permission-btn { + text-align: center; + font-size: 28rpx; + color: #999; + padding: 16rpx 0; +} + +.folder-null { + text-align: center; + padding: 40rpx 0; + font-size: 26rpx; + color: #999; +} + +/* ========== 移交团队 ========== */ +.transfer-body { + max-height: 500rpx; + margin-bottom: 20rpx; +} + +.transfer-list { + padding: 0 10rpx; +} + +.transfer-item { + display: flex; + align-items: center; + justify-content: space-between; + padding: 24rpx 16rpx; + border-bottom: 1rpx solid #f0f0f0; + border-radius: 12rpx; + margin-bottom: 8rpx; +} + +.transfer-item.active { + background: rgba(59, 134, 255, 0.06); +} + +.transfer-name { + font-size: 28rpx; + color: #333; +} + +/* ===== 加载动画 ===== */ +.loading-area { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 60rpx 0; + gap: 16rpx; +} + +.loading-spinner { + width: 56rpx; + height: 56rpx; + border: 4rpx solid #e8e8e8; + border-top-color: #3b86ff; + border-radius: 50%; + animation: spin 0.8s linear infinite; +} + +@keyframes spin { + to { + transform: rotate(360deg); + } +} + +.loading-text { + font-size: 24rpx; + color: #999; +} diff --git a/pages/CloudDbDetail/CloudDbDetail.vue b/pages/CloudDbDetail/CloudDbDetail.vue new file mode 100644 index 0000000..d52995c --- /dev/null +++ b/pages/CloudDbDetail/CloudDbDetail.vue @@ -0,0 +1,715 @@ + + + + + \ No newline at end of file diff --git a/pages/ContactPages/ContactPages.vue b/pages/ContactPages/ContactPages.vue index 1c7e7e5..058b44d 100644 --- a/pages/ContactPages/ContactPages.vue +++ b/pages/ContactPages/ContactPages.vue @@ -194,7 +194,7 @@ - + @@ -389,11 +389,11 @@ label: '添加好友', icon: '➕' }, - { - name: 'videoCall', - label: '视频会议', - icon: '📹' - }, + // { + // name: 'videoCall', + // label: '视频会议', + // icon: '📹' + // }, { name: 'friendRequest', label: '好友申请', diff --git a/pages/WorkSpace/WorkSpace.vue b/pages/WorkSpace/WorkSpace.vue index b19fc3a..da744aa 100644 --- a/pages/WorkSpace/WorkSpace.vue +++ b/pages/WorkSpace/WorkSpace.vue @@ -14,8 +14,8 @@ 目录名称 - + @@ -50,7 +50,9 @@ @click="handleMenu"> - 选择 + + 上传文件 新建文件夹 @@ -88,11 +90,11 @@ - - - + + + - + @@ -107,11 +109,17 @@ getWorkspaceId, getToken } from '@/utils/user-info.js' + import { + chooseFile + } from '@/uni_modules/lime-choose-file'; import { getWorkspaceList, createWorkspaceFolder, daleteWorkspace, - getWorkspaceFileURL + getWorkspaceFileURL, + uploadFileToShortStorage, + workspaceUploadFileByURL, + updateWorkspaceFileName } from '@/utils/cloud-api.js' const UserToken = ref('') @@ -148,6 +156,84 @@ showNewFolder.value = true } + // ========== 上传文件 ========== + const handleUploadFile = () => { + chooseFile({ + count: 10, + type: 'all', + success: async (res) => { + const files = res.tempFiles || []; + if (files.length === 0) { + uni.showToast({ + title: '未选择文件', + icon: 'none' + }); + return; + } + await doUploadWorkspaceFiles(files); + }, + fail: (err) => { + console.error('选择文件失败:', err); + } + }); + }; + + const doUploadWorkspaceFiles = async (files) => { + uni.showLoading({ + title: '上传中...' + }); + try { + const dirPath = folderStack.value.length > 0 ? + './' + folderStack.value.map(f => f.name).join('/') + '/' : + '/'; + + // 1. 一次性上传所有文件到短存云端,获取 URL 数组 + const results = await uploadFileToShortStorage( + workspaceId.value, + files, + dirPath + ); + // results: [{ url, success }, ...] + + // 2. 收集成功的 URL,批量上传到工作区 + const successUrls = results + .filter(r => r.success) + .map(r => r.url); + + if (successUrls.length === 0) { + const errors = results.filter(r => !r.success).map(r => r.error).join('; '); + throw new Error(errors || '所有文件上传失败'); + } + + await workspaceUploadFileByURL( + UserToken.value, + workspaceId.value, + successUrls, + dirPath + ); + + uni.hideLoading(); + const total = files.length; + const failed = total - successUrls.length; + const msg = failed > 0 ? + `上传完成:成功 ${successUrls.length},失败 ${failed}` : + `成功上传 ${total} 个文件`; + uni.showToast({ + title: msg, + icon: successUrls.length > 0 ? 'success' : 'error' + }); + // 刷新文件列表 + initCurrentFolderList(); + } catch (error) { + uni.hideLoading(); + console.error('上传文件失败:', error); + uni.showToast({ + title: typeof error === 'string' ? error : '上传失败,请重试', + icon: 'error' + }); + } + }; + // 当前文件夹路径 const currentFolderPath = computed(() => { if (folderStack.value.length === 0) return '根目录' @@ -168,7 +254,10 @@ const confirmCreateFolder = async () => { const name = newFolderName.value.trim() if (!name) { - uni.showToast({ title: '请输入目录名称', icon: 'none' }) + uni.showToast({ + title: '请输入目录名称', + icon: 'none' + }) return } try { @@ -176,12 +265,18 @@ const folderPath = folderStack.value.map(f => f.name).join('/') const dirPath = folderPath ? `./${folderPath}/${name}` : `./${name}` await createWorkspaceFolder(UserToken.value, workspaceId.value, dirPath) - uni.showToast({ title: '创建成功', icon: 'success' }) + uni.showToast({ + title: '创建成功', + icon: 'success' + }) closeNewFolderModal() initCurrentFolderList() } catch (error) { console.error('创建文件夹失败:', error) - uni.showToast({ title: '创建失败,请重试', icon: 'error' }) + uni.showToast({ + title: '创建失败,请重试', + icon: 'error' + }) } } @@ -189,132 +284,107 @@ const handleLongPress = (folder) => { if (isSelectFolder.value) return; uni.showActionSheet({ - itemList: ['重命名', '删除', '下载', '压缩'], + itemList: ['下载', '删除'], // ['删除', '下载', '压缩', '重命名'] success: (res) => { switch (res.tapIndex) { case 0: - handleRename(folder); + handleDownload(folder); break; case 1: handleDelete(folder); break; - case 2: - handleDownload(folder); - break; - case 3: - handleDownload(folder); - break; + // case 2: + // handleDownload(folder); + // break; + // case 3: + // handleRename(folder); + // break; } } }) } // 重命名 - const handleRename = (folder) => { + const handleRename = async (folder) => { uni.showModal({ title: '重命名', content: '请输入新名称', editable: true, placeholderText: folder.name, - success: (res) => { + success: async (res) => { if (res.confirm && res.content) { - // 更新文件夹名称 - updateFolderName(folder.id, res.content); + try { + uni.showLoading({ + title: '重命名中...' + }); + // 构建文件路径:当前目录 + 文件名 + const dirPath = folderStack.value.length > 0 ? + './' + folderStack.value.map(f => f.name).join('/') + '/' : + '/'; + const filePath = dirPath + folder.name; + await updateWorkspaceFileName( + workspaceId.value, + filePath, + res.content + ); + uni.hideLoading(); + uni.showToast({ + title: '重命名成功', + icon: 'success' + }); + // 刷新文件列表 + initCurrentFolderList(); + } catch (error) { + uni.hideLoading(); + console.error('重命名失败:', error); + uni.showToast({ + title: typeof error === 'string' ? error : '重命名失败,请重试', + icon: 'error' + }); + } } } }); }; - // // 下载文件 - // const handleDownload = async (folder) => { - // // 目录不能下载 - // if (folder.type === 'directory') { - // uni.showToast({ title: '暂不支持下载目录', icon: 'none' }); - // return; - // } - - // try { - // uni.showLoading({ title: '获取下载链接...' }); - - // // 构建文件路径,去掉开头的 ./ - // const filePath = folder.path.startsWith('./') ? folder.path.slice(2) : folder.path; - // const result = await getWorkspaceFileURL(UserToken.value, workspaceId.value, filePath); - - // uni.hideLoading(); - - // // 接口返回数组,取第一个文件的 url - // const fileInfo = Array.isArray(result) ? result[0] : result; - // if (!fileInfo || !fileInfo.url) { - // uni.showToast({ title: '获取下载链接失败', icon: 'error' }); - // return; - // } - - // const downloadUrl = fileInfo.url; - // const fileName = folder.name; - - // uni.showLoading({ title: '下载中...' }); - - // uni.downloadFile({ - // url: downloadUrl, - // success: (downloadRes) => { - // uni.hideLoading(); - // if (downloadRes.statusCode === 200) { - // // 保存到手机相册/文件 - // uni.saveFile({ - // tempFilePath: downloadRes.tempFilePath, - // success: (saveRes) => { - // uni.showToast({ title: '下载成功', icon: 'success' }); - // console.log('文件已保存到:', saveRes.savedFilePath); - // }, - // fail: (err) => { - // console.error('保存文件失败:', err); - // uni.showToast({ title: '保存文件失败', icon: 'error' }); - // } - // }); - // } else { - // uni.showToast({ title: '下载失败', icon: 'error' }); - // } - // }, - // fail: (err) => { - // uni.hideLoading(); - // console.error('下载文件失败:', err); - // uni.showToast({ title: '下载失败,请重试', icon: 'error' }); - // } - // }); - // } catch (error) { - // uni.hideLoading(); - // console.error('获取下载链接失败:', error); - // uni.showToast({ title: '获取下载链接失败,请重试', icon: 'error' }); - // } - // }; const handleDownload = async (folder) => { // 目录不能下载 if (folder.type === 'directory') { - uni.showToast({ title: '暂不支持下载目录', icon: 'none' }); + uni.showToast({ + title: '暂不支持下载目录', + icon: 'none' + }); return; } - + try { - uni.showLoading({ title: '获取下载链接...' }); - + uni.showLoading({ + title: '获取下载链接...' + }); + // 构建文件路径,去掉开头的 ./ const filePath = folder.path.startsWith('./') ? folder.path.slice(2) : folder.path; const result = await getWorkspaceFileURL(UserToken.value, workspaceId.value, filePath); - + uni.hideLoading(); - + // 接口返回数组,取第一个文件的 url const fileInfo = Array.isArray(result) ? result[0] : result; if (!fileInfo || !fileInfo.url) { - uni.showToast({ title: '获取下载链接失败', icon: 'error' }); + uni.showToast({ + title: '获取下载链接失败', + icon: 'error' + }); return; } - + const downloadUrl = fileInfo.url; const fileName = folder.name; - - uni.showLoading({ title: '下载中...' }); - + + uni.showLoading({ + title: '下载中...' + }); + uni.downloadFile({ url: downloadUrl, name: fileName, @@ -325,19 +395,28 @@ // 下载成功,保存到 yxd 目录 saveFileToYxd(fileName, tempPath); } else { - uni.showToast({ title: '下载失败', icon: 'error' }); + uni.showToast({ + title: '下载失败', + icon: 'error' + }); } }, fail: (err) => { uni.hideLoading(); console.error('下载文件失败:', err); - uni.showToast({ title: '下载失败,请重试', icon: 'error' }); + uni.showToast({ + title: '下载失败,请重试', + icon: 'error' + }); } }); } catch (error) { uni.hideLoading(); console.error('获取下载链接失败:', error); - uni.showToast({ title: '获取下载链接失败,请重试', icon: 'error' }); + uni.showToast({ + title: '获取下载链接失败,请重试', + icon: 'error' + }); } }; @@ -352,16 +431,24 @@ callback(dirEntry); }, () => { plus.io.resolveLocalFileSystemURL('/storage/emulated/0/', (rootEntry) => { - rootEntry.getDirectory('yxd', { create: true }, (dirEntry) => { + rootEntry.getDirectory('yxd', { + create: true + }, (dirEntry) => { callback(dirEntry); }, (err) => { console.error('创建 yxd 目录失败:', JSON.stringify(err)); - uni.showToast({ title: '创建目录失败', icon: 'error' }); + uni.showToast({ + title: '创建目录失败', + icon: 'error' + }); openFileConfirm(fileName, tempPath); }); }, (err) => { console.error('访问外部存储根目录失败:', JSON.stringify(err)); - uni.showToast({ title: '无法访问存储目录', icon: 'error' }); + uni.showToast({ + title: '无法访问存储目录', + icon: 'error' + }); openFileConfirm(fileName, tempPath); }); }); @@ -478,13 +565,19 @@ try { // 路径加 ./ 前缀 const filePath = `./${folder.path}` - console.log("删除的是:",filePath); + console.log("删除的是:", filePath); await daleteWorkspace(UserToken.value, workspaceId.value, filePath) - uni.showToast({ title: '删除成功', icon: 'success' }) + uni.showToast({ + title: '删除成功', + icon: 'success' + }) initCurrentFolderList() } catch (error) { console.error('删除失败:', error) - uni.showToast({ title: '删除失败,请重试', icon: 'error' }) + uni.showToast({ + title: '删除失败,请重试', + icon: 'error' + }) } } } diff --git a/uni_modules/lime-choose-file/encrypt b/uni_modules/lime-choose-file/encrypt deleted file mode 100644 index 8e9d757..0000000 --- a/uni_modules/lime-choose-file/encrypt +++ /dev/null @@ -1,2 +0,0 @@ -,P=[&۸6 -IT ]r*IF܃C咺+E|q`(I_+DZsfVqgqݰIC*NRWO5@\7ta `e7HF:Dr|# \ No newline at end of file diff --git a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/classes.dex b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/classes.dex new file mode 100644 index 0000000..841d32e Binary files /dev/null and b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/classes.dex differ diff --git a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.jar b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.jar index f6e0346..bd1c759 100644 Binary files a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.jar and b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.jar differ diff --git a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt new file mode 100644 index 0000000..5be51b9 --- /dev/null +++ b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt @@ -0,0 +1,277 @@ +@file:Suppress("UNCHECKED_CAST", "USELESS_CAST", "INAPPLICABLE_JVM_NAME", "UNUSED_ANONYMOUS_PARAMETER", "SENSELESS_COMPARISON", "NAME_SHADOWING", "UNNECESSARY_NOT_NULL_ASSERTION") +package uts.sdk.modules.limeChooseFile +import android.content.Intent +import android.net.Uri +import android.provider.OpenableColumns +import io.dcloud.uniapp.* +import io.dcloud.uniapp.extapi.* +import io.dcloud.unicloud.* +import io.dcloud.uts.* +import io.dcloud.uts.Map +import io.dcloud.uts.Set +import io.dcloud.uts.UTSAndroid +import java.io.File +import java.io.FileOutputStream +import kotlin.properties.Delegates +import kotlinx.coroutines.CoroutineScope +import kotlinx.coroutines.Deferred +import kotlinx.coroutines.Dispatchers +import kotlinx.coroutines.async +typealias ChooseFileErrorCode = Number +interface GeneralCallbackResult : IUniError { + override var errCode: ChooseFileErrorCode +} +interface ChooseFile { + var name: String + var path: String + var size: Number + var time: Number + var type: String +} +open class ChooseFileSuccessCallbackResult ( + @JsonNotNull + open var tempFiles: UTSArray, + @JsonNotNull + open var errMsg: String, +) : UTSObject(), IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileSuccessCallbackResult", "uni_modules/lime-choose-file/utssdk/interface.uts", 34, 13) + } +} +typealias ChooseFileSuccessCallback = (result: ChooseFileSuccessCallbackResult) -> Unit +typealias ChooseFileFailCallback = (res: GeneralCallbackResult) -> Unit +typealias ChooseFileCompleteCallback = (res: GeneralCallbackResult) -> Unit +open class ChooseFileOption ( + open var filename: String? = null, + open var count: Number? = null, + open var type: String? = null, + open var extension: UTSArray? = null, + open var success: ChooseFileSuccessCallback? = null, + open var fail: ChooseFileFailCallback? = null, + open var complete: ChooseFileCompleteCallback? = null, +) : UTSObject(), IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileOption", "uni_modules/lime-choose-file/utssdk/interface.uts", 45, 13) + } +} +val UniErrorSubject = "chooseFile\"" +val UniErrors: Map = Map(_uA( + _uA( + 9010001, + "chooseFile:ok" + ), + _uA( + 9010002, + "ChooseFile:failed" + ) +)) +open class GeneralCallbackResultImpl : UniError, GeneralCallbackResult, IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("GeneralCallbackResultImpl", "uni_modules/lime-choose-file/utssdk/unierror.uts", 25, 14) + } + constructor(errCode: ChooseFileErrorCode, errMsg: String? = null) : super() { + this.errSubject = UniErrorSubject + this.errCode = errCode + this.errMsg = errMsg ?: UniErrors[errCode] ?: "" + } +} +val REQUEST_CODE_CHOOSE_FILE: Int = 42 +var resultFunction: ((requestCode: Int, resultCode: Int, data: Intent?) -> Unit)? = null +open class ChooseFileImpl : ChooseFile, IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileImpl", "uni_modules/lime-choose-file/utssdk/app-android/index.uts", 17, 7) + } + override var name: String = "" + override var path: String = "" + override var size: Number = 0 + override var time: Number = 0 + override var type: String = "file" + private var options: ChooseFileOption + constructor(uri: Uri, options: ChooseFileOption){ + this.options = options + this.time = Date.now() + this.type = this.getFileTypeFromUri(uri) + this.getFileInfoFromUri(uri) + if (this.isCache(options)) { + this.copyFileToCache(uri) + } + } + private fun isCache(options: ChooseFileOption): Boolean { + val extension = this.getFileExtension(this.name) + val extensions = options.extension + val type = options.type ?: "all" + val hasExtension = extensions != null && extension != "" && extensions.includes(extension) + val isVideoOrImage = _uA( + "video", + "image" + ).includes(type) + val isFileAndNotVideoOrImage = type == "file" && !_uA( + "video", + "image" + ).includes(this.type) + if ((type == "all" || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) { + return true + } else { + return false + } + } + private fun getFileExtension(fileName: String): String { + val lastDotIndex = fileName.lastIndexOf(".") + if (lastDotIndex == -1) { + return "" + } + return fileName.substring(lastDotIndex + 1) + } + private fun copyFileToCache(uri: Uri) { + val cacheDir = UTSAndroid.getAppCachePath() + val context = UTSAndroid.getAppContext() + if (cacheDir != null) { + val path = File(cacheDir) + if (!path.exists()) { + path.mkdir() + } + } + var fileName = this.name + if (this.options.filename != null) { + fileName = this.options.filename!! + if (this.options.count != null && this.options.count!! > 1) { + fileName = "" + fileName + "_" + Date.now() + } + val extension = this.getFileExtension(this.name) + fileName = "" + fileName + "." + extension + } + val destFile = File(cacheDir, fileName) + try { + val inputStream = context!!.getContentResolver().openInputStream(uri) + val outputStream = FileOutputStream(destFile) + if (inputStream != null) { + var buffer = ByteArray(1024) + var c = inputStream.read(buffer) + while(c > 0){ + outputStream.write(buffer, 0, c) + c = inputStream.read(buffer) + } + } + this.path = cacheDir + fileName + } + catch (e: Throwable) {} + } + private fun getFileTypeFromUri(uri: Uri): String { + val context = UTSAndroid.getAppContext() + var fileType = "file" + var mimeType = context!!.getContentResolver().getType(uri) + if (mimeType != null) { + if (mimeType.startsWith("video")) { + fileType = "video" + } else if (mimeType.startsWith("image")) { + fileType = "image" + } + } + return fileType + } + private fun getFileInfoFromUri(uri: Uri) { + val context = UTSAndroid.getAppContext() + var cursor = context!!.getContentResolver().query(uri, null, null, null, null) + if (cursor != null && cursor.moveToFirst()) { + this.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME)) + val fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE)) + this.size = UTSNumber.from(fileSize) + cursor.close() + } else if ("file".equals(uri.getScheme())) { + this.name = uri.getLastPathSegment() ?: "" + val file = File(uri.getPath() ?: "") + val fileSize = file.length() + this.size = UTSNumber.from(fileSize) + } + } +} +fun chooseFile(options: ChooseFileOption) { + if (resultFunction != null) { + UTSAndroid.offAppActivityResult(resultFunction!!) + } + val type = options.type ?: "all" + val intent = Intent(Intent.ACTION_GET_CONTENT) + if (type.equals("all") || type.equals("file")) { + intent.setType("*/*") + } else if (type.equals("video")) { + intent.setType("video/*") + } else if (type.equals("image")) { + intent.setType("image/*") + } + intent.addCategory(Intent.CATEGORY_OPENABLE) + intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, if (options.count == 1) { + false + } else { + true + } + ) + resultFunction = fun(requestCode: Int, resultCode: Int, data: Intent?){ + if (requestCode == REQUEST_CODE_CHOOSE_FILE) { + UTSAndroid.offAppActivityResult(resultFunction!!) + if (resultCode == -1 && data != null) { + val clipData = data.getClipData() + val tempFiles: UTSArray = _uA() + if (clipData != null) { + run { + var i: Number = 0 + while(i < clipData.getItemCount()){ + val uri = clipData.getItemAt(i.toInt()).getUri() + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + i++ + } + } + } else { + val uri = data.getData() + if (uri != null) { + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + } + } + val count = options.count ?: Integer.MAX_VALUE + if (tempFiles.length > 0 && count >= tempFiles.length) { + options.success?.invoke(ChooseFileSuccessCallbackResult(tempFiles = tempFiles, errMsg = "chooseFile:ok")) + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件或文件超过设置数量") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } + UTSAndroid.onAppActivityResult(resultFunction!!) + UTSAndroid.getUniActivity()!!.startActivityForResult(Intent.createChooser(intent, "选择文件"), REQUEST_CODE_CHOOSE_FILE) +} +open class ChooseFileOptionJSONObject : UTSJSONObject() { + open var filename: String? = null + open var count: Number? = null + open var type: String? = null + open var extension: UTSArray? = null + open var success: UTSCallback? = null + open var fail: UTSCallback? = null + open var complete: UTSCallback? = null +} +fun chooseFileByJs(options: ChooseFileOptionJSONObject) { + return chooseFile(ChooseFileOption(filename = options.filename, count = options.count, type = options.type, extension = options.extension, success = fun(result: ChooseFileSuccessCallbackResult): Unit { + options.success?.invoke(result) + } + , fail = fun(res: GeneralCallbackResult): Unit { + options.fail?.invoke(res) + } + , complete = fun(res: GeneralCallbackResult): Unit { + options.complete?.invoke(res) + } + )) +} diff --git a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt.map b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt.map new file mode 100644 index 0000000..27c2988 --- /dev/null +++ b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/index.kt.map @@ -0,0 +1 @@ +{"version":3,"sources":["uni_modules/lime-choose-file/utssdk/app-android/index.uts","uni_modules/lime-choose-file/utssdk/interface.uts","uni_modules/lime-choose-file/utssdk/unierror.uts"],"sourcesContent":["// @ts-nocheck\r\nimport Intent from 'android.content.Intent';\r\nimport ClipData from 'android.content.ClipData';\r\nimport Uri from 'android.net.Uri';\r\nimport InputStream from 'java.io.InputStream';\r\nimport OpenableColumns from 'android.provider.OpenableColumns';\r\nimport Cursor from 'android.database.Cursor';\r\nimport File from 'java.io.File';\r\nimport FileInputStream from 'java.io.FileInputStream';\r\nimport FileOutputStream from 'java.io.FileOutputStream';\r\nimport BufferedOutputStream from 'java.io.BufferedOutputStream';\r\nimport ByteArrayInputStream from 'java.io.ByteArrayInputStream';\r\n\r\nimport { ChooseFileOption, ChooseFile, ChooseFileSuccessCallbackResult } from '../interface'\r\nimport { GeneralCallbackResultImpl } from '../unierror'\r\n\r\nconst REQUEST_CODE_CHOOSE_FILE : Int = 42\r\nlet resultFunction : ((requestCode : Int, resultCode : Int, data ?: Intent) => void) | null = null\r\n\r\n\r\nclass ChooseFileImpl implements ChooseFile {\r\n\tname : string = ''\r\n\tpath : string = ''\r\n\t// private _path : string = ''\r\n\tsize : number = 0\r\n\ttime : number = 0\r\n\ttype : string = 'file'\r\n\t// private uri : Uri \r\n\tprivate options: ChooseFileOption\r\n\tconstructor(uri : Uri, options : ChooseFileOption) {\r\n\t\t// this.uri = uri\r\n\t\tthis.options = options\r\n\t\tthis.time = Date.now()\r\n\t\tthis.type = this.getFileTypeFromUri(uri);\r\n\t\t// this._path = uri.getPath() ?? ''\r\n\t\tthis.getFileInfoFromUri(uri)\r\n\t\tif (this.isCache(options)) {\r\n\t\t\tthis.copyFileToCache(uri)\r\n\t\t}\r\n\r\n\t}\r\n\tprivate isCache(options : ChooseFileOption) : boolean {\r\n\t\tconst extension = this.getFileExtension(this.name)\r\n\t\tconst extensions = options.extension\r\n\t\tconst type = options.type ?? 'all'\r\n\t\tconst hasExtension = extensions != null && extension != '' && extensions.includes(extension)\r\n\t\tconst isVideoOrImage = ['video', 'image'].includes(type)\r\n\t\tconst isFileAndNotVideoOrImage = type == 'file' && !['video', 'image'].includes(this.type);\r\n\t\tif ((type == 'all' || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) {\r\n\t\t\treturn true\r\n\t\t} else {\r\n\t\t\treturn false\r\n\t\t}\r\n\t}\r\n\tprivate getFileExtension(fileName : string) : string {\r\n\t\tconst lastDotIndex = fileName.lastIndexOf(\".\");\r\n\t\tif (lastDotIndex == -1) {\r\n\t\t\treturn \"\";\r\n\t\t}\r\n\t\treturn fileName.substring(lastDotIndex + 1);\r\n\t}\r\n\tprivate copyFileToCache(uri : Uri) {\r\n\t\tconst cacheDir = UTSAndroid.getAppCachePath();\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tif(cacheDir != null) {\r\n\t\t\tconst path = new File(cacheDir); \r\n\t\t\tif (!path.exists()) { \r\n\t\t\t\tpath.mkdir(); \r\n\t\t\t}\r\n\t\t}\r\n\t\tlet fileName = this.name\r\n\t\tif(this.options.filename != null) {\r\n\t\t\tfileName = this.options.filename!;\r\n\t\t\tif(this.options.count != null && this.options.count! > 1) {\r\n\t\t\t\tfileName = `${fileName}_${Date.now()}`;\r\n\t\t\t}\r\n\t\t\tconst extension = this.getFileExtension(this.name)\r\n\t\t\t\r\n\t\t\tfileName = `${fileName}.${extension}`\r\n\t\t}\r\n\t\tconst destFile = new File(cacheDir, fileName);\r\n\t\t\r\n\t\ttry {\r\n\t\t\tconst inputStream = context!.getContentResolver().openInputStream(uri)\r\n\t\t\tconst outputStream = new FileOutputStream(destFile)\r\n\t\t\tif (inputStream != null) {\r\n\t\t\t\tlet buffer = ByteArray(1024);\r\n\t\t\t\tlet c = inputStream.read(buffer)\r\n\t\t\t\twhile (c > 0) {\r\n\t\t\t\t\toutputStream.write(buffer, 0, c);\r\n\t\t\t\t\tc = inputStream.read(buffer)\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tthis.path = cacheDir + fileName//this.name\r\n\t\t} catch (e) {\r\n\t\t\t\r\n\t\t}\r\n\t}\r\n\tprivate getFileTypeFromUri(uri : Uri) : string {\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tlet fileType = 'file'\r\n\t\tlet mimeType = context!.getContentResolver().getType(uri);\r\n\t\tif (mimeType != null) {\r\n\t\t\tif (mimeType.startsWith(\"video\")) {\r\n\t\t\t\tfileType = \"video\";\r\n\t\t\t} else if (mimeType.startsWith(\"image\")) {\r\n\t\t\t\tfileType = \"image\";\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn fileType;\r\n\t}\r\n\tprivate getFileInfoFromUri(uri : Uri) {\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tlet cursor = context!.getContentResolver().query(uri, null, null, null, null);\r\n\t\tif (cursor != null && cursor.moveToFirst()) {\r\n\t\t\tthis.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME))\r\n\t\t\tconst fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE));\r\n\t\t\tthis.size = Number.from(fileSize)\r\n\t\t\tcursor.close();\r\n\t\t} else if (\"file\".equals(uri.getScheme())) {\r\n\t\t\tthis.name = uri.getLastPathSegment() ?? '';\r\n\t\t\tconst file = new File(uri.getPath() ?? '');\r\n\t\t\tconst fileSize = file.length();\r\n\t\t\tthis.size = Number.from(fileSize)\r\n\t\t}\r\n\t}\r\n}\r\n\r\n\r\nexport function chooseFile(options : ChooseFileOption) {\r\n\tif (resultFunction != null) {\r\n\t\tUTSAndroid.offAppActivityResult(resultFunction!)\r\n\t}\r\n\tconst type = options.type ?? 'all'\r\n\tconst intent = new Intent(Intent.ACTION_GET_CONTENT);\r\n\tif (type.equals(\"all\") || type.equals(\"file\")) {\r\n\t\tintent.setType(\"*/*\");\r\n\t} else if (type.equals(\"video\")) {\r\n\t\tintent.setType(\"video/*\");\r\n\t} else if (type.equals(\"image\")) {\r\n\t\tintent.setType(\"image/*\");\r\n\t}\r\n\tintent.addCategory(Intent.CATEGORY_OPENABLE);\r\n\tintent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, options.count == 1 ? false : true); // 允许多选\r\n\r\n\tresultFunction = (requestCode : Int, resultCode : Int, data ?: Intent) => {\r\n\t\tif (requestCode == REQUEST_CODE_CHOOSE_FILE) {\r\n\t\t\tUTSAndroid.offAppActivityResult(resultFunction!);\r\n\t\t\tif (resultCode == -1 && data != null) {\r\n\t\t\t\tconst clipData = data.getClipData();\r\n\t\t\t\tconst tempFiles : ChooseFile[] = []\r\n\t\t\t\t\r\n\t\t\t\tif (clipData != null) {\r\n\t\t\t\t\t// 多选\r\n\t\t\t\t\t// const itemCount = clipData.getItemCount();\r\n\t\t\t\t\t// if (options.count != null && options.count! > itemCount) {\r\n\t\t\t\t\t// \tconst err = new GeneralCallbackResultImpl(9010002, `选中文件数量超过${options.count}`)\r\n\t\t\t\t\t// \toptions.fail?.(err)\r\n\t\t\t\t\t// \toptions.complete?.(err)\r\n\t\t\t\t\t// \treturn\r\n\t\t\t\t\t// }\r\n\t\t\t\t\tfor (let i = 0; i < clipData.getItemCount(); i++) {\r\n\t\t\t\t\t\tconst uri = clipData.getItemAt(i.toInt()).getUri();\r\n\t\t\t\t\t\tconst chooseFile = new ChooseFileImpl(uri, options);\r\n\t\t\t\t\t\tif(chooseFile.path !=''){\r\n\t\t\t\t\t\t\ttempFiles.push(chooseFile)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\t// 单选\r\n\t\t\t\t\tconst uri = data.getData();\r\n\t\t\t\t\tif (uri != null) {\r\n\t\t\t\t\t\tconst chooseFile = new ChooseFileImpl(uri, options)\r\n\t\t\t\t\t\tif(chooseFile.path !='' ){\r\n\t\t\t\t\t\t\ttempFiles.push(chooseFile)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tconst count = options.count ?? Integer.MAX_VALUE // Number.MAX_VALUE\r\n\t\t\t\tif(tempFiles.length > 0 && count >= tempFiles.length){\r\n\t\t\t\t\toptions.success?.({\r\n\t\t\t\t\t\ttempFiles,\r\n\t\t\t\t\t\terrMsg: 'chooseFile:ok'\r\n\t\t\t\t\t} as ChooseFileSuccessCallbackResult)\r\n\t\t\t\t} else {\r\n\t\t\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件或文件超过设置数量`)\r\n\t\t\t\t\toptions.fail?.(err)\r\n\t\t\t\t\toptions.complete?.(err)\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`)\r\n\t\t\t\toptions.fail?.(err)\r\n\t\t\t\toptions.complete?.(err)\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`)\r\n\t\t\toptions.fail?.(err)\r\n\t\t\toptions.complete?.(err)\r\n\t\t}\r\n\t}\r\n\r\n\tUTSAndroid.onAppActivityResult(resultFunction!)\r\n\tUTSAndroid.getUniActivity()!.startActivityForResult(Intent.createChooser(intent, \"选择文件\"), REQUEST_CODE_CHOOSE_FILE)\r\n\t// UTSAndroid.getUniActivity()!.overridePendingTransition((10).toInt(), (0).toInt());\r\n}","// @ts-nocheck\r\n/**\r\n * 错误码\r\n * 根据uni错误码规范要求,建议错误码以90开头,以下是错误码示例:\r\n * - 9010001 错误信息1\r\n * - 9010002 错误信息2\r\n */\r\nexport type ChooseFileErrorCode = 9010001 | 9010002 | 1101001 | 1101002 | 1101003 | 1101004 | 1101005 | 1101006 | 1101007 | 1101008 | 1101009 | 1101010;\r\n/**\r\n * myApi 的错误回调参数\r\n */\r\nexport interface GeneralCallbackResult extends IUniError {\r\n\terrCode : ChooseFileErrorCode\r\n};\r\n\r\n\r\n/** 返回选择的文件的本地临时文件对象数组 */\r\n\r\nexport interface ChooseFile {\r\n\t/** 选择的文件名称 */\r\n\tname : string\r\n\t/** 本地临时文件路径 (本地路径) */\r\n\tpath : string\r\n\t/** 本地临时文件大小,单位 B */\r\n\tsize : number\r\n\t/** 选择的文件的会话发送时间,Unix时间戳,工具暂不支持此属性 */\r\n\ttime : number\r\n\t/** 选择的文件类型\r\n\t *\r\n\t * 可选值:\r\n\t * - 'video': 选择了视频文件;\r\n\t * - 'image': 选择了图片文件;\r\n\t * - 'file': 选择了除图片和视频的文件; */\r\n\ttype : 'video' | 'image' | 'file' | 'all'\r\n}\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\nexport type ChooseFileSuccessCallbackResult = {\r\n\t/** 返回选择的文件的本地临时文件对象数组 */\r\n\ttempFiles : ChooseFile[],\r\n\terrMsg : string\r\n}\r\n\r\n\r\n/** 接口调用成功的回调函数 */\r\nexport type ChooseFileSuccessCallback = (\r\n\tresult : ChooseFileSuccessCallbackResult\r\n) => void\r\n\r\n/** 接口调用失败的回调函数 */\r\nexport type ChooseFileFailCallback = (res : GeneralCallbackResult) => void\r\n\r\n/** 接口调用结束的回调函数(调用成功、失败都会执行) */\r\nexport type ChooseFileCompleteCallback = (\r\n\tres : GeneralCallbackResult\r\n) => void\r\n\r\nexport type ChooseFileOption = {\r\n\t/**\r\n\t * 指定文件名,如果是多选就在后面增加上时间\r\n\t */\r\n\tfilename?: string\r\n\t/**\r\n\t * 最多可以选择的文件数量。\r\n\t * @defaultValue 100\r\n\t */\r\n\tcount ?: number | null,\r\n\t/**\r\n\t * 所选文件类型\r\n\t * @defaultValue all\r\n\t */\r\n\ttype ?: string | null,\r\n\t/**\r\n\t * 根据文件拓展名过滤,每一项都不能是空字符串。默认不过滤。仅H5支持\r\n\t */\r\n\textension ?: (string[]) | null,\r\n\t/**\r\n\t * 成功则返回图片的本地文件路径列表 tempFilePaths\r\n\t */\r\n\tsuccess ?: ChooseFileSuccessCallback | null,\r\n\t/**\r\n\t * 接口调用失败的回调函数\r\n\t */\r\n\tfail ?: ChooseFileFailCallback | null,\r\n\t/**\r\n\t * 接口调用结束的回调函数(调用成功、失败都会执行)\r\n\t */\r\n\tcomplete ?: ChooseFileCompleteCallback | null\r\n}","// @ts-nocheck\r\n/* 此规范为 uni 规范,可以按照自己的需要选择是否实现 */\r\nimport { ChooseFileErrorCode, GeneralCallbackResult } from \"./interface.uts\"\r\n/**\r\n * 错误主题\r\n * 注意:错误主题一般为插件名称,每个组件不同,需要使用时请更改。\r\n * [可选实现]\r\n */\r\nexport const UniErrorSubject = 'chooseFile\"';\r\n\r\n\r\n/**\r\n * 错误信息\r\n * @UniError\r\n * [可选实现]\r\n */\r\nexport const UniErrors : Map = new Map([\r\n /**\r\n * 错误码及对应的错误信息\r\n */\r\n [9010001, 'chooseFile:ok'],\r\n [9010002, 'ChooseFile:failed'],\r\n]);\r\n\r\n\r\n/**\r\n * 错误对象实现\r\n */\r\nexport class GeneralCallbackResultImpl extends UniError implements GeneralCallbackResult {\r\n\r\n /**\r\n * 错误对象构造函数\r\n */\r\n constructor(errCode : ChooseFileErrorCode, errMsg: string|null = null) {\r\n super();\r\n this.errSubject = UniErrorSubject;\r\n this.errCode = errCode;\r\n this.errMsg = errMsg ?? UniErrors[errCode] ?? \"\";\r\n }\r\n}"],"names":[],"mappings":";;AACA,OAAmB,sBAAwB,AAAC;AAE5C,OAAgB,eAAiB,AAAC;AAElC,OAA4B,gCAAkC,AAAC;;;;;;;;AAE/D,OAAiB,YAAc,AAAC;AAEhC,OAA6B,wBAA0B,AAAC;;;;;;UCF5C,sBAAsB,MAAO;AAInC,SAEL,CAFgB,wBAA8B;aAC9C,GAA6B,CAA7B,SAAU;;AAML,SAgBL,CAhBgB;IAEhB,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAOb,GAAyC,CAAzC,MAAO,MAAO;;AAuB+B,WAAlC;IAEX;aAAA,oBAAY,YAAa;IACzB;aAAA,QAAS,MAAM,CAAA;;;;;;UAKJ,6BACX,QAAS,oCACL,IAAI;UAGG,0BAA0B,KAAM,0BAA0B,IAAI;UAG9D,8BACX,KAAM,0BACF,IAAI;AAEsB,WAAnB;IAIX,SAAA,UAAW,MAAM,SAAA;IAKjB,SAAA,OAAS,MAAM,SAAQ;IAKvB,SAAA,MAAQ,MAAM,SAAQ;IAItB,SAAA,oBAAc,MAAM,UAAW;IAI/B,SAAA,SAAW,kCAAiC;IAI5C,SAAA,MAAQ,+BAA8B;IAItC,SAAA,UAAY,mCAAiC;;;;;;AClGvC,IAAM,kBAAkB;AAQxB,IAAM,WAAY,uBAAI,CAAmB,CAAE,MAAM,IAAI,AAAI,IAAI;IAIlE;AAAC,eAAO,AAAP,CAAO;QAAE;KAAgB,AAA1B,CAA0B;IAC1B;AAAC,eAAO,AAAP,CAAO;QAAE;KAAoB;CAC/B;AAMK,WAAO,4BAAkC,+BAAoB,CAAqB;;;;IAKtF,YAAY,4BAA6B,AAA7B,CAA6B,CAAE,QAAQ,MAAM,IAAQ,IAAI,IACnE,KAAK,GAD8D;QAEnE,IAAI,CAAC,UAAU,GAAG;QAClB,IAAI,CAAC,OAAO,GAAG;QACf,IAAI,CAAC,MAAM,GAAG,OAAM,EAAA,CAAI,SAAS,CAAC,QAAQ,CAAA,EAAA,CAAI;IAChD;;AFtBF,IAAM,0BAA2B,MAAM,EAAE;AACzC,IAAI,kBAAmB,aAAc,GAAd,CAAiB,CAAE,YAAa,GAAb,CAAgB,CAAE,MAAQ,YAAW,IAAI,KAAW,IAAI;AAGlG,WAAM,2BAA0B,CAAU;;;;IACzC,aAAA,MAAO,MAAM,GAAG,EAAE;IAClB,aAAA,MAAO,MAAM,GAAG,EAAE;IAElB,aAAA,MAAO,MAAM,GAAG,CAAC;IACjB,aAAA,MAAO,MAAM,GAAG,CAAC;IACjB,aAAA,MAAO,MAAM,GAAG,MAAM;IAEtB,YAAQ,yBAAyB;IACjC,YAAY,KAAM,GAAG,AAAT,CAAS,CAAE,yBAA0B,CAAA;QAEhD,IAAI,CAAC,OAAO,GAAG;QACf,IAAI,CAAC,IAAI,GAAG,KAAK,GAAG;QACpB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,kBAAkB,CAAC;QAEpC,IAAI,CAAC,kBAAkB,CAAC;QACxB,IAAI,IAAI,CAAC,OAAO,CAAC,UAAU;YAC1B,IAAI,CAAC,eAAe,CAAC;;IAGvB;IACA,YAAQ,QAAQ,yBAA0B,GAAI,OAAO,CAAA;QACpD,IAAM,YAAY,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI;QACjD,IAAM,aAAa,QAAQ,SAAS;QACpC,IAAM,OAAO,QAAQ,IAAI,CAAA,EAAA,CAAI;QAC7B,IAAM,eAAe,WAAU,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,UAAS,EAAA,CAAI,GAAE,EAAA,CAAI,WAAW,QAAQ,CAAC;QAClF,IAAM,iBAAiB;YAAC,OAAA,CAAO;YAAE;SAAQ,CAAC,QAAQ,CAAC;QACnD,IAAM,2BAA2B,KAAI,EAAA,CAAI,OAAM,EAAA,CAAI,CAAC;YAAC,OAAA,CAAO;YAAE;SAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI;QACzF,IAAI,CAAC,KAAI,EAAA,CAAI,MAAK,EAAA,CAAI,eAAc,EAAA,CAAI,wBAAwB,EAAC,EAAA,CAAI,CAAC,cAAc;YACnF,OAAO,IAAI;UACL,IAEN,CAFM;YACN,OAAO,KAAK;;IAEd;IACA,YAAQ,iBAAiB,UAAW,MAAM,GAAI,MAAM,CAAA;QACnD,IAAM,eAAe,SAAS,WAAW,CAAC;QAC1C,IAAI,aAAY,EAAA,CAAI,CAAC,CAAC,EAAE;YACvB,OAAO;;QAER,OAAO,SAAS,SAAS,CAAC,aAAY,CAAA,CAAG,CAAC;IAC3C;IACA,YAAQ,gBAAgB,KAAM,GAAG,EAAA;QAChC,IAAM,WAAW,WAAW,eAAe;QAC3C,IAAM,UAAU,WAAW,aAAa;QACxC,IAAG,SAAQ,EAAA,CAAI,IAAI,EAAE;YACpB,IAAM,OAAO,AAAI,KAAK;YACtB,IAAI,CAAC,KAAK,MAAM,IAAI;gBACnB,KAAK,KAAK;;;QAGZ,IAAI,WAAW,IAAI,CAAC,IAAI;QACxB,IAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAA,EAAA,CAAI,IAAI,EAAE;YACjC,WAAW,IAAI,CAAC,OAAO,CAAC,QAAQ;YAChC,IAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAA,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,IAAI,CAAC,OAAO,CAAC,KAAK,GAAC,CAAA,CAAG,CAAC,EAAE;gBACzD,WAAW,KAAG,WAAQ,MAAI,KAAK,GAAG;;YAEnC,IAAM,YAAY,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI;YAEjD,WAAW,KAAG,WAAQ,MAAI;;QAE3B,IAAM,WAAW,AAAI,KAAK,QAAA,CAAQ,CAAE;QAEpC,IAAI;YACH,IAAM,cAAc,UAAS,kBAAkB,GAAG,eAAe,CAAC;YAClE,IAAM,eAAe,AAAI,iBAAiB;YAC1C,IAAI,YAAW,EAAA,CAAI,IAAI,EAAE;gBACxB,IAAI,SAAS,UAAU,IAAI;gBAC3B,IAAI,IAAI,YAAY,IAAI,CAAC;gBACzB,MAAO,EAAC,CAAA,CAAG,CAAC,CAAE;oBACb,aAAa,KAAK,CAAC,MAAA,CAAM,CAAE,CAAC,AAAD,CAAC,CAAE;oBAC9B,IAAI,YAAY,IAAI,CAAC;;;YAGvB,IAAI,CAAC,IAAI,GAAG,SAAQ,CAAA,CAAG;;SACtB,OAAO,cAAG;IAGb;IACA,YAAQ,mBAAmB,KAAM,GAAG,GAAI,MAAM,CAAA;QAC7C,IAAM,UAAU,WAAW,aAAa;QACxC,IAAI,WAAW;QACf,IAAI,WAAW,UAAS,kBAAkB,GAAG,OAAO,CAAC;QACrD,IAAI,SAAQ,EAAA,CAAI,IAAI,EAAE;YACrB,IAAI,SAAS,UAAU,CAAC,UAAU;gBACjC,WAAW;cACL,IAEN,CAFM,IAAI,SAAS,UAAU,CAAC,UAAU;gBACxC,WAAW;;;QAGb,OAAO;IACR;IACA,YAAQ,mBAAmB,KAAM,GAAG,EAAA;QACnC,IAAM,UAAU,WAAW,aAAa;QACxC,IAAI,SAAS,UAAS,kBAAkB,GAAG,KAAK,CAAC,GAAA,CAAG,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI;QAC5E,IAAI,OAAM,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,OAAO,WAAW,IAAI;YAC3C,IAAI,CAAC,IAAI,GAAG,OAAO,SAAS,CAAC,OAAO,qBAAqB,CAAC,gBAAgB,YAAY;YACtF,IAAM,WAAW,OAAO,OAAO,CAAC,OAAO,qBAAqB,CAAC,gBAAgB,IAAI;YACjF,IAAI,CAAC,IAAI,GAAG,UAAO,IAAI,CAAC;YACxB,OAAO,KAAK;UACN,IAKN,CALM,IAAI,OAAO,MAAM,CAAC,IAAI,SAAS,KAAK;YAC1C,IAAI,CAAC,IAAI,GAAG,IAAI,kBAAkB,GAAE,EAAA,CAAI;YACxC,IAAM,OAAO,AAAI,KAAK,IAAI,OAAO,GAAE,EAAA,CAAI;YACvC,IAAM,WAAW,KAAK,MAAM;YAC5B,IAAI,CAAC,IAAI,GAAG,UAAO,IAAI,CAAC;;IAE1B;;AAIK,IAAU,WAAW,yBAA0B,EAAA;IACpD,IAAI,eAAc,EAAA,CAAI,IAAI,EAAE;QAC3B,WAAW,oBAAoB,CAAC;;IAEjC,IAAM,OAAO,QAAQ,IAAI,CAAA,EAAA,CAAI;IAC7B,IAAM,SAAS,AAAI,OAAO,OAAO,kBAAkB;IACnD,IAAI,KAAK,MAAM,CAAC,OAAM,EAAA,CAAI,KAAK,MAAM,CAAC,SAAS;QAC9C,OAAO,OAAO,CAAC;MACT,IAIN,CAJM,IAAI,KAAK,MAAM,CAAC,UAAU;QAChC,OAAO,OAAO,CAAC;MACT,IAEN,CAFM,IAAI,KAAK,MAAM,CAAC,UAAU;QAChC,OAAO,OAAO,CAAC;;IAEhB,OAAO,WAAW,CAAC,OAAO,iBAAiB;IAC3C,OAAO,QAAQ,CAAC,OAAO,oBAAoB,AAA3B,CAA2B,CAAE,IAAA,QAAQ,KAAK,CAAA,EAAA,CAAI,CAAC,EAAG;QAAA,KAAK;IAAL,EAAQ,IAAI,CAAJ;QAAA,IAAI;IAAJ;IAAI;IAE9E,iBAAiB,IAAC,aAAc,GAAd,CAAiB,CAAE,YAAa,GAAb,CAAgB,CAAE,MAAQ,QAAU;QACxE,IAAI,YAAW,EAAA,CAAI,0BAA0B;YAC5C,WAAW,oBAAoB,CAAC;YAChC,IAAI,WAAU,EAAA,CAAI,CAAC,CAAC,CAAA,EAAA,CAAI,KAAI,EAAA,CAAI,IAAI,EAAE;gBACrC,IAAM,WAAW,KAAK,WAAW;gBACjC,IAAM,kCAA2B,KAAE;gBAEnC,IAAI,SAAQ,EAAA,CAAI,IAAI,EAAE;wBASrB;wBAAK,IAAI,YAAI,CAAC;wBAAd,MAAgB,EAAC,CAAA,CAAG,SAAS,YAAY;4BACxC,IAAM,MAAM,SAAS,SAAS,CAAC,EAAE,KAAK,IAAI,MAAM;4BAChD,IAAM,aAAa,AAAI,eAAe,GAAA,CAAG,CAAE;4BAC3C,IAAG,WAAW,IAAI,CAAA,EAAA,CAAG,IAAG;gCACvB,UAAU,IAAI,CAAC;;4BAJ4B;;;kBAOvC,IAUN,CAVM;oBAEN,IAAM,MAAM,KAAK,OAAO;oBACxB,IAAI,IAAG,EAAA,CAAI,IAAI,EAAE;wBAChB,IAAM,aAAa,AAAI,eAAe,GAAA,CAAG,CAAE;wBAC3C,IAAG,WAAW,IAAI,CAAA,EAAA,CAAG,IAAI;4BACxB,UAAU,IAAI,CAAC;;;iBAIjB;gBACD,IAAM,QAAQ,QAAQ,KAAK,CAAA,EAAA,CAAI,QAAQ,SAAS;gBAChD,IAAG,UAAU,MAAM,CAAA,CAAA,CAAG,CAAC,CAAA,EAAA,CAAI,MAAK,EAAA,CAAI,UAAU,MAAM,EAAC;oBACpD,QAAQ,OAAO,SAGV,gCAFJ,YAAA,WACA,SAAQ;kBAEH,IAIN,CAJM;oBACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;oBACnD,QAAQ,IAAI,SAAG;oBACf,QAAQ,QAAQ,SAAG;iBACnB;cACK,IAIN,CAJM;gBACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;gBACnD,QAAQ,IAAI,SAAG;gBACf,QAAQ,QAAQ,SAAG;aACnB;UACK,IAIN,CAJM;YACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;YACnD,QAAQ,IAAI,SAAG;YACf,QAAQ,QAAQ,SAAG;;IAErB;IAEA,WAAW,mBAAmB,CAAC;IAC/B,WAAW,cAAc,KAAI,sBAAsB,CAAC,OAAO,aAAa,CAAC,MAAA,CAAM,CAAE,OAA7B,CAAoC,CAAE;AAE3F;ACjI+B;IAI9B,SAAA,UAAW,MAAM,QAAA;IAKjB,SAAA,OAAS,MAAM,QAAQ;IAKvB,SAAA,MAAQ,MAAM,QAAQ;IAItB,SAAA,oBAAc,MAAM,SAAW;IAI/B,SAAA,SAAS,mBAAmC;IAI5C,SAAA,MAAM,mBAAgC;IAItC,SAAA,UAAU,mBAAmC;;mBDuBnB,mCAA0B;6JChEpD,QAAS,kCACL,IAAI;gCADR;;iBAIqC,KAAM,wBAA0B,IAAI;6BAApC;;qBAIrC,KAAM,wBACF,IAAI;iCADR"} \ No newline at end of file diff --git a/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/manifest.json b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/manifest.json new file mode 100644 index 0000000..e42fee8 --- /dev/null +++ b/unpackage/cache/uts_custom_android/app-android/uts/uni_modules/lime-choose-file/manifest.json @@ -0,0 +1,32 @@ +{ + "version": "1", + "env": { + "compilerVersion": "5.07" + }, + "files": { + "utssdk/app-android/index.uts": { + "md5": "41a4e16dddeba7d4a58db6399cd86ee8" + }, + "utssdk/index.uts": { + "md5": "e6a6ba045e443b3a4973f9217894fa1c" + }, + "utssdk/interface.uts": { + "md5": "1b0ac84897039cfd08776b87e0c6582a" + }, + "utssdk/unierror.uts": { + "md5": "82736e70a9d5007436651a5d33897b4e" + }, + "package.json": { + "md5": "4d1ca74cea144db04520444b4216f76b" + }, + "readme copy.md": { + "md5": "6a3473bb03cb1f311be627c885b49dbe" + }, + "utssdk/app-android/AndroidManifest.xml": { + "md5": "e7b416d035a0a308cd13eba12b2db438" + }, + "utssdk/app-android/config.json": { + "md5": "49e34dad9b85d9ddf183e599555456fa" + } + } +} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/app-config-service.js b/unpackage/dist/build/app-plus/app-config-service.js index 1573ffe..84270da 100644 --- a/unpackage/dist/build/app-plus/app-config-service.js +++ b/unpackage/dist/build/app-plus/app-config-service.js @@ -2,7 +2,7 @@ ;(function(){ let u=void 0,isReady=false,onReadyCallbacks=[],isServiceReady=false,onServiceReadyCallbacks=[]; const __uniConfig = {"pages":[],"globalStyle":{"backgroundColor":"#F8F8F8","navigationBar":{"backgroundColor":"#F8F8F8","titleText":"uni-app","type":"default","titleColor":"#000000"},"isNVue":false},"nvue":{"compiler":"uni-app","styleCompiler":"uni-app","flex-direction":"column"},"renderer":"auto","appname":"test1","splashscreen":{"alwaysShowBeforeRender":true,"autoclose":true},"compilerVersion":"5.07","entryPagePath":"pages/Login/Login","entryPageQuery":"","realEntryPagePath":"","networkTimeout":{"request":60000,"connectSocket":60000,"uploadFile":60000,"downloadFile":60000},"locales":{},"darkmode":false,"themeConfig":{}}; - const __uniRoutes = [{"path":"pages/Login/Login","meta":{"isQuit":true,"isEntry":true,"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"登录页面","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/Chat/Chat","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"聊天页面(主页面)","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/WorkSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"工作区文件管理","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/UserProfileModal/UserProfileModal","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/ContactPages/ContactPages","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/TemplateSpace/TemplateSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/text/text","meta":{"navigationBar":{"titleText":"","type":"default"},"isNVue":false}},{"path":"pages/text/text2","meta":{"navigationBar":{"type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute)); + const __uniRoutes = [{"path":"pages/Login/Login","meta":{"isQuit":true,"isEntry":true,"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"登录页面","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/Chat/Chat","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"聊天页面(主页面)","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/WorkSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"工作区文件管理","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/UserProfileModal/UserProfileModal","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/ContactPages/ContactPages","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/TemplateSpace/TemplateSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/text/text","meta":{"navigationBar":{"titleText":"","type":"default"},"isNVue":false}},{"path":"pages/text/text2","meta":{"navigationBar":{"type":"default"},"isNVue":false}},{"path":"pages/CloudDatabase/CloudDatabase","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"云端数据","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/CloudDbDetail/CloudDbDetail","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"数据库详情","style":"custom","type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute)); __uniConfig.styles=[];//styles __uniConfig.onReady=function(callback){if(__uniConfig.ready){callback()}else{onReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"ready",{get:function(){return isReady},set:function(val){isReady=val;if(!isReady){return}const callbacks=onReadyCallbacks.slice(0);onReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}}); __uniConfig.onServiceReady=function(callback){if(__uniConfig.serviceReady){callback()}else{onServiceReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"serviceReady",{get:function(){return isServiceReady},set:function(val){isServiceReady=val;if(!isServiceReady){return}const callbacks=onServiceReadyCallbacks.slice(0);onServiceReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}}); diff --git a/unpackage/dist/build/app-plus/app-service.js b/unpackage/dist/build/app-plus/app-service.js index 9d5e885..1144daa 100644 --- a/unpackage/dist/build/app-plus/app-service.js +++ b/unpackage/dist/build/app-plus/app-service.js @@ -1,7 +1,7 @@ -if("undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(e){const t=this.constructor;return this.then((a=>t.resolve(e()).then((()=>a))),(a=>t.resolve(e()).then((()=>{throw a}))))}),"undefined"!=typeof uni&&uni&&uni.requireGlobal){const e=uni.requireGlobal();ArrayBuffer=e.ArrayBuffer,Int8Array=e.Int8Array,Uint8Array=e.Uint8Array,Uint8ClampedArray=e.Uint8ClampedArray,Int16Array=e.Int16Array,Uint16Array=e.Uint16Array,Int32Array=e.Int32Array,Uint32Array=e.Uint32Array,Float32Array=e.Float32Array,Float64Array=e.Float64Array,BigInt64Array=e.BigInt64Array,BigUint64Array=e.BigUint64Array}uni.restoreGlobal&&uni.restoreGlobal(Vue,weex,plus,setTimeout,clearTimeout,setInterval,clearInterval),function(e){"use strict";function t(e,t,...a){uni.__log__?uni.__log__(e,t,...a):console[e].apply(console,[...a,t])}function a(e,t){return"string"==typeof e?t:e}const n=((t,a=0)=>(a,n=e.getCurrentInstance())=>{!e.isInSSRComponentSetup&&e.injectHook(t,a,n)})("onShow",3),o="https://cloud.yuxindazhineng.com",l=async e=>new Promise(((t,a)=>{uni.request({url:`${o}/get_user_info`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e},success:e=>{var n,o;if(200===e.statusCode){const l=e.data;if(null==l?void 0:l._id)uni.setStorageSync("userId",l._id),t(l);else{const e=(null==(o=null==(n=null==l?void 0:l.detail)?void 0:n[0])?void 0:o.msg)||"获取用户信息出错啦";a(e)}}else a(`获取用户信息失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})),s=(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/get_user_avatar`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,user_ids:t},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)a(t.users);else{const e=(null==t?void 0:t.error)||"获取用户头像出错啦";n(e)}}else n(`获取用户头像失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),c=(e,t)=>{const a=e.__vccOpts||e;for(const[n,o]of t)a[n]=o;return a},i=c({__name:"Login",setup(a){const n=e.ref(""),l=e.ref(!1),s=e.ref(!1),c=()=>{l.value=!0,h.value=!1},i=()=>{l.value=!1},r=()=>{},d=e.ref(""),u=e.ref(!1),m=e.ref(!1),v=()=>{u.value=!0,h.value=!1},p=()=>{u.value=!1},f=e.reactive({username:e.computed((()=>n.value)),password:e.computed((()=>d.value)),remember:!0}),g=e.ref(!1),h=e.ref(!1),w=async()=>{if(k(),!h.value){g.value=!0;try{await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/login`,method:"POST",data:{username:e,password:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.access_token;if(t)uni.setStorageSync("token",t),a(t);else{const t=e.data.error||"检查用户名和密码";n(t)}}else n(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(n.value,d.value);y(),uni.reLaunch({url:"/pages/Chat/Chat"})}catch(e){t("log","at pages/Login/Login.vue:124","登录失败",e),uni.showToast({title:e||"失败",icon:"error"})}finally{g.value=!1}}},k=()=>{n.value&&d.value||(h.value=!0)},y=()=>{if(f.remember){const e={username:f.username,password:f.password,remember:!0};uni.setStorageSync("login_info",e),uni.setStorageSync("chatType",0)}else uni.removeStorageSync("login_info")};return e.onMounted((()=>{(()=>{try{const e=uni.getStorageSync("login_info");e&&(n.value=e.username||"",d.value=e.password||"",f.remember=e.remember??!0)}catch(e){t("error","at pages/Login/Login.vue:168","读取登录信息失败",e)}})()})),(t,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"login-container page-container"},[e.createElementVNode("view",{class:"login-card"},[e.createElementVNode("view",{class:"login-header"},[e.createElementVNode("view",{class:"login-header-logo"},[e.createElementVNode("view",{class:"icon-wrapper"},[e.createElementVNode("view",{class:"iconfont icon-brain-2-fill danao-style"})]),e.createElementVNode("text",null,"YXD")]),e.createElementVNode("view",{class:"sub-title"},"File Handling Chat")]),e.createElementVNode("view",{class:"form-wrapper"},[e.createElementVNode("view",{class:"form-item"},[e.createElementVNode("view",{class:"form-label"},[e.createElementVNode("text",null,"用户名")]),e.withDirectives(e.createElementVNode("input",{class:e.normalizeClass(["form-input",{focused:l.value,error:s.value}]),"onUpdate:modelValue":a[0]||(a[0]=e=>n.value=e),onFocus:c,onBlur:i,onInput:r,placeholder:"请输入用户名"},null,34),[[e.vModelText,n.value]])]),e.createElementVNode("view",{class:"form-item"},[e.createElementVNode("view",{class:"form-label"},[e.createElementVNode("text",null,"密码")]),e.withDirectives(e.createElementVNode("input",{type:"password",class:e.normalizeClass(["form-input",{focused:u.value,error:m.value}]),"onUpdate:modelValue":a[1]||(a[1]=e=>d.value=e),onFocus:v,onBlur:p,placeholder:"请输入密码"},null,34),[[e.vModelText,d.value]])]),h.value?(e.openBlock(),e.createElementBlock("text",{key:0,class:"error-info"},"用户名或密码不能为空")):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"form-option"},[e.createElementVNode("view",{class:"checkbox-wrapper",onClick:a[2]||(a[2]=e=>f.remember=!f.remember)},[e.createElementVNode("view",{class:e.normalizeClass(["checkbox",{checked:f.remember}])},[f.remember?(e.openBlock(),e.createElementBlock("text",{key:0},"✓")):e.createCommentVNode("",!0)],2),e.createElementVNode("text",{class:"checkbox-text"},"记住密码")]),e.createElementVNode("text",{class:"forget-pwd"},"忘记密码?")]),e.createElementVNode("button",{class:"login-btn",disabled:g.value,loading:g.value,onClick:w},e.toDisplayString(g.value?"Loading...":"登录"),9,["disabled","loading"])])])])],64))}},[["__scopeId","data-v-d4b9d5ac"]]),r=[{font_class:"arrow-down",unicode:""},{font_class:"arrow-left",unicode:""},{font_class:"arrow-right",unicode:""},{font_class:"arrow-up",unicode:""},{font_class:"auth",unicode:""},{font_class:"auth-filled",unicode:""},{font_class:"back",unicode:""},{font_class:"bars",unicode:""},{font_class:"calendar",unicode:""},{font_class:"calendar-filled",unicode:""},{font_class:"camera",unicode:""},{font_class:"camera-filled",unicode:""},{font_class:"cart",unicode:""},{font_class:"cart-filled",unicode:""},{font_class:"chat",unicode:""},{font_class:"chat-filled",unicode:""},{font_class:"chatboxes",unicode:""},{font_class:"chatboxes-filled",unicode:""},{font_class:"chatbubble",unicode:""},{font_class:"chatbubble-filled",unicode:""},{font_class:"checkbox",unicode:""},{font_class:"checkbox-filled",unicode:""},{font_class:"checkmarkempty",unicode:""},{font_class:"circle",unicode:""},{font_class:"circle-filled",unicode:""},{font_class:"clear",unicode:""},{font_class:"close",unicode:""},{font_class:"closeempty",unicode:""},{font_class:"cloud-download",unicode:""},{font_class:"cloud-download-filled",unicode:""},{font_class:"cloud-upload",unicode:""},{font_class:"cloud-upload-filled",unicode:""},{font_class:"color",unicode:""},{font_class:"color-filled",unicode:""},{font_class:"compose",unicode:""},{font_class:"contact",unicode:""},{font_class:"contact-filled",unicode:""},{font_class:"down",unicode:""},{font_class:"bottom",unicode:""},{font_class:"download",unicode:""},{font_class:"download-filled",unicode:""},{font_class:"email",unicode:""},{font_class:"email-filled",unicode:""},{font_class:"eye",unicode:""},{font_class:"eye-filled",unicode:""},{font_class:"eye-slash",unicode:""},{font_class:"eye-slash-filled",unicode:""},{font_class:"fire",unicode:""},{font_class:"fire-filled",unicode:""},{font_class:"flag",unicode:""},{font_class:"flag-filled",unicode:""},{font_class:"folder-add",unicode:""},{font_class:"folder-add-filled",unicode:""},{font_class:"font",unicode:""},{font_class:"forward",unicode:""},{font_class:"gear",unicode:""},{font_class:"gear-filled",unicode:""},{font_class:"gift",unicode:""},{font_class:"gift-filled",unicode:""},{font_class:"hand-down",unicode:""},{font_class:"hand-down-filled",unicode:""},{font_class:"hand-up",unicode:""},{font_class:"hand-up-filled",unicode:""},{font_class:"headphones",unicode:""},{font_class:"heart",unicode:""},{font_class:"heart-filled",unicode:""},{font_class:"help",unicode:""},{font_class:"help-filled",unicode:""},{font_class:"home",unicode:""},{font_class:"home-filled",unicode:""},{font_class:"image",unicode:""},{font_class:"image-filled",unicode:""},{font_class:"images",unicode:""},{font_class:"images-filled",unicode:""},{font_class:"info",unicode:""},{font_class:"info-filled",unicode:""},{font_class:"left",unicode:""},{font_class:"link",unicode:""},{font_class:"list",unicode:""},{font_class:"location",unicode:""},{font_class:"location-filled",unicode:""},{font_class:"locked",unicode:""},{font_class:"locked-filled",unicode:""},{font_class:"loop",unicode:""},{font_class:"mail-open",unicode:""},{font_class:"mail-open-filled",unicode:""},{font_class:"map",unicode:""},{font_class:"map-filled",unicode:""},{font_class:"map-pin",unicode:""},{font_class:"map-pin-ellipse",unicode:""},{font_class:"medal",unicode:""},{font_class:"medal-filled",unicode:""},{font_class:"mic",unicode:""},{font_class:"mic-filled",unicode:""},{font_class:"micoff",unicode:""},{font_class:"micoff-filled",unicode:""},{font_class:"minus",unicode:""},{font_class:"minus-filled",unicode:""},{font_class:"more",unicode:""},{font_class:"more-filled",unicode:""},{font_class:"navigate",unicode:""},{font_class:"navigate-filled",unicode:""},{font_class:"notification",unicode:""},{font_class:"notification-filled",unicode:""},{font_class:"paperclip",unicode:""},{font_class:"paperplane",unicode:""},{font_class:"paperplane-filled",unicode:""},{font_class:"person",unicode:""},{font_class:"person-filled",unicode:""},{font_class:"personadd",unicode:""},{font_class:"personadd-filled",unicode:""},{font_class:"personadd-filled-copy",unicode:""},{font_class:"phone",unicode:""},{font_class:"phone-filled",unicode:""},{font_class:"plus",unicode:""},{font_class:"plus-filled",unicode:""},{font_class:"plusempty",unicode:""},{font_class:"pulldown",unicode:""},{font_class:"pyq",unicode:""},{font_class:"qq",unicode:""},{font_class:"redo",unicode:""},{font_class:"redo-filled",unicode:""},{font_class:"refresh",unicode:""},{font_class:"refresh-filled",unicode:""},{font_class:"refreshempty",unicode:""},{font_class:"reload",unicode:""},{font_class:"right",unicode:""},{font_class:"scan",unicode:""},{font_class:"search",unicode:""},{font_class:"settings",unicode:""},{font_class:"settings-filled",unicode:""},{font_class:"shop",unicode:""},{font_class:"shop-filled",unicode:""},{font_class:"smallcircle",unicode:""},{font_class:"smallcircle-filled",unicode:""},{font_class:"sound",unicode:""},{font_class:"sound-filled",unicode:""},{font_class:"spinner-cycle",unicode:""},{font_class:"staff",unicode:""},{font_class:"staff-filled",unicode:""},{font_class:"star",unicode:""},{font_class:"star-filled",unicode:""},{font_class:"starhalf",unicode:""},{font_class:"trash",unicode:""},{font_class:"trash-filled",unicode:""},{font_class:"tune",unicode:""},{font_class:"tune-filled",unicode:""},{font_class:"undo",unicode:""},{font_class:"undo-filled",unicode:""},{font_class:"up",unicode:""},{font_class:"top",unicode:""},{font_class:"upload",unicode:""},{font_class:"upload-filled",unicode:""},{font_class:"videocam",unicode:""},{font_class:"videocam-filled",unicode:""},{font_class:"vip",unicode:""},{font_class:"vip-filled",unicode:""},{font_class:"wallet",unicode:""},{font_class:"wallet-filled",unicode:""},{font_class:"weibo",unicode:""},{font_class:"weixin",unicode:""}];const d=c({name:"UniIcons",emits:["click"],props:{type:{type:String,default:""},color:{type:String,default:"#333333"},size:{type:[Number,String],default:16},customPrefix:{type:String,default:""},fontFamily:{type:String,default:""}},data:()=>({icons:r}),computed:{unicode(){let e=this.icons.find((e=>e.font_class===this.type));return e?e.unicode:""},iconSize(){return"number"==typeof(e=this.size)||/^[0-9]*$/g.test(e)?e+"px":e;var e},styleObj(){return""!==this.fontFamily?`color: ${this.color}; font-size: ${this.iconSize}; font-family: ${this.fontFamily};`:`color: ${this.color}; font-size: ${this.iconSize};`}},methods:{_onClick(e){this.$emit("click",e)}}},[["render",function(t,a,n,o,l,s){return e.openBlock(),e.createElementBlock("text",{style:e.normalizeStyle(s.styleObj),class:e.normalizeClass(["uni-icons",["uniui-"+n.type,n.customPrefix,n.customPrefix?n.type:""]]),onClick:a[0]||(a[0]=(...e)=>s._onClick&&s._onClick(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-b25a9929"]]),u=()=>uni.getStorageSync("token"),m=()=>{const e=uni.getStorageSync("currentSessionId");return isNaN(Number(e))?e.replace(/-/g,""):e},v=()=>uni.getStorageSync("taskCallId"),p=c(Object.assign({name:"ChatSidebar"},{__name:"ChatSidebar",props:{chatList:{type:Array,required:!0},showNewChatModal:{type:Boolean,default:!1},currentSessionId:{type:[String,Number],required:!0},chatType:{type:Number,required:!0}},emits:["update:showNewChatModal","update:currentSessionId","refresh-conversations","update:chatType"],setup(n,{emit:l}){const s=n,c=l,i=e.toRef(s,"chatList");e.toRef(s,"showNewChatModal");const r=e.toRef(s,"chatType"),m=()=>{uni.navigateTo({url:"/pages/UserProfileModal/UserProfileModal"})},v=e.ref(!1),p=e.ref([]),f=async()=>{try{const e=u();await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/delete_conversation`,method:"POST",data:{access_token:e,conversation_ids:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)a(t.message);else{const e=t.failed_ids.error||"删除对话出错啦";n(e)}}else n(`删除对话失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(e,p.value),uni.showToast({title:"删除成功",icon:"success"}),p.value=[],v.value=!1,c("refresh-conversations")}catch(e){t("error","at components/ChatSidebar.vue:188","删除会话失败:",e),uni.showToast({title:"删除失败,请重试",icon:"none"})}},g=e.computed((()=>i.value.length>0&&p.value.length===i.value.length)),h=e.toRef(s,"currentSessionId"),w=(e,a="")=>{t("log","at components/ChatSidebar.vue:206","选择的id是:",e),a&&uni.setStorageSync("receiverId",a),uni.setStorageSync("currentSessionId",e),c("update:currentSessionId",e)},k=()=>{t("log","at components/ChatSidebar.vue:217","点击了新建会话"),c("update:showNewChatModal",!0)},y=()=>{uni.navigateTo({url:"/pages/ContactPages/ContactPages"})},E=e.ref(""),N=e.ref(!1),V=()=>{v.value=!v.value,v.value||(p.value=[])},b=e=>{const t=p.value.indexOf(e);-1===t?p.value.push(e):p.value.splice(t,1)},C=()=>{g.value?p.value=[]:p.value=i.value.map((e=>e._id))};return e.onMounted((()=>{t("log","at components/ChatSidebar.vue:264","会话数据:"),t("log","at components/ChatSidebar.vue:265",s.chatList)})),(t,n)=>{const o=a(e.resolveDynamicComponent("uni-icons"),d);return e.openBlock(),e.createElementBlock("view",{class:"chat-sidebar-container"},[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"sidebar-header"},[e.createElementVNode("view",{class:"user-profile-card",onClick:m},[e.createElementVNode("view",{class:"left"},[e.createVNode(o,{type:"contact-filled",size:"50",color:"#007aff"})]),e.createElementVNode("view",{class:"center"},[e.createElementVNode("text",null,"欢迎回来"),e.createElementVNode("text",null,"用户名")]),e.createElementVNode("view",{class:"right"},[e.createElementVNode("view",{class:"status-dot"}),e.createElementVNode("view",{class:"status-text"},[e.createElementVNode("text",null,"在线")])])]),e.createElementVNode("view",{class:"new-chat-btn",onClick:y},[e.createElementVNode("text",null,"+ 聊天列表")])]),e.createElementVNode("view",{class:"chat-history"},[e.createElementVNode("view",{class:"history-header"},[e.createElementVNode("view",{class:"history-title-section"},[e.createElementVNode("text",null,"历史会话"),e.createElementVNode("text",null,e.toDisplayString(i.value.length)+"个对话",1)]),e.createElementVNode("view",{class:"history-management"},[v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-management-btn iconfont icon-jia icon-jia-style",onClick:k})),v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:1,class:"history-management-btn iconfont icon-duoxuan icon-duoxuan-style",onClick:V})),v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:2,class:"history-management-btn iconfont icon-saochu icon-saochu-style"})),v.value&&p.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:3,class:"history-management-btn iconfont icon-shanchu icon-shanchu-style",onClick:f})):e.createCommentVNode("",!0),v.value?(e.openBlock(),e.createElementBlock("view",{key:4,class:e.normalizeClass(["history-management-btn iconfont icon-total_selection icon-total_selection-style",{active:g.value}]),onClick:C},null,2)):e.createCommentVNode("",!0),v.value?(e.openBlock(),e.createElementBlock("view",{key:5,class:"history-management-btn iconfont icon-quxiao icon-quxiao-style",onClick:V})):e.createCommentVNode("",!0)])]),v.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-search-wrap"},[e.createElementVNode("view",{class:e.normalizeClass(["history-search-inner",{"has-value":E.value||N.value}])},[e.createVNode(o,{type:"search",class:e.normalizeClass([E.value||N.value?"chat-search-icon":"search-icon"])},null,8,["class"]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[0]||(n[0]=e=>E.value=e),onFocus:n[1]||(n[1]=e=>N.value=!0),onBlur:n[2]||(n[2]=e=>N.value=!1),type:"text",placeholder:"搜索会话..."},null,544),[[e.vModelText,E.value]])],2)])),e.createElementVNode("view",{class:"chat-history-list"},[0===r.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(i.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t._id,"data-chat-id":t._id,class:e.normalizeClass(["chat-history-card",{"is-select-chat":h.value===t._id||p.value.includes(t._id)}]),onClick:e=>v.value?b(t._id):w(t._id)},[v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[p.value.includes(t._id)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[e.createVNode(o,{type:"chat-filled",size:"26",color:"#007aff"})]),e.createElementVNode("view",null,e.toDisplayString(t.title),1)],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0),1===r.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(i.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t.sessionId,"data-chat-id":t.sessionId,class:e.normalizeClass(["chat-history-card",{"is-select-chat":h.value===t.sessionId||p.value.includes(t.sessionId)}]),onClick:e=>v.value?b(t.sessionId):w(t.sessionId,t.receiver)},[v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[p.value.includes(t.sessionId)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):e.createCommentVNode("",!0)]),e.createElementVNode("view",null,e.toDisplayString(t.friendNickName),1)],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0),2===r.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(i.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t.id,"data-chat-id":t.id,class:e.normalizeClass(["chat-history-card",{"is-select-chat":h.value===t.id||p.value.includes(t.id)}]),onClick:e=>v.value?b(t.id):w(t.id)},[v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[p.value.includes(t.id)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[e.createElementVNode("view",{class:"iconfont icon-qunliao",style:{"font-size":"80rpx",color:"#fff"}})]),e.createElementVNode("view",null,e.toDisplayString(t.name),1)],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0)])])])}}}),[["__scopeId","data-v-8ade48e4"]]);var f={"":["",""],_:["",""],"*":["",""],"~":["",""],"\n":["
"]," ":["
"],"-":["
"]};function g(e){return e.replace(RegExp("^"+(e.match(/^(\t| )+/)||"")[0],"gm"),"")}function h(e){return(e+"").replace(/"/g,""").replace(//g,">")}function w(e,t){var a,n,o,l,s,c=/((?:^|\n+)(?:\n---+|\* \*(?: \*)+)\n)|(?:^``` *(\w*)\n([\s\S]*?)\n```$)|((?:(?:^|\n+)(?:\t| {2,}).+)+\n*)|((?:(?:^|\n)([>*+-]|\d+\.)\s+.*)+)|(?:!\[([^\]]*?)\]\(([^)]+?)\))|(\[)|(\](?:\(([^)]+?)\))?)|(?:(?:^|\n+)([^\s].*)\n(-{3,}|={3,})(?:\n+|$))|(?:(?:^|\n+)(#{1,6})\s*(.+)(?:\n+|$))|(?:`([^`].*?)`)|( \n\n*|\n{2,}|__|\*\*|[_*]|~~)/gm,i=[],r="",d=t||{},u=0;function m(e){var t=f[e[1]||""],a=i[i.length-1]==e;return t?t[1]?(a?i.pop():i.push(e),t[0|a]):t[0]:e}function v(){for(var e="";i.length;)e+=m(i[i.length-1]);return e}for(e=e.replace(/^\[(.+?)\]:\s*(.+)$/gm,(function(e,t,a){return d[t.toLowerCase()]=a,""})).replace(/^\n+|\n+$/g,"");o=c.exec(e);)n=e.substring(u,o.index),u=c.lastIndex,a=o[0],n.match(/[^\\](\\\\)*\\$/)||((s=o[3]||o[4])?a='
"+g(h(s).replace(/^\n+|\n+$/g,""))+"
":(s=o[6])?(s.match(/\./)&&(o[5]=o[5].replace(/^\d+/gm,"")),l=w(g(o[5].replace(/^\s*[>*+.-]/gm,""))),">"==s?s="blockquote":(s=s.match(/\./)?"ol":"ul",l=l.replace(/^(.*)(\n|$)/gm,"
  • $1
  • ")),a="<"+s+">"+l+""):o[8]?a=''+h(o[7])+'':o[10]?(r=r.replace("",''),a=v()+""):o[9]?a="":o[12]||o[14]?a="<"+(s="h"+(o[14]?o[14].length:o[13]>"="?1:2))+">"+w(o[12]||o[15],d)+"":o[16]?a=""+h(o[16])+"":(o[17]||o[1])&&(a=m(o[17]||"--"))),r+=n,r+=a;return(r+e.substring(u)+v()).replace(/^\n+|\n+$/g,"")} +if("undefined"==typeof Promise||Promise.prototype.finally||(Promise.prototype.finally=function(e){const t=this.constructor;return this.then((a=>t.resolve(e()).then((()=>a))),(a=>t.resolve(e()).then((()=>{throw a}))))}),"undefined"!=typeof uni&&uni&&uni.requireGlobal){const e=uni.requireGlobal();ArrayBuffer=e.ArrayBuffer,Int8Array=e.Int8Array,Uint8Array=e.Uint8Array,Uint8ClampedArray=e.Uint8ClampedArray,Int16Array=e.Int16Array,Uint16Array=e.Uint16Array,Int32Array=e.Int32Array,Uint32Array=e.Uint32Array,Float32Array=e.Float32Array,Float64Array=e.Float64Array,BigInt64Array=e.BigInt64Array,BigUint64Array=e.BigUint64Array}uni.restoreGlobal&&uni.restoreGlobal(Vue,weex,plus,setTimeout,clearTimeout,setInterval,clearInterval),function(e){"use strict";function t(e,t,...a){uni.__log__?uni.__log__(e,t,...a):console[e].apply(console,[...a,t])}function a(e,t){return"string"==typeof e?t:e}const n=((t,a=0)=>(a,n=e.getCurrentInstance())=>{!e.isInSSRComponentSetup&&e.injectHook(t,a,n)})("onShow",3),o="https://cloud.yuxindazhineng.com",l=async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/delete_conversation`,method:"POST",data:{access_token:e,conversation_ids:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)a(t.message);else{const e=t.failed_ids.error||"删除对话出错啦";n(e)}}else n(`删除对话失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),s=async e=>new Promise(((t,a)=>{uni.request({url:`${o}/get_user_info`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e},success:e=>{var n,o;if(200===e.statusCode){const l=e.data;if(null==l?void 0:l._id)uni.setStorageSync("userId",l._id),t(l);else{const e=(null==(o=null==(n=null==l?void 0:l.detail)?void 0:n[0])?void 0:o.msg)||"获取用户信息出错啦";a(e)}}else a(`获取用户信息失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})),c=(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/get_user_avatar`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,user_ids:t},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)a(t.users);else{const e=(null==t?void 0:t.error)||"获取用户头像出错啦";n(e)}}else n(`获取用户头像失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),i=(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/search_users`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,keyword:t},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)a(t.users);else{const e=(null==t?void 0:t.error)||"通过用户名或邮箱来去查询用户出错啦";n(e)}}else n(`通过用户名或邮箱来去查询用户失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),r=(e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/phone/workspace/delete`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,workspaces_id:t,file_path:a},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.message);else{const e=(null==t?void 0:t.error)||"删除工作区文件出错啦";l(e)}}else l(`删除工作区文件失败:${e.statusCode}`)}})})),u=(e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/phone/workspace/create`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,workspaces_id:t,dir_path:a},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.message);else{const e=(null==t?void 0:t.error)||"创建工作区文件夹出错啦";l(e)}}else l(`创建工作区文件夹失败:${e.statusCode}`)}})})),d=(e,t,a="/",n="")=>new Promise(((l,s)=>{uni.request({url:`${o}/cloud_api/file/list`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,path:a,type:t,team_id:n},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)l(t.data);else{const e=(null==t?void 0:t.error)||"获取工作区文件目录出错啦";s(e)}}else s(`获取工作区文件目录失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})),m=async e=>new Promise(((t,a)=>{uni.request({url:`${o}/cloud_api/team/list`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_name:""},success:e=>{if(200===e.statusCode){const n=e.data;if(n.success){const e=n.teams.slice(1);t(e)}else{const t=e.data.error||"获取用户可访问的团队列表出错啦";a(t)}}else a(`获取用户可访问的团队列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})),v=(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/team/get_all_member`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_id:t},success:e=>{var t;if(200===e.statusCode){const o=e.data;if(o.success){const e=(null==(t=o.team)?void 0:t.result)||[];a(e)}else{const e=(null==o?void 0:o.error)||"获取团队全部成员出错啦";n(e)}}else n(`获取团队全部成员失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),p=(e,t,a,n)=>new Promise(((l,s)=>{const c={access_token:e,database_id:t};"user_id"===a?c.user_id=n:"team_id"===a&&(c.team_id=n),uni.request({url:`${o}/cloud_api/database/permission/info`,method:"POST",data:c,header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)l(t.data);else if(Array.isArray(t))l(t);else{const e=(null==t?void 0:t.error)||"查看 个人/团队 数据库权限信息出错啦";s(e)}}else s(`查看 个人/团队 数据库权限信息失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})),f=(e,t)=>{const a=e.__vccOpts||e;for(const[n,o]of t)a[n]=o;return a},h=f({__name:"Login",setup(a){const n=e.ref(""),l=e.ref(!1),s=e.ref(!1),c=()=>{l.value=!0,g.value=!1},i=()=>{l.value=!1},r=()=>{},u=e.ref(""),d=e.ref(!1),m=e.ref(!1),v=()=>{d.value=!0,g.value=!1},p=()=>{d.value=!1},f=e.reactive({username:e.computed((()=>n.value)),password:e.computed((()=>u.value)),remember:!0}),h=e.ref(!1),g=e.ref(!1),w=async()=>{if(k(),!g.value){h.value=!0;try{await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/login`,method:"POST",data:{username:e,password:t,login_type:"phone"},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.access_token;if(t)uni.setStorageSync("token",t),a(t);else{const t=e.data.error||"检查用户名和密码";n(t)}}else n(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(n.value,u.value);y(),uni.reLaunch({url:"/pages/Chat/Chat"})}catch(e){t("log","at pages/Login/Login.vue:124","登录失败",e),uni.showToast({title:e||"失败",icon:"error"})}finally{h.value=!1}}},k=()=>{n.value&&u.value||(g.value=!0)},y=()=>{if(f.remember){const e={username:f.username,password:f.password,remember:!0};uni.setStorageSync("login_info",e),uni.setStorageSync("chatType",0)}else uni.removeStorageSync("login_info")};return e.onMounted((()=>{(()=>{try{const e=uni.getStorageSync("login_info");e&&(n.value=e.username||"",u.value=e.password||"",f.remember=e.remember??!0)}catch(e){t("error","at pages/Login/Login.vue:168","读取登录信息失败",e)}})()})),(t,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"login-container page-container"},[e.createElementVNode("view",{class:"login-card"},[e.createElementVNode("view",{class:"login-header"},[e.createElementVNode("view",{class:"login-header-logo"},[e.createElementVNode("view",{class:"icon-wrapper"},[e.createElementVNode("view",{class:"iconfont icon-brain-2-fill danao-style"})]),e.createElementVNode("text",null,"YXD")]),e.createElementVNode("view",{class:"sub-title"},"File Handling Chat")]),e.createElementVNode("view",{class:"form-wrapper"},[e.createElementVNode("view",{class:"form-item"},[e.createElementVNode("view",{class:"form-label"},[e.createElementVNode("text",null,"用户名")]),e.withDirectives(e.createElementVNode("input",{class:e.normalizeClass(["form-input",{focused:l.value,error:s.value}]),"onUpdate:modelValue":a[0]||(a[0]=e=>n.value=e),onFocus:c,onBlur:i,onInput:r,placeholder:"请输入用户名"},null,34),[[e.vModelText,n.value]])]),e.createElementVNode("view",{class:"form-item"},[e.createElementVNode("view",{class:"form-label"},[e.createElementVNode("text",null,"密码")]),e.withDirectives(e.createElementVNode("input",{type:"password",class:e.normalizeClass(["form-input",{focused:d.value,error:m.value}]),"onUpdate:modelValue":a[1]||(a[1]=e=>u.value=e),onFocus:v,onBlur:p,placeholder:"请输入密码"},null,34),[[e.vModelText,u.value]])]),g.value?(e.openBlock(),e.createElementBlock("text",{key:0,class:"error-info"},"用户名或密码不能为空")):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"form-option"},[e.createElementVNode("view",{class:"checkbox-wrapper",onClick:a[2]||(a[2]=e=>f.remember=!f.remember)},[e.createElementVNode("view",{class:e.normalizeClass(["checkbox",{checked:f.remember}])},[f.remember?(e.openBlock(),e.createElementBlock("text",{key:0},"✓")):e.createCommentVNode("",!0)],2),e.createElementVNode("text",{class:"checkbox-text"},"记住密码")]),e.createElementVNode("text",{class:"forget-pwd"},"忘记密码?")]),e.createElementVNode("button",{class:"login-btn",disabled:h.value,loading:h.value,onClick:w},e.toDisplayString(h.value?"Loading...":"登录"),9,["disabled","loading"])])])])],64))}},[["__scopeId","data-v-d4b9d5ac"]]),g=[{font_class:"arrow-down",unicode:""},{font_class:"arrow-left",unicode:""},{font_class:"arrow-right",unicode:""},{font_class:"arrow-up",unicode:""},{font_class:"auth",unicode:""},{font_class:"auth-filled",unicode:""},{font_class:"back",unicode:""},{font_class:"bars",unicode:""},{font_class:"calendar",unicode:""},{font_class:"calendar-filled",unicode:""},{font_class:"camera",unicode:""},{font_class:"camera-filled",unicode:""},{font_class:"cart",unicode:""},{font_class:"cart-filled",unicode:""},{font_class:"chat",unicode:""},{font_class:"chat-filled",unicode:""},{font_class:"chatboxes",unicode:""},{font_class:"chatboxes-filled",unicode:""},{font_class:"chatbubble",unicode:""},{font_class:"chatbubble-filled",unicode:""},{font_class:"checkbox",unicode:""},{font_class:"checkbox-filled",unicode:""},{font_class:"checkmarkempty",unicode:""},{font_class:"circle",unicode:""},{font_class:"circle-filled",unicode:""},{font_class:"clear",unicode:""},{font_class:"close",unicode:""},{font_class:"closeempty",unicode:""},{font_class:"cloud-download",unicode:""},{font_class:"cloud-download-filled",unicode:""},{font_class:"cloud-upload",unicode:""},{font_class:"cloud-upload-filled",unicode:""},{font_class:"color",unicode:""},{font_class:"color-filled",unicode:""},{font_class:"compose",unicode:""},{font_class:"contact",unicode:""},{font_class:"contact-filled",unicode:""},{font_class:"down",unicode:""},{font_class:"bottom",unicode:""},{font_class:"download",unicode:""},{font_class:"download-filled",unicode:""},{font_class:"email",unicode:""},{font_class:"email-filled",unicode:""},{font_class:"eye",unicode:""},{font_class:"eye-filled",unicode:""},{font_class:"eye-slash",unicode:""},{font_class:"eye-slash-filled",unicode:""},{font_class:"fire",unicode:""},{font_class:"fire-filled",unicode:""},{font_class:"flag",unicode:""},{font_class:"flag-filled",unicode:""},{font_class:"folder-add",unicode:""},{font_class:"folder-add-filled",unicode:""},{font_class:"font",unicode:""},{font_class:"forward",unicode:""},{font_class:"gear",unicode:""},{font_class:"gear-filled",unicode:""},{font_class:"gift",unicode:""},{font_class:"gift-filled",unicode:""},{font_class:"hand-down",unicode:""},{font_class:"hand-down-filled",unicode:""},{font_class:"hand-up",unicode:""},{font_class:"hand-up-filled",unicode:""},{font_class:"headphones",unicode:""},{font_class:"heart",unicode:""},{font_class:"heart-filled",unicode:""},{font_class:"help",unicode:""},{font_class:"help-filled",unicode:""},{font_class:"home",unicode:""},{font_class:"home-filled",unicode:""},{font_class:"image",unicode:""},{font_class:"image-filled",unicode:""},{font_class:"images",unicode:""},{font_class:"images-filled",unicode:""},{font_class:"info",unicode:""},{font_class:"info-filled",unicode:""},{font_class:"left",unicode:""},{font_class:"link",unicode:""},{font_class:"list",unicode:""},{font_class:"location",unicode:""},{font_class:"location-filled",unicode:""},{font_class:"locked",unicode:""},{font_class:"locked-filled",unicode:""},{font_class:"loop",unicode:""},{font_class:"mail-open",unicode:""},{font_class:"mail-open-filled",unicode:""},{font_class:"map",unicode:""},{font_class:"map-filled",unicode:""},{font_class:"map-pin",unicode:""},{font_class:"map-pin-ellipse",unicode:""},{font_class:"medal",unicode:""},{font_class:"medal-filled",unicode:""},{font_class:"mic",unicode:""},{font_class:"mic-filled",unicode:""},{font_class:"micoff",unicode:""},{font_class:"micoff-filled",unicode:""},{font_class:"minus",unicode:""},{font_class:"minus-filled",unicode:""},{font_class:"more",unicode:""},{font_class:"more-filled",unicode:""},{font_class:"navigate",unicode:""},{font_class:"navigate-filled",unicode:""},{font_class:"notification",unicode:""},{font_class:"notification-filled",unicode:""},{font_class:"paperclip",unicode:""},{font_class:"paperplane",unicode:""},{font_class:"paperplane-filled",unicode:""},{font_class:"person",unicode:""},{font_class:"person-filled",unicode:""},{font_class:"personadd",unicode:""},{font_class:"personadd-filled",unicode:""},{font_class:"personadd-filled-copy",unicode:""},{font_class:"phone",unicode:""},{font_class:"phone-filled",unicode:""},{font_class:"plus",unicode:""},{font_class:"plus-filled",unicode:""},{font_class:"plusempty",unicode:""},{font_class:"pulldown",unicode:""},{font_class:"pyq",unicode:""},{font_class:"qq",unicode:""},{font_class:"redo",unicode:""},{font_class:"redo-filled",unicode:""},{font_class:"refresh",unicode:""},{font_class:"refresh-filled",unicode:""},{font_class:"refreshempty",unicode:""},{font_class:"reload",unicode:""},{font_class:"right",unicode:""},{font_class:"scan",unicode:""},{font_class:"search",unicode:""},{font_class:"settings",unicode:""},{font_class:"settings-filled",unicode:""},{font_class:"shop",unicode:""},{font_class:"shop-filled",unicode:""},{font_class:"smallcircle",unicode:""},{font_class:"smallcircle-filled",unicode:""},{font_class:"sound",unicode:""},{font_class:"sound-filled",unicode:""},{font_class:"spinner-cycle",unicode:""},{font_class:"staff",unicode:""},{font_class:"staff-filled",unicode:""},{font_class:"star",unicode:""},{font_class:"star-filled",unicode:""},{font_class:"starhalf",unicode:""},{font_class:"trash",unicode:""},{font_class:"trash-filled",unicode:""},{font_class:"tune",unicode:""},{font_class:"tune-filled",unicode:""},{font_class:"undo",unicode:""},{font_class:"undo-filled",unicode:""},{font_class:"up",unicode:""},{font_class:"top",unicode:""},{font_class:"upload",unicode:""},{font_class:"upload-filled",unicode:""},{font_class:"videocam",unicode:""},{font_class:"videocam-filled",unicode:""},{font_class:"vip",unicode:""},{font_class:"vip-filled",unicode:""},{font_class:"wallet",unicode:""},{font_class:"wallet-filled",unicode:""},{font_class:"weibo",unicode:""},{font_class:"weixin",unicode:""}];const w=f({name:"UniIcons",emits:["click"],props:{type:{type:String,default:""},color:{type:String,default:"#333333"},size:{type:[Number,String],default:16},customPrefix:{type:String,default:""},fontFamily:{type:String,default:""}},data:()=>({icons:g}),computed:{unicode(){let e=this.icons.find((e=>e.font_class===this.type));return e?e.unicode:""},iconSize(){return"number"==typeof(e=this.size)||/^[0-9]*$/g.test(e)?e+"px":e;var e},styleObj(){return""!==this.fontFamily?`color: ${this.color}; font-size: ${this.iconSize}; font-family: ${this.fontFamily};`:`color: ${this.color}; font-size: ${this.iconSize};`}},methods:{_onClick(e){this.$emit("click",e)}}},[["render",function(t,a,n,o,l,s){return e.openBlock(),e.createElementBlock("text",{style:e.normalizeStyle(s.styleObj),class:e.normalizeClass(["uni-icons",["uniui-"+n.type,n.customPrefix,n.customPrefix?n.type:""]]),onClick:a[0]||(a[0]=(...e)=>s._onClick&&s._onClick(...e))},[e.renderSlot(t.$slots,"default",{},void 0,!0)],6)}],["__scopeId","data-v-b25a9929"]]),k=()=>uni.getStorageSync("token"),y=()=>{const e=uni.getStorageSync("currentSessionId");return isNaN(Number(e))?e.replace(/-/g,""):e},E=()=>uni.getStorageSync("taskCallId"),N=()=>(t("log","at utils/user-info.js:50","用户Id(UserId)",uni.getStorageSync("userId")),uni.getStorageSync("userId")),C=f(Object.assign({name:"ChatSidebar"},{__name:"ChatSidebar",props:{chatList:{type:Array,required:!0},showNewChatModal:{type:Boolean,default:!1},currentSessionId:{type:[String,Number],required:!0},chatType:{type:Number,required:!0}},emits:["update:showNewChatModal","update:currentSessionId","refresh-conversations","update:chatType"],setup(n,{emit:o}){const c=n,i=o,r=e.toRef(c,"chatList");e.toRef(c,"showNewChatModal");const u=e.toRef(c,"chatType"),d=()=>{uni.navigateTo({url:"/pages/UserProfileModal/UserProfileModal"})},m=e.ref(!1),v=e.ref([]),p=()=>{0!==v.value.length&&uni.showModal({title:"确认删除",content:`确定要删除全部 ${v.value.length} 个对话吗?此操作不可恢复。`,confirmText:"确认删除",confirmColor:"#ff0000",success:async e=>{if(e.confirm)try{const e=k();await l(e,v.value),uni.showToast({title:"删除成功",icon:"success"}),v.value=[],m.value=!1,i("refresh-conversations")}catch(a){t("error","at components/ChatSidebar.vue:209","删除会话失败:",a),uni.showToast({title:"删除失败,请重试",icon:"none"})}}})},f=()=>{r.value.length?uni.showModal({title:"确认删除",content:`确定要删除全部 ${r.value.length} 个对话吗?此操作不可恢复。`,confirmText:"删除全部",confirmColor:"#ff0000",success:async e=>{if(e.confirm)try{const e=k(),t=r.value.map((e=>e._id));await l(e,t),uni.showToast({title:"已删除全部对话",icon:"success"}),i("refresh-conversations")}catch(a){t("error","at components/ChatSidebar.vue:241","清空全部对话失败:",a),uni.showToast({title:"删除失败,请重试",icon:"none"})}}}):uni.showToast({title:"没有可删除的会话",icon:"none"})},h=e.computed((()=>r.value.length>0&&v.value.length===r.value.length)),g=e.toRef(c,"currentSessionId"),y=(e,a="")=>{t("log","at components/ChatSidebar.vue:259","选择的id是:",e),a&&uni.setStorageSync("receiverId",a),uni.setStorageSync("currentSessionId",e),i("update:currentSessionId",e)},E=()=>{t("log","at components/ChatSidebar.vue:270","点击了新建会话"),i("update:showNewChatModal",!0)},N=()=>{uni.navigateTo({url:"/pages/ContactPages/ContactPages"})},C=e.ref(""),b=e.ref(!1),V=()=>{m.value=!m.value,m.value||(v.value=[])},_=e=>{const t=v.value.indexOf(e);-1===t?v.value.push(e):v.value.splice(t,1)},B=()=>{h.value?v.value=[]:v.value=r.value.map((e=>e._id))},S=e.ref(""),x=e.ref(""),T=e.ref("");return e.onMounted((async()=>{S.value=k();const e=await s(S.value);x.value=e.avatar||"",T.value=e.username||"",t("log","at components/ChatSidebar.vue:320","菜单收到的会话列表:",r.value)})),(t,n)=>{const o=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock("view",{class:"chat-sidebar-container"},[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"sidebar-header"},[e.createElementVNode("view",{class:"user-profile-card",onClick:d},[e.createElementVNode("view",{class:"left"},[x.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"avatar-preview"},[e.createElementVNode("image",{src:x.value,mode:"aspectFill"},null,8,["src"])])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"avatar-placeholder"},[e.createVNode(o,{type:"contact-filled",size:"50",color:"#007aff"})]))]),e.createElementVNode("view",{class:"center"},[e.createElementVNode("text",null,"欢迎回来"),e.createElementVNode("text",null,e.toDisplayString(T.value),1)]),e.createElementVNode("view",{class:"right"},[e.createElementVNode("view",{class:"status-dot"}),e.createElementVNode("view",{class:"status-text"},[e.createElementVNode("text",null,"在线")])])]),e.createElementVNode("view",{class:"new-chat-btn",onClick:N},[e.createElementVNode("text",null,"+ 聊天列表")])]),e.createElementVNode("view",{class:"chat-history"},[e.createElementVNode("view",{class:"history-header"},[e.createElementVNode("view",{class:"history-title-section"},[e.createElementVNode("text",null,"历史会话"),e.createElementVNode("text",null,e.toDisplayString(r.value.length)+"个对话",1)]),e.createElementVNode("view",{class:"history-management"},[m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-management-btn iconfont icon-jia icon-jia-style",onClick:E})),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:1,class:"history-management-btn iconfont icon-duoxuan icon-duoxuan-style",onClick:V})),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:2,class:"history-management-btn iconfont icon-saochu icon-saochu-style",onClick:f})),m.value&&v.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:3,class:"history-management-btn iconfont icon-shanchu icon-shanchu-style",onClick:p})):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("view",{key:4,class:e.normalizeClass(["history-management-btn iconfont icon-total_selection icon-total_selection-style",{active:h.value}]),onClick:B},null,2)):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("view",{key:5,class:"history-management-btn iconfont icon-quxiao icon-quxiao-style",onClick:V})):e.createCommentVNode("",!0)])]),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-search-wrap"},[e.createElementVNode("view",{class:e.normalizeClass(["history-search-inner",{"has-value":C.value||b.value}])},[e.createVNode(o,{type:"search",class:e.normalizeClass([C.value||b.value?"chat-search-icon":"search-icon"])},null,8,["class"]),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[0]||(n[0]=e=>C.value=e),onFocus:n[1]||(n[1]=e=>b.value=!0),onBlur:n[2]||(n[2]=e=>b.value=!1),type:"text",placeholder:"搜索会话..."},null,544),[[e.vModelText,C.value]])],2)])),e.createElementVNode("view",{class:"chat-history-list"},[0===u.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(r.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t._id,"data-chat-id":t._id,class:e.normalizeClass(["chat-history-card",{"is-select-chat":g.value===t._id||v.value.includes(t._id)}]),onClick:e=>m.value?_(t._id):y(t._id)},[m.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[v.value.includes(t._id)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[e.createVNode(o,{type:"chat-filled",size:"26",color:"#007aff"})]),t.agent_id?(e.openBlock(),e.createElementBlock("view",{key:1},e.toDisplayString(t.agent_data.title),1)):(e.openBlock(),e.createElementBlock("view",{key:2},e.toDisplayString(t.title),1))],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0),1===u.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t.sessionId,"data-chat-id":t.sessionId,class:e.normalizeClass(["chat-history-card",{"is-select-chat":g.value===t.sessionId||v.value.includes(t.sessionId)}]),onClick:e=>m.value?_(t.sessionId):y(t.sessionId,t.receiver)},[m.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[v.value.includes(t.sessionId)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):e.createCommentVNode("",!0)]),e.createElementVNode("view",null,e.toDisplayString(t.friendNickName),1)],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0),2===u.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(r.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t.id,"data-chat-id":t.id,class:e.normalizeClass(["chat-history-card",{"is-select-chat":g.value===t.id||v.value.includes(t.id)}]),onClick:e=>m.value?_(t.id):y(t.id)},[m.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"history-chat-checkbox"},[v.value.includes(t.id)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",size:"20",color:"#007aff"})):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"history-chat-avatar"},[e.createElementVNode("view",{class:"iconfont icon-qunliao",style:{"font-size":"80rpx",color:"#fff"}})]),e.createElementVNode("view",null,e.toDisplayString(t.name),1)],10,["data-chat-id","onClick"])))),128)):e.createCommentVNode("",!0)])])])}}}),[["__scopeId","data-v-766a2af1"]]);var b={"":["",""],_:["",""],"*":["",""],"~":["",""],"\n":["
    "]," ":["
    "],"-":["
    "]};function V(e){return e.replace(RegExp("^"+(e.match(/^(\t| )+/)||"")[0],"gm"),"")}function _(e){return(e+"").replace(/"/g,""").replace(//g,">")}function B(e,t){var a,n,o,l,s,c=/((?:^|\n+)(?:\n---+|\* \*(?: \*)+)\n)|(?:^``` *(\w*)\n([\s\S]*?)\n```$)|((?:(?:^|\n+)(?:\t| {2,}).+)+\n*)|((?:(?:^|\n)([>*+-]|\d+\.)\s+.*)+)|(?:!\[([^\]]*?)\]\(([^)]+?)\))|(\[)|(\](?:\(([^)]+?)\))?)|(?:(?:^|\n+)([^\s].*)\n(-{3,}|={3,})(?:\n+|$))|(?:(?:^|\n+)(#{1,6})\s*(.+)(?:\n+|$))|(?:`([^`].*?)`)|( \n\n*|\n{2,}|__|\*\*|[_*]|~~)/gm,i=[],r="",u=t||{},d=0;function m(e){var t=b[e[1]||""],a=i[i.length-1]==e;return t?t[1]?(a?i.pop():i.push(e),t[0|a]):t[0]:e}function v(){for(var e="";i.length;)e+=m(i[i.length-1]);return e}for(e=e.replace(/^\[(.+?)\]:\s*(.+)$/gm,(function(e,t,a){return u[t.toLowerCase()]=a,""})).replace(/^\n+|\n+$/g,"");o=c.exec(e);)n=e.substring(d,o.index),d=c.lastIndex,a=o[0],n.match(/[^\\](\\\\)*\\$/)||((s=o[3]||o[4])?a='
    "+V(_(s).replace(/^\n+|\n+$/g,""))+"
    ":(s=o[6])?(s.match(/\./)&&(o[5]=o[5].replace(/^\d+/gm,"")),l=B(V(o[5].replace(/^\s*[>*+.-]/gm,""))),">"==s?s="blockquote":(s=s.match(/\./)?"ol":"ul",l=l.replace(/^(.*)(\n|$)/gm,"
  • $1
  • ")),a="<"+s+">"+l+""):o[8]?a=''+_(o[7])+'':o[10]?(r=r.replace("
    ",''),a=v()+""):o[9]?a="":o[12]||o[14]?a="<"+(s="h"+(o[14]?o[14].length:o[13]>"="?1:2))+">"+B(o[12]||o[15],u)+"":o[16]?a=""+_(o[16])+"":(o[17]||o[1])&&(a=m(o[17]||"--"))),r+=n,r+=a;return(r+e.substring(d)+v()).replace(/^\n+|\n+$/g,"")} /*! * pinia v2.1.7 * (c) 2023 Eduardo San Martin Morote * @license MIT */ -let k;const y=e=>k=e,E=Symbol();function N(e){return e&&"object"==typeof e&&"[object Object]"===Object.prototype.toString.call(e)&&"function"!=typeof e.toJSON}var V,b;(b=V||(V={})).direct="direct",b.patchObject="patch object",b.patchFunction="patch function";const C=()=>{};function _(t,a,n,o=C){t.push(a);const l=()=>{const e=t.indexOf(a);e>-1&&(t.splice(e,1),o())};return!n&&e.getCurrentScope()&&e.onScopeDispose(l),l}function x(e,...t){e.slice().forEach((e=>{e(...t)}))}const S=e=>e();function B(t,a){t instanceof Map&&a instanceof Map&&a.forEach(((e,a)=>t.set(a,e))),t instanceof Set&&a instanceof Set&&a.forEach(t.add,t);for(const n in a){if(!a.hasOwnProperty(n))continue;const o=a[n],l=t[n];N(l)&&N(o)&&t.hasOwnProperty(n)&&!e.isRef(o)&&!e.isReactive(o)?t[n]=B(l,o):t[n]=o}return t}const T=Symbol();const{assign:I}=Object;function M(t,a,n={},o,l,s){let c;const i=I({actions:{}},n),r={deep:!0};let d,u,m,v=[],p=[];const f=o.state.value[t];let g;function h(a){let n;d=u=!1,"function"==typeof a?(a(o.state.value[t]),n={type:V.patchFunction,storeId:t,events:m}):(B(o.state.value[t],a),n={type:V.patchObject,payload:a,storeId:t,events:m});const l=g=Symbol();e.nextTick().then((()=>{g===l&&(d=!0)})),u=!0,x(v,n,o.state.value[t])}s||f||(o.state.value[t]={}),e.ref({});const w=s?function(){const{state:e}=n,t=e?e():{};this.$patch((e=>{I(e,t)}))}:C;function k(e,a){return function(){y(o);const n=Array.from(arguments),l=[],s=[];function c(e){l.push(e)}function i(e){s.push(e)}let r;x(p,{args:n,name:e,store:b,after:c,onError:i});try{r=a.apply(this&&this.$id===t?this:b,n)}catch(d){throw x(s,d),d}return r instanceof Promise?r.then((e=>(x(l,e),e))).catch((e=>(x(s,e),Promise.reject(e)))):(x(l,r),r)}}const E={_p:o,$id:t,$onAction:_.bind(null,p),$patch:h,$reset:w,$subscribe(a,n={}){const l=_(v,a,n.detached,(()=>s())),s=c.run((()=>e.watch((()=>o.state.value[t]),(e=>{("sync"===n.flush?u:d)&&a({storeId:t,type:V.direct,events:m},e)}),I({},r,n))));return l},$dispose:function(){c.stop(),v=[],p=[],o._s.delete(t)}},b=e.reactive(E);o._s.set(t,b);const M=(o._a&&o._a.runWithContext||S)((()=>o._e.run((()=>(c=e.effectScope()).run(a)))));for(const y in M){const a=M[y];if(e.isRef(a)&&(z=a,!e.isRef(z)||!z.effect)||e.isReactive(a))s||(!f||N(P=a)&&P.hasOwnProperty(T)||(e.isRef(a)?a.value=f[y]:B(a,f[y])),o.state.value[t][y]=a);else if("function"==typeof a){const e=k(y,a);M[y]=e,i.actions[y]=a}}var P,z;return I(b,M),I(e.toRaw(b),M),Object.defineProperty(b,"$state",{get:()=>o.state.value[t],set:e=>{h((t=>{I(t,e)}))}}),o._p.forEach((e=>{I(b,c.run((()=>e({store:b,app:o._a,pinia:o,options:i}))))})),f&&s&&n.hydrate&&n.hydrate(b.$state,f),d=!0,u=!0,b}function P(t,a,n){let o,l;const s="function"==typeof a;function c(t,n){const c=e.hasInjectionContext();(t=t||(c?e.inject(E,null):null))&&y(t),(t=k)._s.has(o)||(s?M(o,a,l,t):function(t,a,n,o){const{state:l,actions:s,getters:c}=a,i=n.state.value[t];let r;r=M(t,(function(){i||(n.state.value[t]=l?l():{});const a=e.toRefs(n.state.value[t]);return I(a,s,Object.keys(c||{}).reduce(((a,o)=>(a[o]=e.markRaw(e.computed((()=>{y(n);const e=n._s.get(t);return c[o].call(e,e)}))),a)),{}))}),a,n,0,!0)}(o,l,t));return t._s.get(o)}return"string"==typeof t?(o=t,l=s?n:a):(l=t,o=t.id),c.$id=o,c}const z=new class{constructor(){this.ws=null,this.url="wss://cloud.yuxindazhineng.com/chat",this.options={token:"",conversationId:"",onMessage:null,onError:null,onReconnect:null,onOpen:null,onClose:null},this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.reconnectDelay=3e3,this.reconnectTimer=null,this.heartbeatTimer=null,this.isManualClose=!1}connect(e={}){this.options={...this.options,...e},this.isManualClose=!1,this.ws&&this.close();try{this.ws=uni.connectSocket({url:this.url,success:()=>{t("log","at utils/socket.js:42","WebSocket 连接请求已发送")},fail:e=>{t("error","at utils/socket.js:45","WebSocket 连接失败:",e),this.handleError(e)}}),this.initEventHandlers()}catch(a){this.handleError(a)}}initEventHandlers(){this.ws&&(this.ws.onOpen((e=>{var a,n,o,l;t("log","at utils/socket.js:72","WebSocket 已连接"),this.reconnectAttempts>0&&(null==(n=(a=this.options).onReconnect)||n.call(a)),null==(l=(o=this.options).onOpen)||l.call(o,e),this.reconnectAttempts=0})),this.ws.onMessage((e=>{try{const a=JSON.parse(e.data);t("log","at utils/socket.js:85","收到了返回消息:",a),this.handleMessage(a)}catch(a){t("error","at utils/socket.js:89","消息解析失败:",a),uni.setStorageSync("currentSessionId",e.data.task_call_id)}})),this.ws.onError((e=>{t("error","at utils/socket.js:94","WebSocket 错误:",e),this.handleError(e)})),this.ws.onClose((e=>{var a,n;t("log","at utils/socket.js:98","WebSocket 已关闭:",e.code,e.reason),null==(n=(a=this.options).onClose)||n.call(a,e),this.stopHeartbeat(),!this.isManualClose&&this.reconnectAttempts{if(!this.isConnected())return void n(new Error("WebSocket 未连接"));const o=JSON.stringify(e);t("log","at utils/socket.js:187","发送的消息是:",o),this.ws.send({data:o,success:()=>a(),fail:e=>{t("error","at utils/socket.js:195","发送消息失败:",e),n(e)}})}))}reconnect(){this.reconnectTimer||(this.reconnectAttempts++,t("log","at utils/socket.js:221",`尝试重连 (${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.reconnectTimer=setTimeout((()=>{this.reconnectTimer=null,this.isManualClose||this.connect(this.options)}),this.reconnectDelay*this.reconnectAttempts))}startHeartbeat(){this.stopHeartbeat(),this.heartbeatTimer=setInterval((()=>{this.isConnected()?this.send({ws_event:"ping"}).catch((()=>{t("log","at utils/socket.js:243","心跳发送失败,准备重连"),this.reconnectTimer||this.isManualClose||this.reconnect()})):!this.isManualClose&&this.reconnectAttemptst("log","at utils/socket.js:329","连接已关闭"),fail:e=>t("error","at utils/socket.js:330","关闭失败:",e)})}catch(e){t("error","at utils/socket.js:338","关闭连接出错:",e)}this.ws=null}this.reconnectAttempts=0}updateOptions(e){this.options={...this.options,...e}}},j=P("socket",(()=>{const a=e.ref("disconnected"),n=e.ref([]),o=e.ref(""),l=e.ref({token:"",conversationId:""}),s=e.ref(""),c=e.ref([]),i=e.ref(20),r=e.computed((()=>"connected"===a.value)),d=e.computed((()=>"connecting"===a.value)),u=e.computed((()=>"disconnected"===a.value)),m=e.computed((()=>"error"===a.value)),v=e.computed((()=>n.value[n.value.length-1]));function p(e,a){const n=new Date,o=`${n.getHours().toString().padStart(2,"0")}:${n.getMinutes().toString().padStart(2,"0")}:${n.getSeconds().toString().padStart(2,"0")}`;c.value.push({type:e,connect:a,time:o}),c.value.length>i.value&&(c.value=c.value.slice(-i.value)),t("log","at stores/socket.js:49",`[${e.toUpperCase()}] ${a}`)}function f(){z.close(),a.value="disconnected",p("warn","已主动断开连接")}function g(){a.value="connected",p("success","连接成功!")}function h(){"disconnected"!==a.value&&(a.value="disconnected",p("warn","连接已断开"))}function w(e){p("error",`Socket错误: ${JSON.stringify(e)}`),a.value="error"}function k(e){a.value="connecting",p("warn",`重连中... (${e}/5)`)}function y(e){p("receive",`收到: ${JSON.stringify(e)}`);const{ws_event:a,queue:n,data:c}=e||{};switch((null==c?void 0:c.task_call_id)&&(s.value=c.task_call_id,uni.setStorageSync("taskCallId",c.task_call_id)),a){case"connect":p("success","连接成功"),function(e){const{ws_event:t,queue:a,data:n}=e||{};(null==n?void 0:n.task_call_id)&&z.send({ws_event:"message",data:{task_call_id:s.value,token:l.value.token,conversation_id:l.value.conversationId}})}(e);break;case"disconnect":p("warn","收到服务端断开指令"),f();break;case"message":!function(e){const{ws_event:a,queue:n,data:l}=e,c=(null==l?void 0:l.content)||(null==l?void 0:l.chunk)||"";if("list_tools"===(null==l?void 0:l.cmd)||"catalog"===(null==l?void 0:l.cmd))return z.send({ws_event:"message",data:{task_call_id:s.value,result:{tools:[]}}}),void p("info",`调用工具: ${null==l?void 0:l.module}`);"message"===a&&"render"===n&&(o.value+=c,l.task_call_id&&z.send({ws_event:"message",data:{task_call_id:s.value}}).catch((e=>t("error","at stores/socket.js:230","发送确认失败:",e))))}(e);break;default:p("info",`未知事件类型: ${a}`)}}return{connectionStatus:a,messageString:o,logs:c,config:l,isConnected:r,isConnecting:d,isDisconnected:u,isError:m,lastMessage:v,connect:function(e={}){n.value=[],o.value="",l.value={...l.value,...e},p("info",`准备连接WebSocket。Token:${l.value.token||"未设置"}。ConversationId: ${l.value.conversationId||"未设置"}`),l.value.token&&l.value.conversationId?(a.value="connecting",z.connect({token:l.value.token,conversationId:l.value.conversationId,onMessage:y,onError:w,onOpen:g,onClose:h,onReconnect:k}),setTimeout((()=>{"connecting"===a.value&&(a.value="error",p("error","连接超时(10s)"))}),1e4)):p("error","Token和ConversationId都不能为空")},disconnect:f,send:async function(e){if(!r.value)throw p("error","发送失败: 连接未建立"),new Error("连接未建立");try{return await z.send(e),p("send","string"==typeof e?e:JSON.stringify(e)),!0}catch(t){throw p("error",`发送失败: ${t.message||t}`),t}},addLog:p,clearLogs:function(){c.value=[]},getStatusText:function(){return{connecting:"连接中",connected:"已连接",disconnected:"未连接",error:"连接错误"}[a.value]||"未知状态"}}})),$="http://chat.yuxindazhineng.com",D=async e=>new Promise(((a,n)=>{uni.request({url:`${$}/api/chatList/getChatFriend`,method:"POST",header:{"Content-Type":"application/json"},data:{size:500,current:1,sendId:e},success:e=>{var o;if(200===e.statusCode){const l=e.data;if(t("log","at utils/friend-api.js:20","获取到的好友列表消息",l),0===(null==l?void 0:l.code)||"成功"===(null==l?void 0:l.msg)){const e=null==(o=l.data)?void 0:o.records;if(e.length>0){const t=e[0].receiver;t&&uni.setStorageSync("receiverId",t)}a(e)}else{const t=e.data.error||"获取好友列表出错啦";n(t)}}else n(`获取好友列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),L=async e=>new Promise(((t,a)=>{uni.request({url:`${$}/api/group/getGroup`,method:"POST",header:{"Content-Type":"application/json"},data:{size:500,current:1,contactId:e},success:e=>{var n;if(200===e.statusCode){const o=e.data;if(0===(null==o?void 0:o.code)||"成功"===(null==o?void 0:o.msg)){const e=null==(n=o.data)?void 0:n.records;t(e)}else{const t=e.data.error||"获取群聊列表出错啦";a(t)}}else a(`获取群聊列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})}));const F=new class{constructor(){this.ws=null,this.url="ws://wss.yuxindazhineng.com/ws",this.options={token:"",UserId:"",onMessage:null,onError:null,onReconnect:null,onOpen:null,onClose:null},this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.reconnectDelay=3e3,this.reconnectTimer=null,this.heartbeatTimer=null,this.isManualClose=!1}connect(e={}){this.options={...this.options,...e},this.isManualClose=!1,this.ws&&this.close();try{this.ws=uni.connectSocket({url:this.url,success:()=>{t("log","at utils/friend-socket.js:44","WebSocket 连接请求已发送")},fail:e=>{t("error","at utils/friend-socket.js:47","WebSocket 连接失败:",e),this.handleError(e)}}),this.initEventHandlers()}catch(a){this.handleError(a)}}initEventHandlers(){this.ws&&(this.ws.onOpen((e=>{var a,n,o,l;t("log","at utils/friend-socket.js:74","WebSocket 已连接"),this.reconnectAttempts>0&&(null==(n=(a=this.options).onReconnect)||n.call(a)),null==(l=(o=this.options).onOpen)||l.call(o,e),this.reconnectAttempts=0})),this.ws.onMessage((e=>{try{const a=JSON.parse(e.data);t("log","at utils/friend-socket.js:87","收到了返回消息:",a),this.handleMessage(a)}catch(a){t("error","at utils/friend-socket.js:90","消息解析失败:",a),uni.setStorageSync("currentSessionId",e.data.task_call_id)}})),this.ws.onError((e=>{t("error","at utils/friend-socket.js:95","WebSocket 错误:",e),this.handleError(e)})),this.ws.onClose((e=>{var a,n;t("log","at utils/friend-socket.js:99","WebSocket 已关闭:",e.code,e.reason),null==(n=(a=this.options).onClose)||n.call(a,e),!this.isManualClose&&this.reconnectAttempts{if(!this.isConnected())return void n(new Error("WebSocket 未连接"));const o=JSON.stringify(e);t("log","at utils/friend-socket.js:170","发送的消息是:",o),this.ws.send({data:o,success:()=>a(),fail:e=>{t("error","at utils/friend-socket.js:178","发送消息失败:",e),n(e)}})}))}reconnect(){this.reconnectTimer||(this.reconnectAttempts++,t("log","at utils/friend-socket.js:204",`尝试重连 (${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.reconnectTimer=setTimeout((()=>{this.reconnectTimer=null,this.isManualClose||this.connect(this.options)}),this.reconnectDelay*this.reconnectAttempts))}startHeartbeat(){this.stopHeartbeat(),this.heartbeatTimer=setInterval((()=>{this.isConnected()?this.send({ws_event:"ping"}).catch((()=>{t("log","at utils/friend-socket.js:226","心跳发送失败,准备重连"),this.reconnectTimer||this.isManualClose||this.reconnect()})):!this.isManualClose&&this.reconnectAttemptst("log","at utils/friend-socket.js:312","连接已关闭"),fail:e=>t("error","at utils/friend-socket.js:313","关闭失败:",e)})}catch(e){t("error","at utils/friend-socket.js:321","关闭连接出错:",e)}this.ws=null}this.reconnectAttempts=0}updateOptions(e){this.options={...this.options,...e}}},A=P("friendSocket",(()=>{const a=e.ref("disconnected"),n=e.ref([]),o=e.ref(""),l=e.ref({token:"",UserId:""});e.ref("");const s=e.ref(null),c=e.ref(null),i=e.ref(!1),r=e.ref([]),d=e.ref(20),u=e.computed((()=>"connected"===a.value)),m=e.computed((()=>"connecting"===a.value)),v=e.computed((()=>"disconnected"===a.value)),p=e.computed((()=>"error"===a.value)),f=e.computed((()=>n.value[n.value.length-1]));function g(e,a){const n=new Date,o=`${n.getHours().toString().padStart(2,"0")}:${n.getMinutes().toString().padStart(2,"0")}:${n.getSeconds().toString().padStart(2,"0")}`;r.value.push({type:e,connect:a,time:o}),r.value.length>d.value&&(r.value=r.value.slice(-d.value)),t("log","at stores/friend-socket.js:57",`[${e.toUpperCase()}] ${a}`)}async function h(){const e={version:"1.1",body:{command:7,sender:(t("log","at utils/user-info.js:50","用户Id(UserId)",uni.getStorageSync("userId")),uni.getStorageSync("userId")),avatar:"",sessionId:"",message:"",callBackMessage:!1}};try{return await F.send(e),g("send","string"==typeof e?e:JSON.stringify(e)),!0}catch(a){throw g("error",`发送验证失败: ${a.message||a}`),a}}function w(){a.value="connected",g("success","连接成功!"),h()}function k(){"disconnected"!==a.value&&(a.value="disconnected",g("warn","连接已断开"))}function y(e){g("error",`Socket错误: ${JSON.stringify(e)}`),a.value="error"}function E(e){a.value="connecting",g("warn",`重连中... (${e}/5)`)}function N(e){g("receive",`收到: ${JSON.stringify(e)}`);const a=e.body||e,{callBackMessage:n,groupName:o,command:l,groupId:r}=a||{};switch(l){case 3:s.value=l,c.value=r;break;case 7:s.value=l;break;case 1:t("log","at stores/friend-socket.js:199","有好友消息"),i.value=!0;break;case 9:t("log","at stores/friend-socket.js:204","群消息发送成功/有新群消息"),i.value=!0;break;default:g("info","未知事件类型")}}return{connectionStatus:a,messageString:o,logs:r,config:l,command:s,groupId:c,MessageReceived:i,isConnected:u,isConnecting:m,isDisconnected:v,isError:p,lastMessage:f,connect:function(e={}){n.value=[],o.value="",l.value={...l.value,...e},g("info",`准备连接FriendsWebSocket。Token:${l.value.token||"未设置"}。UserId: ${l.value.UserId||"未设置"}`),l.value.token&&l.value.UserId?(a.value="connecting",F.connect({token:l.value.token,UserId:l.value.UserId,onMessage:N,onError:y,onOpen:w,onClose:k,onReconnect:E}),setTimeout((()=>{"connecting"===a.value&&(a.value="error",g("error","连接超时(10s)"))}),1e4)):g("error","Token和UserId都不能为空")},disconnect:function(){F.close(),a.value="disconnected",g("warn","已主动断开连接")},send:async function(e){if(!u.value)throw g("error","发送失败: 连接未建立"),new Error("连接未建立");try{return await F.send(e),g("send","string"==typeof e?e:JSON.stringify(e)),!0}catch(t){throw g("error",`发送失败: ${t.message||t}`),t}},addLog:g,clearLogs:function(){r.value=[]},getStatusText:function(){return{connecting:"连接中",connected:"已连接",disconnected:"未连接",error:"连接错误"}[a.value]||"未知状态"}}})),O=uni.requireUTSPlugin("uni_modules/lime-choose-file"),U=c({__name:"Chat",setup(c){const i=A(),r=()=>{i.isConnected||(q.value&&W.value?i.connect({token:q.value,UserId:W.value}):t("warn","at pages/Chat/Chat.vue:242","Token或UserId未准备好"))},v=j(),f=e.ref(0),g=e=>{if(!e)return"";e=h(e);try{return w(e)}catch(a){return t("error","at pages/Chat/Chat.vue:279","解析失败",a),e}},h=e=>{const t=/]*>([\s\S]*?)<\/script>/i.test(e),a=/<(form|input|select|textarea|button)\b[^>]*>/i.test(e);let n=e.replace(/]*>([\s\S]*?)<\/script>/gi,"");if(n=n.replace(/<\/?minimax:tool_call>/g,(e=>e.replace(//g,">"))).replace(/<\|[\w]+?\|>/g,(e=>e.replace(//g,">"))),t||a){return'

    表单仅预览,不可操作!!!

    '+n}return n},k=async()=>{try{const e="0123456789abcdef";let t="";for(let o=0;o<24;o++)t+=e[Math.floor(Math.random()*e.length)];const a=await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/create_workspace`,method:"POST",data:{access_token:e,name:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.workspace_id;if(t)a(t);else{const t=e.data.error||"创建工作区id出错啦";n(t)}}else n(`创建工作区id失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(q.value,t);if(!a)return void uni.showToast({title:"工作区创建失败",icon:"none"});const n=uni.getStorageSync("yxd_login_info");let l="";n&&(l=n.username||"");const s=await(async(e,t,a,n)=>new Promise(((l,s)=>{uni.request({url:`${o}/create_conversation`,method:"POST",data:{access_token:e,workspace_id:t,title:a,sender:n},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.conversation_id;if(t)l(t);else{const t=e.data.error||"创建新对话id出错啦";s(t)}}else s(`创建新对话失败:${e.statusCode}`)}})})))(q.value,a,"新会话",l);if(!s)return void uni.showToast({title:"新会话创建失败",icon:"none"});G()}catch(e){t("error","at pages/Chat/Chat.vue:373","新建普通会话失败:",e),uni.showToast({title:"创建会话失败,请重试",icon:"none"})}},y=e.ref(!1),E=()=>{y.value=!1},N=e.ref(!1),V=()=>{N.value=!N.value},b=()=>{uni.navigateTo({url:"/pages/WorkSpace/WorkSpace"})},C=()=>{uni.reLaunch({url:"/pages/Login/Login"})},_=e.ref([]),x=()=>{t("log","at pages/Chat/Chat.vue:407","点击了拍照上传"),uni.chooseImage({count:1,sourceType:["camera","album"],success:e=>{const t=e.tempFiles,a=e.tempFilePaths;t.forEach(((e,t)=>{_.value.push({path:a[t],name:e.name||`photo_${Date.now()}_${t}.jpg`,size:e.size,type:"image",tempFile:e})}))},fail:e=>{t("error","at pages/Chat/Chat.vue:425","选择图片失败",e)}})},S=e.ref([]),B=e.ref(!1),T=()=>{0===f.value&&P(),1===f.value&&I(),2===f.value&&M()},I=async()=>{i.isConnecting||await r();const e=uni.getStorageSync("receiverId"),t={version:"1.1",body:{command:1,sender:W.value,receiver:e,avatar:"",sessionId:R.value,message:F.value,callBackMessage:!1}};i.send(t);const a={sender:W.value,receiver:e,content:F.value,taskId:null,avatar:null,createTime:"",messageType:"null",contentJson:"null"};te.value=[...te.value,a],F.value="",setTimeout((()=>{se()}),1e3)},M=async()=>{i.isConnecting||await r();const e={version:"1.1",body:{command:9,sender:W.value,groupId:R.value,message:F.value,callBackMessage:!0,messageType:0}};i.send(e);const t={id:te.value.length+1,message:F.value,messageType:0,groupId:null,createTime:"",contentJson:"",sender:W.value};te.value=[...te.value,t],F.value="",setTimeout((()=>{ce()}),1e3)},P=async()=>{try{v.isConnected||v.connect({token:q.value,conversationId:R.value});await(async(e,t,a,n)=>new Promise(((l,s)=>{uni.request({url:`${o}/add_message_dict`,method:"POST",data:{access_token:e,conversation_id:a,message:{role:t,content:n}},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.message_id;if(t)l(t);else{const t=e.data.error||"用户发送消息出错啦";s(t)}}else s(`用户发送失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})))(q.value,"user",R.value,F.value)&&(F.value="",B.value=!0),await z()}catch(e){B.value=!1,uni.showToast({title:`用户发送消息失败${e}`,icon:"error"})}},z=()=>new Promise(((a,n)=>{const o=setTimeout((()=>{n(new Error("等待AI回复超时"))}),18e4),l=e.watch((()=>v.isDisconnected),(async e=>{if(t("log","at pages/Chat/Chat.vue:597","创建一个一次性监听器"),e&&v.messageString){t("log","at pages/Chat/Chat.vue:599","ai返回的消息:",v.messageString);try{t("log","at pages/Chat/Chat.vue:601","检测到socket断开,刷新消息列表"),await le(),l(),clearTimeout(o),a()}catch(s){t("error","at pages/Chat/Chat.vue:609","保存AI回复失败:",s),n(s)}finally{B.value=!1,l(),clearTimeout(o)}}}))})),F=e.ref(""),U=e.ref([]),R=e.ref(""),q=e.ref(""),W=e.ref(""),H=e.ref(""),J=e.ref(null),G=async()=>{try{q.value=u(),t("log","at pages/Chat/Chat.vue:650","token:",q.value),U.value=await(async e=>new Promise(((t,a)=>{uni.request({url:`${o}/get_user_conversations`,method:"POST",data:{access_token:e},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const a=e.data.conversations;t(a)}else a(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(q.value)||[],t("log","at pages/Chat/Chat.vue:652","UserConversations:",U.value),U.value.length>0?R.value=U.value[0]._id:R.value="",t("log","at pages/Chat/Chat.vue:660","保存会话id:",R.value),uni.setStorageSync("currentSessionId",R.value)}catch(e){uni.showToast({title:`获取会话列表失败${e}`,icon:"error"})}},K=e.ref([]),X=e=>{if(!e)return null;const t=K.value.find((t=>t.receiver===e));return(null==t?void 0:t.avatar)||null},Y=async e=>{if(!(null==e?void 0:e.length))return[];try{const t=e.map((e=>e.receiver)),a=await s(q.value,t),n=new Map(a.map((e=>[e.user_id,e]))||[]);return e.map((e=>{const t=n.get(e.receiver);return{...e,avatar:(null==t?void 0:t.avatar)||null}}))}catch(a){return t("error","at pages/Chat/Chat.vue:716","获取好友头像失败",a),e}},Q=e.ref([]),Z=e.ref([]),ee=e=>{if(!e)return null;const t=Z.value.find((t=>t.groupContactId===e));return(null==t?void 0:t.avatar)||null},te=e.ref([]),ae=e.ref("");e.ref(!1);const ne=e.ref(1),oe=e.computed((()=>te.value.slice(-100))),le=async()=>{try{te.value=await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/get_conversation_messages`,method:"POST",data:{access_token:e,conversation_id:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(t)uni.setStorageSync("workspace_id",t.workspace_id),a(t.messages);else{const t=e.data.error||"获取消息出错啦";n(t)}}else n(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(q.value,R.value)||[],de()}catch(e){uni.showToast({title:`获取ai会话内容失败${e}`,icon:"none"})}},se=async()=>{try{te.value=await(async(e,a=1)=>(t("log","at utils/friend-api.js:88","请求的好友消息id:",e),new Promise(((t,n)=>{uni.request({url:`${$}/api/message/list`,method:"POST",data:{sessionId:e,size:100,current:a,beginTime:"",endTime:""},header:{"Content-Type":"application/json"},success:e=>{var a;if(200===e.statusCode){const o=e.data;if(0===o.code){const e=((null==(a=null==o?void 0:o.data)?void 0:a.records)||[]).reverse();t(e)}else{const t=e.data.error||"获取好友消息出错啦";n(t)}}else n(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})}))))(R.value)||[],t("log","at pages/Chat/Chat.vue:807","好友消息:",JSON.stringify(te.value)),de()}catch(e){uni.showToast({title:`获取好友会话消息失败${e}`,icon:"none"})}},ce=async()=>{try{te.value=await(async(e,a=1)=>(t("log","at utils/friend-api.js:134","请求的群聊消息id:",e),new Promise(((n,o)=>{uni.request({url:`${$}/api/group/getGroupList`,method:"POST",data:{current:a,size:100,groupId:e,beginTime:"",endTime:""},header:{"Content-Type":"application/json"},success:e=>{var a;if(200===e.statusCode){const l=e.data;if(t("log","at utils/friend-api.js:152","获取到的群聊信息:",l),0===l.code){const e=((null==(a=null==l?void 0:l.data)?void 0:a.records)||[]).reverse();n(e)}else{const t=e.data.error||"获取群聊消息出错啦";o(t)}}else o(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";o(t)}})}))))(R.value)||[],t("log","at pages/Chat/Chat.vue:820","群聊消息:",te.value);const e=await(async e=>new Promise(((t,a)=>{uni.request({url:`${$}/api/group/getGroupMemberList`,method:"POST",header:{"Content-Type":"application/json"},data:{groupId:e,current:1,size:100},success:e=>{if(200===e.statusCode){const n=e.data;if(0===n.code){const e=n.data.records;t(e)}else{const t=e.data.error||"获取群成员出错啦";a(t)}}else a(`请求群成员失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(R.value);t("log","at pages/Chat/Chat.vue:823","获取到的群成员列表:",e),e&&e.length?(Z.value=await(async e=>{if(!(null==e?void 0:e.length))return[];try{const a=e.map((e=>e.groupContactId));t("log","at pages/Chat/Chat.vue:745","请求头像的ID列表:",a);const n=await s(q.value,a);t("log","at pages/Chat/Chat.vue:747","头像接口返回数据:",n);const o=new Map(n.map((e=>[e.user_id,e]))||[]);return t("log","at pages/Chat/Chat.vue:750","userMap的keys:",Array.from(o.keys())),e.map((e=>{const a=e.groupContactId,n=o.get(a);return t("log","at pages/Chat/Chat.vue:755",`查找 ${a} 的头像:`,n),{...e,avatar:(null==n?void 0:n.avatar)||null}}))}catch(a){return t("error","at pages/Chat/Chat.vue:762","获取群成员头像失败",a),e}})(e),t("log","at pages/Chat/Chat.vue:826","群成员列表(带头像):",Z.value)):Z.value=[],de()}catch(e){uni.showToast({title:`获取群聊会话失败${e}`,icon:"none"})}},ie=async()=>{if(t("log","at pages/Chat/Chat.vue:841","加载更多信息"),te.value.length>100*ne.value){ne.value+=1;const t=te.value.slice(-100*ne.value),a=t.length-oe.value.length;oe.value=t,await e.nextTick(),ae.value="msg-"+(a+1)}},re=e=>{},de=async()=>{await e.nextTick(),oe.value.length>0&&(ae.value="msg-"+(oe.value.length-1))};return e.watch((()=>i.MessageReceived),(e=>{if(t("log","at pages/Chat/Chat.vue:869","收到了好友消息"),e)switch(t("log","at pages/Chat/Chat.vue:871","ChatType:",f.value),f.value){case 0:le(),i.MessageReceived=!1;break;case 1:se(),i.MessageReceived=!1;break;case 2:ce(),i.MessageReceived=!1;break;default:t("log","at pages/Chat/Chat.vue:887","default 分支"),i.MessageReceived=!1}}),{immediate:!0}),e.watch(R,(e=>{if(e)switch(uni.setStorageSync("currentSessionId",R.value),f.value){case 0:default:le();break;case 1:se();break;case 2:ce()}}),{immediate:!0}),e.onMounted((()=>{})),n((async()=>{await(async()=>{try{q.value=u(),J.value=await l(q.value),W.value=J.value._id,H.value=J.value.avatar||"",t("log","at pages/Chat/Chat.vue:640","用户信息已加载:",W.value,H.value)}catch(e){t("error","at pages/Chat/Chat.vue:642","获取用户信息失败:",e)}})();const e=uni.getStorageSync("chatType");f.value=e;const a=m();a&&(R.value=a),0===e?(await G(),R.value&&le()):1===e?(await(async()=>{try{t("log","at pages/Chat/Chat.vue:675","开始获取好友列表");const e=await D(W.value);t("log","at pages/Chat/Chat.vue:678","friendList:",e),e&&e.length?K.value=await Y(e):(K.value=[],t("log","at pages/Chat/Chat.vue:683","好友列表为空"))}catch(e){t("error","at pages/Chat/Chat.vue:686","获取好友列表失败:",e),K.value=[]}finally{U.value=K.value}})(),se(),r()):2===e&&(await(async()=>{try{t("log","at pages/Chat/Chat.vue:726","开始获取群聊列表"),Q.value=await L(W.value)}catch(e){t("error","at pages/Chat/Chat.vue:731","获取群聊列表失败:",e),Q.value=[]}finally{U.value=Q.value}})(),await r(),await ce())})),(n,o)=>{const l=a(e.resolveDynamicComponent("uni-icons"),d);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),y.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"ncd-overlay",onClick:E},[e.createElementVNode("view",{class:"ncd-card",onClick:o[0]||(o[0]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"ncd-header"},[e.createElementVNode("view",{class:"ncd-title-eng"},[e.createElementVNode("text",null,"NEW")]),e.createElementVNode("text",{class:"ncd-title-zh"},"创建对话"),e.createVNode(l,{type:"closeempty",color:"#ff0000",size:"24",onClick:E})]),e.createElementVNode("text",null,"选择对话类型,开启全新会话体验"),e.createElementVNode("view",{class:"ncd-options"},[e.createElementVNode("view",{class:"ncd-option ncd-normal"},[e.createElementVNode("view",{class:"ncd-opt-icon"},[e.createVNode(l,{type:"chat",color:"#000000",size:"30"})]),e.createElementVNode("view",{class:"ncd-opt-title",onClick:k},[e.createElementVNode("view",{class:"ncd-opt-title-1"},"普通会话"),e.createElementVNode("view",{class:"ncd-opt-title-2"},"与AI自由对话,探索任何话题")]),e.createVNode(l,{type:"arrow-right",class:"arrow-right-style"})]),e.createElementVNode("view",{class:"ncd-option ncd-intelligence"},[e.createElementVNode("view",{class:"ncd-opt-icon"},[e.createVNode(l,{type:"star",color:"#ffffff",size:"30"})]),e.createElementVNode("view",{class:"ncd-opt-title"},[e.createElementVNode("view",{class:"ncd-opt-title-1"},"智能体会话"),e.createElementVNode("view",{class:"ncd-opt-title-2"},"选择专属智能体,获得精准专业服务")]),e.createVNode(l,{type:"arrow-right",class:"arrow-right-style"})])])])])):e.createCommentVNode("",!0),B.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"ncd-overlay",onClick:E},[e.createElementVNode("view",{class:"ncd-card ai-card",onClick:o[1]||(o[1]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"thinking-content"},[e.createElementVNode("view",{class:"loading-dots"},[e.createElementVNode("view",{class:"dot"}),e.createElementVNode("view",{class:"dot"}),e.createElementVNode("view",{class:"dot"})]),e.createElementVNode("text",{class:"thinking-text"},"AI 正在思考中...")])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"chat-page page-container"},[N.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"mask",onClick:V})):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["chat-sidebar",{"sidebar-show":N.value}])},[e.createVNode(p,{chatList:U.value,showNewChatModal:y.value,"onUpdate:showNewChatModal":o[2]||(o[2]=e=>y.value=e),currentSessionId:R.value,"onUpdate:currentSessionId":o[3]||(o[3]=e=>R.value=e),chatType:f.value,"onUpdate:chatType":o[4]||(o[4]=e=>f.value=e),onRefreshConversations:G},null,8,["chatList","showNewChatModal","currentSessionId","chatType"])],2),e.createElementVNode("view",{class:"chat-wrapper"},[e.createElementVNode("view",{class:"chat-hearder"},[e.createElementVNode("view",{class:"chat-btn-group"},[e.createElementVNode("view",{class:"head-btn",onClick:V},[e.createElementVNode("view",{class:"iconfont icon-caidan"})]),e.createElementVNode("view",{class:"head-btn",onClick:b},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"})]),e.createElementVNode("view",{class:"head-btn log-out",onClick:C},[e.createElementVNode("view",{class:"iconfont icon-tuichu"})])])]),e.createElementVNode("view",{class:"main-chat"},[e.createElementVNode("scroll-view",{class:"chat-messages",direction:"vertical","scroll-y":"","scroll-into-view":ae.value,onScrolltoupper:ie,"upper-threshold":0,"scroll-with-animation":!0,onScroll:re},[0===f.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(oe.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":"user"===t.role}]),key:a,id:"msg-"+a},["user"===t.role?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":"user"===t.role}])},["user"===t.role&&(null==(n=J.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:J.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"iconfont icon-yonghuziliao"}))],2)):e.createCommentVNode("",!0),t.content&&""!==String(t.content).trim()?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["chat-content",{"chat-content-user":"user"===t.role}])},[e.createElementVNode("view",{innerHTML:g(t.content)},null,8,["innerHTML"])],2)):e.createCommentVNode("",!0)],10,["id"])})),128)):e.createCommentVNode("",!0),1===f.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(oe.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":t.sender===W.value}]),key:a,id:"msg-"+a},[e.createElementVNode("view",{class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":t.sender===W.value}])},[t.sender===W.value&&(null==(n=J.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:J.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):X(t.sender)?(e.openBlock(),e.createElementBlock("image",{key:1,src:X(t.sender),class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"iconfont icon-yonghuziliao"}))],2),t.content&&""!==String(t.content).trim()?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["chat-content",{"chat-content-user":t.sender===W.value}])},[e.createElementVNode("view",{innerHTML:g(t.content)},null,8,["innerHTML"])],2)):e.createCommentVNode("",!0)],10,["id"])})),128)):e.createCommentVNode("",!0),2===f.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(oe.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":t.sender===W.value}]),key:a,id:"msg-"+a},[e.createElementVNode("view",{class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":t.sender===W.value}])},[t.sender===W.value&&(null==(n=J.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:J.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):Z.value.length>0&&ee(t.sender)?(e.openBlock(),e.createElementBlock("image",{key:1,src:ee(t.sender),class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"iconfont icon-yonghuziliao"}))],2),e.createElementVNode("view",{class:e.normalizeClass(["chat-content",{"chat-content-user":t.sender===W.value}])},[t.message&&""!==String(t.message).trim()?(e.openBlock(),e.createElementBlock("view",{key:0,innerHTML:g(t.message)},null,8,["innerHTML"])):e.createCommentVNode("",!0),t.contentJson?(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(JSON.parse(t.contentJson),((t,a)=>{return e.openBlock(),e.createElementBlock("view",{key:a,class:"file-item"},[["jpg","jpeg","png","gif","webp","bmp"].includes(t.extendName.toLowerCase())?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.url,mode:"widthFix",class:"message-image",onClick:e=>{return a=t.url,void uni.previewImage({urls:[a]});var a}},null,8,["src","onClick"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file",onClick:e=>{return a=t.url,void uni.downloadFile({url:a,success:e=>{uni.openDocument({filePath:e.tempFilePath,showMenu:!0})}});var a}},[e.createElementVNode("view",{class:"file-icon"},"📄"),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-size"},e.toDisplayString((n=t.fileSize,n?n<1?(1024*n).toFixed(0)+"KB":n.toFixed(2)+"MB":"0KB")),1)],8,["onClick"]))]);var n})),128))])):e.createCommentVNode("",!0)],2)],10,["id"])})),128)):e.createCommentVNode("",!0)],40,["scroll-into-view"]),e.createElementVNode("view",{class:"chat-interactive-container"},[e.createElementVNode("view",{class:"chat-interactive-group"},[e.createElementVNode("view",{class:"chat-interactive-btn",onClick:x},"拍照上传"),e.createElementVNode("view",{class:"chat-interactive-btn",onClick:o[5]||(o[5]=e=>(t("log","at pages/Chat/Chat.vue:448","点击了上传文件"),void O.chooseFile({count:5,type:"file",success:e=>{S.value=e.tempFiles,_.value.push(...e.tempFiles),uni.showToast({title:`已选择 ${e.tempFiles.length} 个文件`,icon:"success"})},fail:e=>{t("error","at pages/Chat/Chat.vue:463","选择失败:",e),uni.showToast({title:"选择失败",icon:"error"})}})))},"上传文件")]),_.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"image-list"},[e.createElementVNode("view",{class:"image-title"},"已选择: ("+e.toDisplayString(_.value.length)+")",1),e.createElementVNode("view",{class:"image-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(_.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"image-item",key:a},[e.createElementVNode("view",{class:"image-info"},[e.createElementVNode("text",{class:"image-name"},e.toDisplayString(t.name),1),e.createElementVNode("text",{class:"delete-btn",onClick:e.withModifiers((e=>(e=>{uni.showModal({title:"提示",content:"确定要删除这张图片吗?",success:t=>{t.confirm&&(_.value.splice(e,1),uni.showToast({title:"删除成功",icon:"success"}))}})})(a)),["stop"])},"删除",8,["onClick"])])])))),128))])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"chat-input-container"},[e.withDirectives(e.createElementVNode("textarea",{class:"message-input",placeholder:"输入消息...",onConfirm:T,"confirm-type":"send","onUpdate:modelValue":o[6]||(o[6]=e=>F.value=e),"auto-height":""},null,544),[[e.vModelText,F.value]]),e.createElementVNode("view",{class:"input-btn-group"},[e.createElementVNode("view",{class:"iconfont icon-tingzhi icon-btn"})])])])])])])],64)}}},[["__scopeId","data-v-fb45d58d"]]),R=c({__name:"WorkSpace",setup(n){const o=e.ref(""),l=e.ref("工作区"),s=e.ref(!1),c=e.ref([]),i=()=>{s.value&&(c.value=[]),s.value=!s.value},r=e=>{uni.showModal({title:"重命名",content:"请输入新名称",editable:!0,placeholderText:e.name,success:t=>{t.confirm&&t.content&&updateFolderName(e.id,t.content)}})},u=e=>{uni.showToast({title:"移动功能开发中",icon:"none"})},m=e=>{uni.showModal({title:"提示",content:`确定要删除文件夹"${e.name}"吗?`,success:e=>{e.confirm&&t("log","at pages/WorkSpace/WorkSpace.vue:147","确认删除文件夹")}})},v=e.ref(!1),p=()=>{v.value=!v.value},f=e.ref(""),g=e.ref(!1),h=()=>{g.value=!g.value},w=e.ref({root:[{id:1,name:"文档资料",parentId:"root",children:[{id:11,name:"工作文档",parentId:1,children:[]},{id:12,name:"学习笔记",parentId:1,children:[]},{id:13,name:"合同模板",parentId:1,children:[]}]},{id:2,name:"图片素材",parentId:"root",children:[{id:21,name:"风景图片",parentId:2,children:[]},{id:22,name:"人物照片",parentId:2,children:[]},{id:23,name:"UI图标",parentId:2,children:[]}]},{id:3,name:"视频文件",parentId:"root",children:[{id:31,name:"教程视频",parentId:3,children:[]},{id:32,name:"会议录像",parentId:3,children:[]}]},{id:4,name:"项目代码",parentId:"root",children:[{id:41,name:"前端项目",parentId:4,children:[]},{id:42,name:"后端服务",parentId:4,children:[]}]},{id:5,name:"安装包",parentId:"root",children:[]},{id:6,name:"备份文件",parentId:"root",children:[]},{id:7,name:"临时文件",parentId:"root",children:[]},{id:8,name:"个人收藏",parentId:"root",children:[]}]}),k=e.ref([]),y=e.ref([]),E=()=>{y.value=(()=>{const e=k.value.length>0?k.value[k.value.length-1].id:"root";if("root"===e)return w.value.root||[];const t=(e,a)=>{for(const n of e){if(n.id===a)return n;if(n.children&&n.children.length>0){const e=t(n.children,a);if(e)return e}}return null},a=t(w.value.root,e);return a?a.children:[]})()},N=()=>{s.value?c.value.length===y.value.length?c.value=[]:c.value=y.value.map((e=>e.id)):k.value.length>0?(k.value.pop(),0===k.value.length?(l.value="工作区",o.value=null):(l.value=k.value[k.value.length-1].name,o.value=k.value.length>1?k.value[k.value.length-2].name:"工作区"),E(),f.value="",g.value=!1):uni.navigateBack({delta:1,fail(){t("log","at pages/WorkSpace/WorkSpace.vue:363","返回失败,进入兜底跳转"),uni.reLaunch({url:"/pages/Chat/Chat"})}})};return e.onMounted((()=>{E()})),(t,n)=>{const w=a(e.resolveDynamicComponent("uni-icons"),d);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"workspace-container page-container"},[e.createElementVNode("view",{class:"workspace-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:n[0]||(n[0]=(...e)=>N&&N(...e))},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"}),e.createElementVNode("view",{class:"navbar-before-title workspace-text"},e.toDisplayString(s.value?"全选":o.value),1)]),e.createElementVNode("view",{class:"navbar-title workspace-text"},e.toDisplayString(l.value),1),e.createElementVNode("view",{class:"navbar-right"},[s.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right-text workspace-text",onClick:n[1]||(n[1]=e=>i())}," 完成")):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["iconfont icon-gengduo",v.value?"menu-open":"custom-navbar-icon"]),onClick:p},null,2))]),v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:n[2]||(n[2]=e=>{i(),p()})},"选择"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item"},"新建文件夹")])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"search-file-warpper"},[e.createElementVNode("view",{class:"search-file"},[e.createElementVNode("view",{class:"iconfont icon-sousuo"}),e.withDirectives(e.createElementVNode("input",{class:"search-file-input",placeholder:"搜索",onFocus:h,"onUpdate:modelValue":n[3]||(n[3]=e=>f.value=e)},null,544),[[e.vModelText,f.value]])]),g.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"cancel-search",onClick:h},"取消")):e.createCommentVNode("",!0)])]),e.createElementVNode("view",{class:"workspace-content"},[0===y.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createTextVNode(" 文件夹为空 ")])):e.createCommentVNode("",!0),y.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"folder-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["folder-item",{"select-folder":c.value.includes(t.id)}]),key:t.id,onClick:e=>s.value?(e=>{const t=c.value.indexOf(e);-1!==t?c.value.splice(t,1):c.value.push(e)})(t.id):(e=>{k.value.push({id:e.id,name:e.name}),l.value=e.name,o.value=k.value.length>1?k.value[k.value.length-2].name:"工作区",E(),f.value="",g.value=!1})(t),onLongpress:e=>(e=>{s.value||uni.showActionSheet({itemList:["重命名","删除","下载","压缩"],success:t=>{switch(t.tapIndex){case 0:r(e);break;case 1:m(e);break;case 2:case 3:u()}}})})(t)},[e.createElementVNode("view",{class:"iconfont icon-a-wenjianjiawenjian folder-item-style"}),e.createElementVNode("view",{class:"folder-name"},e.toDisplayString(t.name),1),s.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["folder-checkbox",{"select-folder":c.value.includes(t.id)}])},[c.value.includes(t.id)?(e.openBlock(),e.createBlock(w,{key:0,type:"checkmarkempty",color:"#fff"})):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],42,["onClick","onLongpress"])))),128))])):e.createCommentVNode("",!0)]),s.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["workspace-footer",{"folder-actions":c.value.length>0}])},[e.createElementVNode("view",{class:"iconfont icon-shangchuan"}),e.createElementVNode("view",{class:"iconfont icon-fuzhi"}),e.createElementVNode("view",{class:"iconfont icon-wenjian"}),e.createElementVNode("view",{class:"iconfont icon-del"}),e.createElementVNode("view",{class:"iconfont icon-gengduo"})],2)):e.createCommentVNode("",!0)])],64)}}},[["__scopeId","data-v-ea107472"]]),q=c({__name:"UserProfileModal",setup(n){const o=()=>{uni.navigateBack({url:"/pages/Chat/Chat"})},l=()=>{uni.navigateBack({url:"/pages/Chat/Chat"})},s=e.ref(""),c=e.ref("满满华华"),i=e.ref("08042@hh.com"),r=e.ref(!1),u=e.ref(!1),m=()=>{uni.chooseImage({count:1,sizeType:["compressed"],sourceType:["album","camera"],success:e=>{const t=e.tempFilePaths[0];v(t)},fail:e=>{t("log","at pages/UserProfileModal/UserProfileModal.vue:81","选择图片失败",e)}})},v=e=>{s.value=e};return(t,n)=>{const v=a(e.resolveDynamicComponent("uni-icons"),d);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"user-profile page-container"},[e.createElementVNode("view",{class:"modal-header"},[e.createElementVNode("view",{class:"modal-left",onClick:o},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"})]),e.createElementVNode("view",{class:"modal-title"},[e.createElementVNode("view",{class:"title-text"},"编辑资料")]),e.createElementVNode("view",{class:"modal-right",onClick:l},[e.createElementVNode("view",{class:"save-btn"},"保存")])]),e.createElementVNode("view",{class:"modal-body"},[e.createElementVNode("view",{class:"avatar-upload-section",onClick:m},[e.createElementVNode("view",{class:"avatar-upload-container"},[s.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"avatar-preview"},[e.createElementVNode("image",{src:s.value,mode:"aspectFill"},null,8,["src"])])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"avatar-placeholder"},[e.createVNode(v,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))])]),e.createElementVNode("view",{class:"form-card"},[e.createElementVNode("view",{class:"form-field"},[e.createElementVNode("view",{class:"form-text"},"用户名"),e.withDirectives(e.createElementVNode("input",{"adjust-position":"false",class:e.normalizeClass(["form-field-input form-field-username",{"edit-input-focus":r.value}]),"onUpdate:modelValue":n[0]||(n[0]=e=>c.value=e),onFocus:n[1]||(n[1]=e=>r.value=!0),onBlur:n[2]||(n[2]=e=>r.value=!1)},null,34),[[e.vModelText,c.value]])]),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"form-field"},[e.createElementVNode("view",{class:"form-text"},"邮箱"),e.withDirectives(e.createElementVNode("input",{"adjust-position":"false",class:e.normalizeClass(["form-field-input form-field-emile",{"edit-input-focus":u.value}]),"onUpdate:modelValue":n[3]||(n[3]=e=>i.value=e),onFocus:n[4]||(n[4]=e=>u.value=!0),onBlur:n[5]||(n[5]=e=>u.value=!1)},null,34),[[e.vModelText,i.value]])])]),e.createElementVNode("view",{class:"prompt-content"},"*保存后再返回哟")])])],64)}}},[["__scopeId","data-v-d1eea957"]]),W=c({__name:"ContactPages",setup(n){const o=A(),c=()=>{uni.navigateBack({delta:1,fail(){uni.reLaunch({url:"/pages/Chat/Chat"})}})},i=(e,t="")=>{uni.setStorageSync("chatType",e),t&&uni.setStorageSync("currentSessionId",t),uni.reLaunch({url:"/pages/Chat/Chat"})},r=e.ref(0),m=e.reactive([{name:"contacts",label:"通讯录",icon:"📞"},{name:"createGroup",label:"新建群聊",icon:"👥"},{name:"addFriend",label:"添加好友",icon:"➕"},{name:"videoCall",label:"视频会议",icon:"📹"},{name:"friendRequest",label:"好友申请",icon:"📨"}]),v=e=>{r.value=e.detail.current},p=e.ref(""),f=e.ref(""),g="宇恒一号",h=e.ref([]),w=async e=>{if(!(null==e?void 0:e.length))return[];try{const t=e.map((e=>e.receiver)),a=await s(p.value,t),n=new Map(a.map((e=>[e.user_id,e]))||[]);return e.map((e=>{const t=n.get(e.receiver);return{...e,avatar:(null==t?void 0:t.avatar)||null}}))}catch(a){return t("error","at pages/ContactPages/ContactPages.vue:460","获取好友头像失败",a),e}};e.onMounted((async()=>{await(async()=>{try{t("log","at pages/ContactPages/ContactPages.vue:425","开始获取好友列表"),p.value=u();const e=await l(p.value);f.value=e._id,t("log","at pages/ContactPages/ContactPages.vue:429","UserId.value:",f.value);const a=await D(f.value);t("log","at pages/ContactPages/ContactPages.vue:431","friendList:",a),a&&a.length?h.value=await w(a):(h.value=[],t("log","at pages/ContactPages/ContactPages.vue:436","好友列表为空"))}catch(e){t("error","at pages/ContactPages/ContactPages.vue:439","获取好友列表失败:",e),h.value=[]}})(),await y(),o.isConnected||(p.value&&f.value?o.connect({token:p.value,UserId:f.value}):t("warn","at pages/ContactPages/ContactPages.vue:324","Token或UserId未准备好"))}));const k=e.ref([]),y=async()=>{try{t("log","at pages/ContactPages/ContactPages.vue:476","开始获取群聊列表"),p.value=u();const e=await l(p.value);f.value=e._id,t("log","at pages/ContactPages/ContactPages.vue:480","UserId.value:",f.value),k.value=await L(f.value)}catch(e){t("error","at pages/ContactPages/ContactPages.vue:483","获取群聊列表失败:",e),k.value=[]}},E=e.ref(""),N=e.ref(),V=async()=>{try{if(!E.value)return void uni.showToast({title:"群名称不能为空",icon:"none"});if(0===C.value.length)return void uni.showToast({title:"请选择群成员",icon:"none"});await new Promise(((e,a)=>{if(o.isConnected)return void e();if(!p.value||!f.value)return void a(new Error("Token或UserId未准备好"));t("log","at pages/ContactPages/ContactPages.vue:504","friendSocket 未连接,正在建立连接..."),o.connect({token:p.value,UserId:f.value});const n=setInterval((()=>{o.isConnected&&(clearInterval(n),t("log","at pages/ContactPages/ContactPages.vue:513","friendSocket 连接已建立"),e())}),100);setTimeout((()=>{clearInterval(n),o.isConnected||a(new Error("连接超时"))}),1e4)})),N.value={version:"1.1",body:{command:3,userIds:memberIds,message:"我来邀请你们了",sender:f.value,callBackMessage:!0,groupName:E.value,teamCreateReq:{access_token:p.value}}};await o.send(N.value)?await b():t("log","at pages/ContactPages/ContactPages.vue:567","发送新建群聊消息失败")}catch(e){uni.showToast({title:`新建群聊失败${e}`,icon:"error"})}},b=()=>new Promise(((a,n)=>{const l=setTimeout((()=>{n(new Error("超时未返回群聊创建结果"))}),18e4),s=e.watch((()=>o.command),(async e=>{if(t("log","at pages/ContactPages/ContactPages.vue:588","创建一个一次性监听器"),e&&3===o.command){t("log","at pages/ContactPages/ContactPages.vue:590","监听到command的值是3,检查群聊是否创建成功",o.command);try{const e=k.value.find((e=>e.id===o.groupId));e?t("log","at pages/ContactPages/ContactPages.vue:596","✅ 新建群聊成功",e):t("log","at pages/ContactPages/ContactPages.vue:598","❌ 新建群聊失败 / 群组不存在")}catch(a){t("error","at pages/ContactPages/ContactPages.vue:602","保存AI回复失败:",a),n(a)}finally{o.command=null,o.groupId=null,s(),clearTimeout(l)}}}))})),C=e.ref([]),_=e.ref(!1),x=e.ref(""),S=e.ref([]),B=()=>{if(!x.value.trim())return void(S.value=[]);const e=x.value.toLowerCase().trim(),t=U.value.filter((t=>t.nickname.toLowerCase().includes(e)||t.username.toLowerCase().includes(e)||t.email.toLowerCase().includes(e)));S.value=t},T=()=>{_.value=!_.value},I=e.ref(null),M=e=>{const a=U.value.find((t=>t.id===e));a?I.value={...a}:(t("warn","at pages/ContactPages/ContactPages.vue:670","未找到该好友"),I.value=null)},P=()=>{I.value=null,O.value=!1},z=e.ref(!1),j=e.ref(!1),$=()=>{z.value=!z.value},F=()=>{j.value=!j.value},O=e.ref(!1),U=e.ref([{id:1,nickname:"张三",username:"zhangsan",email:"zhangsan@example.com",avatar:"👤"},{id:2,nickname:"李四",username:"lisi",email:"lisi@example.com",avatar:"👥"},{id:3,nickname:"王小明",username:"wangxm",email:"wang@example.com",avatar:"👪"},{id:4,nickname:"赵磊",username:"zhaolei",email:"zhao@example.com",avatar:"🗣️"},{id:5,nickname:"张三2",username:"zhangsan",email:"zhangsan@example.com",avatar:"👤"},{id:6,nickname:"李四2",username:"lisi",email:"lisi@example.com",avatar:"👥"},{id:7,nickname:"王小明2",username:"wangxm",email:"wang@example.com",avatar:"👪"},{id:8,nickname:"赵磊2",username:"zhaolei",email:"zhao@example.com",avatar:"🗣️"}]);return(n,o)=>{const l=a(e.resolveDynamicComponent("uni-icons"),d);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),I.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-overlay"},[e.createElementVNode("view",{class:"popup-card"},[e.createElementVNode("view",{class:"close-popup-card",onClick:P},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},e.toDisplayString(O.value?"通过好友申请":"申请添加朋友"),1),e.createElementVNode("view",{class:"friend-card"},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar"},e.toDisplayString(I.value.avatar),1)]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(I.value.username),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(I.value.sessionId),1)])]),e.createElementVNode("view",{class:"nickname-wrapper"},[e.createElementVNode("view",null,"好友备注"),e.createElementVNode("input",{class:"input-nickname",placeholder:"请输入好友名称"})]),e.createElementVNode("view",{class:"text-btn confirm-btn"},e.toDisplayString(O.value?"确认通过":"发送申请"),1)])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"tabbar-page page-container"},[e.createElementVNode("swiper",{class:"content-swiper",current:r.value,duration:300,onChange:v},[e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:c}),e.createElementVNode("view",{class:"tabpage-title"},"通讯录")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[e.createElementVNode("view",{class:"friend-card",onClick:o[0]||(o[0]=e=>i(0))},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar",style:{"background-color":"#38bdf8"}},[e.createElementVNode("view",{class:"iconfont icon-Robot",style:{"font-size":"80rpx",color:"#fff"}})])]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(g),1),e.createElementVNode("view",{class:"friend-label"})]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(l,{type:"right"})])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.sessionId,onClick:e=>i(t.type,t.sessionId)},[e.createElementVNode("view",{class:"friend-card-left"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(l,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.friendNickName),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.sessionId),1)]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(l,{type:"right"})])],8,["onClick"])))),128)),e.createElementVNode("view",null,"群聊"),e.createElementVNode("view",{class:"solid-line"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.id,onClick:e=>i(t.type,t.id)},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar",style:{"background-color":"#ffaaff"}},[e.createElementVNode("view",{class:"iconfont icon-qunliao",style:{"font-size":"80rpx",color:"#fff"}})])]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.createTime),1)]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(l,{type:"right"})])],8,["onClick"])))),128))])])])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:c}),e.createElementVNode("view",{class:"tabpage-title"},"新建群聊")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("view",{class:"group-info"},[e.createElementVNode("view",{class:"group-name"},[e.createElementVNode("view",null,"群名称"),e.withDirectives(e.createElementVNode("input",{class:"input",placeholder:"请输入群名称","onUpdate:modelValue":o[1]||(o[1]=e=>E.value=e)},null,512),[[e.vModelText,E.value]])]),e.createElementVNode("view",{class:"group-member-wrapper"},[e.createElementVNode("view",{class:"member-title"},"群成员"),e.createElementVNode("view",{class:"group-ismember-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"group-ismember-info",key:a},[e.createElementVNode("view",{class:"group-ismember-name"},e.toDisplayString(t.friendNickName),1)])))),128))])]),e.createElementVNode("view",{class:"create-group-btn",onClick:V},"创建群聊")]),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(a=>{var n;return e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:a.receiver},[e.createElementVNode("view",{class:"friend-card-left"},[a.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:a.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(l,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(a.friendNickName),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(a.email),1)]),e.createElementVNode("view",{class:"friend-card-right",onClick:e=>(e=>{t("log","at pages/ContactPages/ContactPages.vue:623","选择的好友id:",e),t("log","at pages/ContactPages/ContactPages.vue:624","selectGroupMember.value=",JSON.stringify(C.value));const a=C.value.findIndex((t=>t.id===e));if(-1===a){const t=h.value.find((t=>t.receiver===e));t&&C.value.push({id:t.receiver,friendNickName:t.friendNickName})}else C.value.splice(a,1)})(a.receiver)},[e.createElementVNode("view",{class:"friend-checkbox"},[(null==(n=C.value)?void 0:n.find((e=>e.id===a.receiver)))?(e.openBlock(),e.createBlock(l,{key:0,type:"checkmarkempty"})):e.createCommentVNode("",!0)])],8,["onClick"])])})),128))])])])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:c}),e.createElementVNode("view",{class:"tabpage-title"},"添加好友")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("view",{class:"search-warpper"},[e.withDirectives(e.createElementVNode("input",{class:e.normalizeClass(["search-file-input",{active:_.value}]),onFocus:T,onBlur:T,"onUpdate:modelValue":o[2]||(o[2]=e=>x.value=e)},null,34),[[e.vModelText,x.value]]),e.createElementVNode("view",{class:"iconfont icon-sousuo",onClick:B})]),x.value?S.value.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"search-result"},[e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.id},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar"},e.toDisplayString(t.avatar),1)]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.nickname),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.email),1)]),e.createElementVNode("view",{class:"friend-card-right",onClick:e=>M(t.id)},[e.createElementVNode("view",{class:"add-btn text-btn"},"添加")],8,["onClick"])])))),128))])])])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"no-result"},"未找到相关用户,请尝试其他关键词")):(e.openBlock(),e.createElementBlock("view",{key:0,class:"search-tip"},"请输入用户名或邮箱进行搜索"))])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:c}),e.createElementVNode("view",{class:"tabpage-title"},"视频会议")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("view",{class:"join-meeting-wrapper"},[e.createElementVNode("view",null,"加入会议"),e.createElementVNode("input",{class:"input-meeting",placeholder:"请输入会议号"}),e.createElementVNode("view",{class:"meeting-btn text-btn"},"加入会议")]),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"create-meeting-wrapper"},[e.createElementVNode("view",null,"创建会议"),e.createElementVNode("view",{class:"meeting-field"},[e.createElementVNode("view",{class:"meeting-label"},"会议主题"),e.createElementVNode("input",{class:"input-meeting",placeholder:"例如:XXX"})]),e.createElementVNode("view",{class:"meeting-field"},[e.createElementVNode("view",{class:"meeting-label"},"会议密码"),e.createElementVNode("input",{class:"input-meeting",placeholder:"留空则无密码"})]),e.createElementVNode("view",{class:"meeting-field"},[e.createElementVNode("view",{class:"meeting-label"},"邀请好友"),e.createElementVNode("view",{class:"friend-card"},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar"},"avatar")]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},"friend.nickname"),e.createElementVNode("view",{class:"friend-label"},"friend.email")]),e.createElementVNode("view",{class:"friend-card-right",onClick:o[3]||(o[3]=e=>M(n.friend.id))},[e.createElementVNode("view",{class:"add-btn text-btn"},"添加")])])]),e.createElementVNode("view",{class:"meeting-toggles"},[e.createElementVNode("view",{class:"meeting-toggles-item"},[e.createElementVNode("view",{class:"meeting-toggles-icon icon-btn"},[e.createVNode(l,{type:"mic-filled"}),e.createTextVNode("开启麦克风入会 ")]),e.createElementVNode("view",{class:"meeting-toggles-switch",onClick:$},[e.createElementVNode("view",{class:e.normalizeClass(["switch-box",{active:z.value}])},[e.createElementVNode("view",{class:"switch-track"})],2)])]),e.createElementVNode("view",{class:"meeting-toggles-item"},[e.createElementVNode("view",{class:"meeting-toggles-icon icon-btn"},[e.createVNode(l,{type:"eye-filled"}),e.createTextVNode("开启摄像头入会 ")]),e.createElementVNode("view",{class:"meeting-toggles-switch",onClick:F},[e.createElementVNode("view",{class:e.normalizeClass(["switch-box",{active:j.value}])},[e.createElementVNode("view",{class:"switch-track"})],2)])])]),e.createElementVNode("view",{class:"meeting-btn text-btn"},"加入会议")])])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:c}),e.createElementVNode("view",{class:"tabpage-title"},"好友申请")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(U.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.id},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar"},e.toDisplayString(t.avatar),1)]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.nickname),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.email),1)]),e.createElementVNode("view",{class:"friend-card-right"},[e.createElementVNode("view",{class:"friend-option"},[e.createElementVNode("view",{class:"refuse-btn text-btn",onClick:e=>{}},"拒绝",8,["onClick"]),e.createElementVNode("view",{class:"agree-btn text-btn",onClick:e=>(e=>{O.value=!0,I.value={...e}})(t)},"同意",8,["onClick"])])])])))),128))])])])])])],40,["current"]),e.createElementVNode("view",{class:"bottom-tabbar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:t.name,onClick:e=>(e=>{r.value=e})(a),class:"tab-item"},[e.createElementVNode("view",{class:"tab-icon"},e.toDisplayString(t.icon),1),e.createElementVNode("view",{class:"tab-label"},e.toDisplayString(t.label),1)],8,["onClick"])))),128))])])],64)}}},[["__scopeId","data-v-35441fc3"]]),H=c({__name:"TemplateSpace",setup(a){const n=e=>{if(!e)return"";const t=Math.floor(e),a=new Date(1e3*t);return`${a.getFullYear()}-${(a.getMonth()+1).toString().padStart(2,"0")}-${a.getDate().toString().padStart(2,"0")} ${a.getHours().toString().padStart(2,"0")}:${a.getMinutes().toString().padStart(2,"0")}:${a.getSeconds().toString().padStart(2,"0")}`},o=e=>{if(!e||0===e)return"0 B";const t=["B","KB","MB","GB","TB"];let a=e,n=0;for(;a>=1024&&n{t("log","at pages/WorkSpace/TemplateSpace/TemplateSpace.vue:188","点击了编辑模板")},c=e.ref(""),i=e.ref([]),r=e=>{c.value=e,"all"===e&&(u.value="全部模板",i.value=y.value),"like"===e&&(u.value="收藏模板",i.value=y.value.filter((e=>!0===e.is_favorite)))},d=e.ref(""),u=e.ref("模板区"),m=e.ref(!1),v=e.ref([]),p=()=>{m.value&&(v.value=[]),m.value=!m.value},f=e.ref(!1),g=()=>{f.value=!f.value},h=e.ref(""),w=e.ref(!1),k=()=>{w.value=!w.value},y=e.ref([{name:"SKILL.md",type:"file",path:"SKILL.md",children:[],file_count:0,directory_count:0,size:4768,modified_time:1776827361.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"该回家看了的法国红酒看来法帝国海军快来尝尝v吧给v复仇计划曝光vi计划日方提供与i哦的风格和健康"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"的法国红酒看来法帝国海军快来尝尝v吧给"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:""},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"}]),E=()=>{m.value?v.value.length===i.value.length?v.value=[]:v.value=i.value.map((e=>e.id)):(!m.value&&i.value&&(i.value=[],c.value="",u.value="模板区"),m.value||i.value||uni.navigateBack({delta:1,fail(){t("log","at pages/WorkSpace/TemplateSpace/TemplateSpace.vue:468","返回失败,进入兜底跳转"),uni.reLaunch({url:"/pages/Chat/Chat"})}}))};return(t,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"popup-overlay"},[e.createElementVNode("view",{class:"popup-card"},[e.createElementVNode("view",{class:"close-popup-card"},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"编辑模板"),e.createElementVNode("view",{class:"edit-template-wrapper"},[e.createElementVNode("view",{class:"edit-template-name"},[e.createElementVNode("view",null,"模板名称"),e.withDirectives(e.createElementVNode("input",{"placeholder-style":"请输入模板名称","onUpdate:modelValue":a[0]||(a[0]=e=>l.value=e)},null,512),[[e.vModelText,l.value]])]),e.createElementVNode("view",{class:"edit-template-name"},[e.createElementVNode("view",null,"模板内容"),e.createElementVNode("view",{class:"markdown-editor-pane"},[e.createElementVNode("view",{class:"markdown-pane-header"}," 编辑 "),e.createElementVNode("textarea")]),e.createElementVNode("view",{class:"markdown-preview-pane"},[e.createElementVNode("view",{class:"markdown-pane-header"}," 预览 "),e.createElementVNode("view")])])])])]),e.createElementVNode("view",{class:"workspace-container page-container"},[e.createElementVNode("view",{class:"workspace-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:a[1]||(a[1]=(...e)=>E&&E(...e))},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"}),e.createElementVNode("view",{class:"navbar-before-title workspace-text"},e.toDisplayString(m.value?"全选":d.value),1)]),e.createElementVNode("view",{class:"navbar-title workspace-text"},e.toDisplayString(u.value),1),c.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right"},[m.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right-text workspace-text",onClick:a[2]||(a[2]=e=>p())}," 完成")):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["iconfont icon-gengduo",f.value?"menu-open":"custom-navbar-icon"]),onClick:g},null,2))])):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:a[3]||(a[3]=e=>{p(),g()})},"选择"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item"},"新建模板"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item"},"上传模板")])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"search-file-warpper"},[e.createElementVNode("view",{class:"search-file"},[e.createElementVNode("view",{class:"iconfont icon-sousuo"}),e.withDirectives(e.createElementVNode("input",{class:"search-file-input",placeholder:"搜索",onFocus:k,"onUpdate:modelValue":a[4]||(a[4]=e=>h.value=e)},null,544),[[e.vModelText,h.value]])]),w.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"cancel-search",onClick:k},"取消")):e.createCommentVNode("",!0)])]),c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-grid"},[e.createElementVNode("view",{class:"folder-item",onClick:a[5]||(a[5]=e=>r("all"))},[e.createElementVNode("view",{class:"iconfont icon-a-wenjianjiawenjian folder-item-style"}),e.createElementVNode("view",{class:"folder-name"},"全部模板")]),e.createElementVNode("view",{class:"folder-item",onClick:a[6]||(a[6]=e=>r("like"))},[e.createElementVNode("view",{class:"iconfont icon-a-wenjianjiawenjian folder-item-style"}),e.createElementVNode("view",{class:"folder-name"},"收藏模板")])])),c.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"workspace-content"},[0===i.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createTextVNode(" 暂无模板 ")])):e.createCommentVNode("",!0),i.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"template-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"template-card",key:a},[e.createElementVNode("view",{class:"template-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"template-content"},[e.createElementVNode("view",{class:"template-content-text"},e.toDisplayString(t.content),1)]),e.createElementVNode("view",{class:"template-info-wrapper"},[e.createElementVNode("view",{class:"template-item"},[e.createElementVNode("view",{class:"template-time background-style"},e.toDisplayString(n(t.modified_time)),1),e.createElementVNode("view",{class:"template-cache background-style"},e.toDisplayString(o(t.size)),1)]),e.createElementVNode("view",{class:"template-option"},[e.createElementVNode("view",{class:e.normalizeClass(["iconfont",t.is_favorite?"icon-favorite-fill":"icon-favorite"]),onClick:e=>(e=>{let t;"all"===c.value?t=y.value[e]:"like"===c.value&&(t=y.value.filter((e=>e.is_favorite))[e]);t&&(t.is_favorite=!t.is_favorite),"all"===c.value?i.value=[...y.value]:i.value=y.value.filter((e=>e.is_favorite))})(a)},null,10,["onClick"]),e.createElementVNode("view",{class:"iconfont icon-edit-fill",onClick:s}),e.createElementVNode("view",{class:"iconfont icon-choose-fill"})])])])))),128))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:e.normalizeClass(["workspace-footer",{"folder-actions":v.value.length>0}])},[e.createElementVNode("view",{class:"iconfont icon-shangchuan"}),e.createElementVNode("view",{class:"iconfont icon-fuzhi"}),e.createElementVNode("view",{class:"iconfont icon-wenjian"}),e.createElementVNode("view",{class:"iconfont icon-del"}),e.createElementVNode("view",{class:"iconfont icon-gengduo"})],2)):e.createCommentVNode("",!0)])],64))}},[["__scopeId","data-v-2acd55d4"]]),J={__name:"text",setup(t){const a=e.ref("");return e.onMounted((()=>{a.value='\n明白了!您希望在我的回复中直接嵌入可编辑的表单卡片。让我试试:\n\n---\n\n
    \n

    \n✏️ 直接在下方编辑任务\n

    \n\n
    \n
    \n\n\n
    \n\n
    \n\n\n
    \n\n
    \n
    \n\n\n
    \n
    \n\n\n
    \n
    \n\n
    \n\n\n
    \n\n
    \n\n
    \n\n\n\n
    \n
    \n\n
    \n\n
    \n\n\n\n\n
    \n
    \n\n
    \n\n\n
    \n
    \n
    \n\n\n\n---\n\n**✅ 您现在可以直接在上方的卡片中填写任务信息,点击"添加任务"即可!**\n\n填写完成后告诉我"已填好"或"添加",我会帮您确认是否成功!\n'})),(t,n)=>{return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{innerHTML:(o=a.value,o.replace(/<\/?script>/gi,(e=>{let t="";for(let a=0;a{const e=n.connectionStatus;return{"status-connected":"connected"===e,"status-connecting":"connecting"===e,"status-error":"error"===e,"status-disconnected":"disconnected"===e}})),i=()=>{o.value.token?n.connect({token:o.value.token,conversationId:m()}):uni.showToast({title:"请输入Token",icon:"none"})},r=()=>{n.disconnect()},d=async()=>{try{await n.sendPing()}catch(e){uni.showToast({title:"发送失败",icon:"none"})}},p=async()=>{if(l.value.trim())try{const e={ws_event:"message",data:{task_call_id:v(),result:{tools:[]}}};await n.send(e),l.value=""}catch(e){uni.showToast({title:"发送失败",icon:"none"})}},f=()=>{if(l.value.trim())try{const e=JSON.parse(l.value);l.value=JSON.stringify(e,null,2)}catch{uni.showToast({title:"不是有效的JSON",icon:"none"})}},g=()=>{};return e.watch((()=>n.isDisconnected),(e=>{e&&n.messageString&&t("log","at pages/text/text2.vue:253",n.messageString)})),e.onMounted((()=>{n.addLog("info","=== Socket测试页面 ==="),n.addLog("info","页面已加载"),n.isConnected&&n.addLog("info","当前已处于连接状态")})),e.onUnmounted((()=>{n.addLog("info","页面卸载")})),(t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createElementVNode("view",{class:"status-card"},[e.createElementVNode("text",{class:"status-label"},"连接状态"),e.createElementVNode("view",{class:e.normalizeClass(["status-value",c.value])},[e.createElementVNode("text",null,e.toDisplayString(e.unref(n).getStatusText()),1)],2),e.unref(n).reconnectAttempts>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"status-info"},[e.createElementVNode("text",{class:"reconnect-info"},"重连次数: "+e.toDisplayString(e.unref(n).reconnectAttempts),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"config-card"},[e.createElementVNode("text",{class:"section-title"},"连接配置"),e.createElementVNode("view",{class:"input-group"},[e.createElementVNode("text",{class:"input-label"},"Token"),e.withDirectives(e.createElementVNode("input",{class:"input-field","onUpdate:modelValue":a[0]||(a[0]=e=>o.value.token=e),placeholder:"请输入Token"},null,512),[[e.vModelText,o.value.token]])]),e.createElementVNode("view",{class:"input-group"},[e.createElementVNode("text",{class:"input-label"},"Conversation ID"),e.withDirectives(e.createElementVNode("input",{class:"input-field","onUpdate:modelValue":a[1]||(a[1]=e=>o.value.conversationId=e),placeholder:"请输入会话ID(可选)"},null,512),[[e.vModelText,o.value.conversationId]])])]),e.createElementVNode("view",{class:"control-card"},[e.createElementVNode("button",{class:"btn btn-primary",disabled:e.unref(n).isConnected||e.unref(n).isConnecting,onClick:i},e.toDisplayString(e.unref(n).isConnecting?"连接中...":"连接"),9,["disabled"]),e.createElementVNode("button",{class:"btn btn-danger",disabled:!e.unref(n).isConnected,onClick:r}," 断开 ",8,["disabled"]),e.createElementVNode("button",{class:"btn btn-secondary",onClick:d,disabled:!e.unref(n).isConnected}," Ping ",8,["disabled"])]),e.createElementVNode("view",{class:"send-card"},[e.createElementVNode("text",{class:"section-title"},"发送消息"),e.createElementVNode("view",{class:"send-input-wrapper"},[e.withDirectives(e.createElementVNode("textarea",{class:"send-input","onUpdate:modelValue":a[2]||(a[2]=e=>l.value=e),placeholder:"输入要发送的消息(JSON格式)",disabled:!e.unref(n).isConnected},null,8,["disabled"]),[[e.vModelText,l.value]]),e.createElementVNode("view",{class:"send-buttons"},[e.createElementVNode("button",{class:"btn btn-primary btn-small",disabled:!e.unref(n).isConnected||!l.value.trim(),onClick:p}," 发送 ",8,["disabled"]),e.createElementVNode("button",{class:"btn btn-outline btn-small",disabled:!l.value.trim(),onClick:f}," 格式化 ",8,["disabled"])])]),e.createElementVNode("view",{class:"quick-messages"},[e.createElementVNode("text",{class:"quick-label"},"快捷消息:"),e.createElementVNode("view",{class:"quick-btns"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(t=>(e.openBlock(),e.createElementBlock("button",{key:t.label,class:"quick-btn",disabled:!e.unref(n).isConnected,onClick:e=>(async e=>{const t={ws_event:"message",data:{task_call_id:v(),token:u(),conversation_id:m()}};try{await n.send(t)}catch(a){uni.showToast({title:"发送失败",icon:"none"})}})(t.data)},e.toDisplayString(t.label),9,["disabled","onClick"])))),128))])])]),e.createElementVNode("view",{class:"log-card"},[e.createElementVNode("view",{class:"log-header"},[e.createElementVNode("view",{class:"log-title-wrapper"},[e.createElementVNode("text",{class:"section-title"},"日志"),e.createElementVNode("text",{class:"log-count"},"("+e.toDisplayString(e.unref(n).logs.length)+")",1)]),e.createElementVNode("view",{class:"log-actions"},[e.createElementVNode("button",{class:"btn btn-small btn-secondary",onClick:a[3]||(a[3]=(...t)=>e.unref(n).clearLogs&&e.unref(n).clearLogs(...t))},"清空")])]),e.createElementVNode("scroll-view",{class:"log-list","scroll-y":"",onScrolltoupper:g},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(n).logs,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass(["log-item","log-"+t.type])},[e.createElementVNode("text",{class:"log-time"},e.toDisplayString(t.time),1),e.createElementVNode("text",{class:"log-content"},e.toDisplayString(t.content),1)],2)))),128))],32)])]))}},[["__scopeId","data-v-939e1d1d"]]);__definePage("pages/Login/Login",i),__definePage("pages/Chat/Chat",U),__definePage("pages/WorkSpace/WorkSpace",R),__definePage("pages/UserProfileModal/UserProfileModal",q),__definePage("pages/ContactPages/ContactPages",W),__definePage("pages/WorkSpace/TemplateSpace/TemplateSpace",H),__definePage("pages/text/text",J),__definePage("pages/text/text2",G);const K={onLaunch:function(){t("log","at App.vue:4","App Launch")},onShow:function(){t("log","at App.vue:7","App Show")},onHide:function(){t("log","at App.vue:10","App Hide")}};const{app:X,Vuex:Y,Pinia:Q}=function(){const t=e.createVueApp(K),a=function(){const t=e.effectScope(!0),a=t.run((()=>e.ref({})));let n=[],o=[];const l=e.markRaw({install(e){y(l),l._a=e,e.provide(E,l),e.config.globalProperties.$pinia=l,o.forEach((e=>n.push(e))),o=[]},use(e){return this._a?n.push(e):o.push(e),this},_p:n,_a:null,_e:t,_s:new Map,state:a});return l}();return t.use(a),{app:t,pinia:a}}();uni.Vuex=Y,uni.Pinia=Q,X.provide("__globalStyles",__uniConfig.styles),X._component.mpType="app",X._component.render=()=>{},X.mount("#app")}(Vue); +let S;const x=e=>S=e,T=Symbol();function D(e){return e&&"object"==typeof e&&"[object Object]"===Object.prototype.toString.call(e)&&"function"!=typeof e.toJSON}var j,P;(P=j||(j={})).direct="direct",P.patchObject="patch object",P.patchFunction="patch function";const $=()=>{};function L(t,a,n,o=$){t.push(a);const l=()=>{const e=t.indexOf(a);e>-1&&(t.splice(e,1),o())};return!n&&e.getCurrentScope()&&e.onScopeDispose(l),l}function M(e,...t){e.slice().forEach((e=>{e(...t)}))}const I=e=>e();function z(t,a){t instanceof Map&&a instanceof Map&&a.forEach(((e,a)=>t.set(a,e))),t instanceof Set&&a instanceof Set&&a.forEach(t.add,t);for(const n in a){if(!a.hasOwnProperty(n))continue;const o=a[n],l=t[n];D(l)&&D(o)&&t.hasOwnProperty(n)&&!e.isRef(o)&&!e.isReactive(o)?t[n]=z(l,o):t[n]=o}return t}const F=Symbol();const{assign:O}=Object;function A(t,a,n={},o,l,s){let c;const i=O({actions:{}},n),r={deep:!0};let u,d,m,v=[],p=[];const f=o.state.value[t];let h;function g(a){let n;u=d=!1,"function"==typeof a?(a(o.state.value[t]),n={type:j.patchFunction,storeId:t,events:m}):(z(o.state.value[t],a),n={type:j.patchObject,payload:a,storeId:t,events:m});const l=h=Symbol();e.nextTick().then((()=>{h===l&&(u=!0)})),d=!0,M(v,n,o.state.value[t])}s||f||(o.state.value[t]={}),e.ref({});const w=s?function(){const{state:e}=n,t=e?e():{};this.$patch((e=>{O(e,t)}))}:$;function k(e,a){return function(){x(o);const n=Array.from(arguments),l=[],s=[];function c(e){l.push(e)}function i(e){s.push(e)}let r;M(p,{args:n,name:e,store:E,after:c,onError:i});try{r=a.apply(this&&this.$id===t?this:E,n)}catch(u){throw M(s,u),u}return r instanceof Promise?r.then((e=>(M(l,e),e))).catch((e=>(M(s,e),Promise.reject(e)))):(M(l,r),r)}}const y={_p:o,$id:t,$onAction:L.bind(null,p),$patch:g,$reset:w,$subscribe(a,n={}){const l=L(v,a,n.detached,(()=>s())),s=c.run((()=>e.watch((()=>o.state.value[t]),(e=>{("sync"===n.flush?d:u)&&a({storeId:t,type:j.direct,events:m},e)}),O({},r,n))));return l},$dispose:function(){c.stop(),v=[],p=[],o._s.delete(t)}},E=e.reactive(y);o._s.set(t,E);const N=(o._a&&o._a.runWithContext||I)((()=>o._e.run((()=>(c=e.effectScope()).run(a)))));for(const V in N){const a=N[V];if(e.isRef(a)&&(b=a,!e.isRef(b)||!b.effect)||e.isReactive(a))s||(!f||D(C=a)&&C.hasOwnProperty(F)||(e.isRef(a)?a.value=f[V]:z(a,f[V])),o.state.value[t][V]=a);else if("function"==typeof a){const e=k(V,a);N[V]=e,i.actions[V]=a}}var C,b;return O(E,N),O(e.toRaw(E),N),Object.defineProperty(E,"$state",{get:()=>o.state.value[t],set:e=>{g((t=>{O(t,e)}))}}),o._p.forEach((e=>{O(E,c.run((()=>e({store:E,app:o._a,pinia:o,options:i}))))})),f&&s&&n.hydrate&&n.hydrate(E.$state,f),u=!0,d=!0,E}function U(t,a,n){let o,l;const s="function"==typeof a;function c(t,n){const c=e.hasInjectionContext();(t=t||(c?e.inject(T,null):null))&&x(t),(t=S)._s.has(o)||(s?A(o,a,l,t):function(t,a,n,o){const{state:l,actions:s,getters:c}=a,i=n.state.value[t];let r;r=A(t,(function(){i||(n.state.value[t]=l?l():{});const a=e.toRefs(n.state.value[t]);return O(a,s,Object.keys(c||{}).reduce(((a,o)=>(a[o]=e.markRaw(e.computed((()=>{x(n);const e=n._s.get(t);return c[o].call(e,e)}))),a)),{}))}),a,n,0,!0)}(o,l,t));return t._s.get(o)}return"string"==typeof t?(o=t,l=s?n:a):(l=t,o=t.id),c.$id=o,c}const q=new class{constructor(){this.ws=null,this.url="ws://cloud.yuxindazhineng.com/cloud_api/phone/app_ws",this.options={token:"",conversationId:"",onMessage:null,onError:null,onReconnect:null,onOpen:null,onClose:null},this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.reconnectDelay=3e3,this.reconnectTimer=null,this.heartbeatTimer=null,this.isManualClose=!1}connect(e={}){this.options={...this.options,...e},this.isManualClose=!1,this.ws&&this.close();try{this.ws=uni.connectSocket({url:this.url,success:()=>{t("log","at utils/socket.js:44","WebSocket 连接请求已发送")},fail:e=>{t("error","at utils/socket.js:47","WebSocket 连接失败:",e),this.handleError(e)}}),this.initEventHandlers()}catch(a){this.handleError(a)}}initEventHandlers(){this.ws&&(this.ws.onOpen((e=>{var a,n,o,l;t("log","at utils/socket.js:74","WebSocket 已连接"),this.reconnectAttempts>0&&(null==(n=(a=this.options).onReconnect)||n.call(a)),null==(l=(o=this.options).onOpen)||l.call(o,e),this.reconnectAttempts=0})),this.ws.onMessage((e=>{try{const a=JSON.parse(e.data);t("log","at utils/socket.js:87","收到了返回消息:",a),this.handleMessage(a)}catch(a){t("error","at utils/socket.js:91","消息解析失败:",a),uni.setStorageSync("currentSessionId",e.data.task_call_id)}})),this.ws.onError((e=>{t("error","at utils/socket.js:96","WebSocket 错误:",e),this.handleError(e)})),this.ws.onClose((e=>{var a,n;t("log","at utils/socket.js:100","WebSocket 已关闭:",e.code,e.reason),null==(n=(a=this.options).onClose)||n.call(a,e),this.stopHeartbeat(),!this.isManualClose&&this.reconnectAttempts{if(!this.isConnected())return void n(new Error("WebSocket 未连接"));const o=JSON.stringify(e);t("log","at utils/socket.js:193","发送的消息是:",o),this.ws.send({data:o,success:()=>a(),fail:e=>{t("error","at utils/socket.js:201","发送消息失败:",e),n(e)}})}))}reconnect(){this.reconnectTimer||(this.reconnectAttempts++,t("log","at utils/socket.js:227",`尝试重连 (${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.reconnectTimer=setTimeout((()=>{this.reconnectTimer=null,this.isManualClose||this.connect(this.options)}),this.reconnectDelay*this.reconnectAttempts))}startHeartbeat(){this.stopHeartbeat(),this.heartbeatTimer=setInterval((()=>{this.isConnected()?this.send({ws_event:"ping"}).catch((()=>{t("log","at utils/socket.js:249","心跳发送失败,准备重连"),this.reconnectTimer||this.isManualClose||this.reconnect()})):!this.isManualClose&&this.reconnectAttemptst("log","at utils/socket.js:335","连接已关闭"),fail:e=>t("error","at utils/socket.js:336","关闭失败:",e)})}catch(e){t("error","at utils/socket.js:344","关闭连接出错:",e)}this.ws=null}this.reconnectAttempts=0}updateOptions(e){this.options={...this.options,...e}}},W=U("socket",(()=>{const a=e.ref("disconnected"),n=e.ref([]),o=e.ref(""),l=e.ref(!1),s=e.ref({token:"",conversationId:""});e.ref("");const c=e.ref([]),i=e.ref(20),r=e.computed((()=>"connected"===a.value)),u=e.computed((()=>"connecting"===a.value)),d=e.computed((()=>"disconnected"===a.value)),m=e.computed((()=>"error"===a.value)),v=e.computed((()=>n.value[n.value.length-1]));function p(e,a){const n=new Date,o=`${n.getHours().toString().padStart(2,"0")}:${n.getMinutes().toString().padStart(2,"0")}:${n.getSeconds().toString().padStart(2,"0")}`;c.value.push({type:e,connect:a,time:o}),c.value.length>i.value&&(c.value=c.value.slice(-i.value)),t("log","at stores/socket.js:52",`[${e.toUpperCase()}] ${a}`)}function f(){a.value="connected",p("success","连接成功!发送auth"),t("log","at stores/socket.js:115","连接成功!发送auth"),s.value.token,q.send({type:"auth",access_token:s.value.token})}function h(){"disconnected"!==a.value&&(a.value="disconnected",p("warn","连接已断开"))}function g(e){p("error",`Socket错误: ${JSON.stringify(e)}`),a.value="error"}function w(e){a.value="connecting",p("warn",`重连中... (${e}/5)`)}function k(e){p("receive",`收到: ${JSON.stringify(e)}`);const{type:a,conversation_id:n,message_id:s,data:c}=e||{};switch(t("log","at stores/socket.js:160","[handleMessage] type =",a,", data =",JSON.stringify(c)),a){case"auth_ok":p("success","连接成功");break;case"chat_ack":p("warn","AI成功收到用户发送的消息");break;case"render":p("warn","AI正在回复信息"),function(e){if("exit"===e)return t("log","at stores/socket.js:212","ai结束思考"),void(l.value=!1);if(!e||"object"!=typeof e)return;const{role:a,chunk:n,message_role:s,meaasge_uuid:c,message_type:i,task_call_id:r}=e;l.value||!n&&"assistant"!==s||(t("log","at stores/socket.js:233","ai开始思考"),o.value="",l.value=!0);n&&(o.value+=n)}(c);break;default:p("info",`未知事件类型: ${a}`)}}return{connectionStatus:a,messageString:o,isThinking:l,logs:c,config:s,isConnected:r,isConnecting:u,isDisconnected:d,isError:m,lastMessage:v,connect:function(e={}){n.value=[],o.value="",s.value={...s.value,...e},p("info",`准备连接WebSocket。Token:${s.value.token||"未设置"}。ConversationId: ${s.value.conversationId||"未设置"}`),s.value.token&&s.value.conversationId?(a.value="connecting",q.connect({token:s.value.token,conversationId:s.value.conversationId,onMessage:k,onError:g,onOpen:f,onClose:h,onReconnect:w}),setTimeout((()=>{"connecting"===a.value&&(a.value="error",p("error","连接超时(10s)"))}),1e4)):p("error","Token和ConversationId都不能为空")},disconnect:function(){q.close(),a.value="disconnected",p("warn","已主动断开连接")},send:async function(e){if(t("log","at stores/socket.js:96","检查到要发生消息为:",e),!r.value)throw p("error","发送失败: 连接未建立"),new Error("连接未建立");try{return await q.send(e),p("send","string"==typeof e?e:JSON.stringify(e)),!0}catch(a){throw p("error",`发送失败: ${a.message||a}`),a}},addLog:p,clearLogs:function(){c.value=[]},getStatusText:function(){return{connecting:"连接中",connected:"已连接",disconnected:"未连接",error:"连接错误"}[a.value]||"未知状态"}}})),R="http://chat.yuxindazhineng.com",J=async e=>new Promise(((a,n)=>{uni.request({url:`${R}/api/chatList/getChatFriend`,method:"POST",header:{"Content-Type":"application/json"},data:{size:500,current:1,sendId:e},success:e=>{var o;if(200===e.statusCode){const l=e.data;if(t("log","at utils/friend-api.js:20","获取到的好友列表消息",l),0===(null==l?void 0:l.code)||"成功"===(null==l?void 0:l.msg)){const e=null==(o=l.data)?void 0:o.records;if(e.length>0){const t=e[0].receiver;t&&uni.setStorageSync("receiverId",t)}a(e)}else{const t=e.data.error||"获取好友列表出错啦";n(t)}}else n(`获取好友列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})),H=async e=>new Promise(((t,a)=>{uni.request({url:`${R}/api/group/getGroup`,method:"POST",header:{"Content-Type":"application/json"},data:{size:500,current:1,contactId:e},success:e=>{var n;if(200===e.statusCode){const o=e.data;if(0===(null==o?void 0:o.code)||"成功"===(null==o?void 0:o.msg)){const e=null==(n=o.data)?void 0:n.records;t(e)}else{const t=e.data.error||"获取群聊列表出错啦";a(t)}}else a(`获取群聊列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})),G=e=>new Promise(((t,a)=>{uni.uploadFile({url:`${R}/api/file/upload`,filePath:e,name:"file",success:e=>{const n=JSON.parse(e.data);0===n.code?t(n.data):a(n.msg||"上传失败")},fail:e=>{a(e.errMsg||"网络错误")}})}));const X=new class{constructor(){this.ws=null,this.url="wss://wss.yuxindazhineng.com/ws",this.options={token:"",UserId:"",onMessage:null,onError:null,onReconnect:null,onOpen:null,onClose:null},this.reconnectAttempts=0,this.maxReconnectAttempts=5,this.reconnectDelay=3e3,this.reconnectTimer=null,this.heartbeatTimer=null,this.isManualClose=!1}connect(e={}){this.options={...this.options,...e},this.isManualClose=!1,this.ws&&(t("log","at utils/friend-socket.js:37","关闭现有连接"),this.close());try{this.ws=uni.connectSocket({url:this.url,success:()=>{t("log","at utils/friend-socket.js:45","WebSocket 连接请求已发送")},fail:e=>{t("error","at utils/friend-socket.js:48","WebSocket 连接失败:",e),this.handleError(e)}}),this.initEventHandlers()}catch(a){this.handleError(a)}}initEventHandlers(){this.ws&&(this.ws.onOpen((e=>{var a,n,o,l;t("log","at utils/friend-socket.js:75","WebSocket 已连接"),this.reconnectAttempts>0&&(null==(n=(a=this.options).onReconnect)||n.call(a)),null==(l=(o=this.options).onOpen)||l.call(o,e),this.reconnectAttempts=0})),this.ws.onMessage((e=>{try{const a=JSON.parse(e.data);t("log","at utils/friend-socket.js:88","收到了返回消息:",a),this.handleMessage(a)}catch(a){t("error","at utils/friend-socket.js:91","消息解析失败:",a),uni.setStorageSync("currentSessionId",e.data.task_call_id)}})),this.ws.onError((e=>{t("error","at utils/friend-socket.js:96","WebSocket 错误:",JSON.stringify(e)),this.handleError(e)})),this.ws.onClose((e=>{var a,n;t("log","at utils/friend-socket.js:100","WebSocket 已关闭:",e.code,e.reason),null==(n=(a=this.options).onClose)||n.call(a,e),!this.isManualClose&&this.reconnectAttempts{if(!this.isConnected())return void n(new Error("WebSocket 未连接"));const o=JSON.stringify(e);t("log","at utils/friend-socket.js:171","发送的消息是:",o),this.ws.send({data:o,success:()=>a(),fail:e=>{t("error","at utils/friend-socket.js:179","发送消息失败:",e),n(e)}})}))}reconnect(){this.reconnectTimer||(this.reconnectAttempts++,t("log","at utils/friend-socket.js:205",`尝试重连 (${this.reconnectAttempts}/${this.maxReconnectAttempts})...`),this.reconnectTimer=setTimeout((()=>{this.reconnectTimer=null,this.isManualClose||this.connect(this.options)}),this.reconnectDelay*this.reconnectAttempts))}startHeartbeat(){this.stopHeartbeat(),this.heartbeatTimer=setInterval((()=>{this.isConnected()?this.send({ws_event:"ping"}).catch((()=>{t("log","at utils/friend-socket.js:227","心跳发送失败,准备重连"),this.reconnectTimer||this.isManualClose||this.reconnect()})):!this.isManualClose&&this.reconnectAttempts{})),this.ws.onMessage((()=>{})),this.ws.onError((()=>{})),this.ws.onClose((()=>{}));try{this.ws.close({success:()=>t("log","at utils/friend-socket.js:314","连接已关闭"),fail:e=>t("error","at utils/friend-socket.js:315","关闭失败:",e)})}catch(e){t("error","at utils/friend-socket.js:323","关闭连接出错:",e)}this.ws=null}this.reconnectAttempts=0}updateOptions(e){this.options={...this.options,...e}}},K=U("friendSocket",(()=>{const a=e.ref("disconnected"),n=e.ref([]),o=e.ref(""),l=e.ref({token:"",UserId:""});e.ref("");const s=e.ref(null),c=e.ref(null),i=e.ref(!1),r=e.ref([]),u=e.ref(20),d=e.computed((()=>"connected"===a.value)),m=e.computed((()=>"connecting"===a.value)),v=e.computed((()=>"disconnected"===a.value)),p=e.computed((()=>"error"===a.value)),f=e.computed((()=>n.value[n.value.length-1]));function h(e,a){const n=new Date,o=`${n.getHours().toString().padStart(2,"0")}:${n.getMinutes().toString().padStart(2,"0")}:${n.getSeconds().toString().padStart(2,"0")}`;r.value.push({type:e,connect:a,time:o}),r.value.length>u.value&&(r.value=r.value.slice(-u.value)),t("log","at stores/friend-socket.js:57",`[${e.toUpperCase()}] ${a}`)}function g(){a.value="connected",h("success","连接成功!"),async function(){const e={version:"1.1",body:{command:7,sender:N(),avatar:"",sessionId:"",message:"",callBackMessage:!1}};try{await X.send(e),h("send","string"==typeof e?e:JSON.stringify(e))}catch(t){throw h("error",`发送验证失败: ${t.message||t}`),t}}()}function w(){"disconnected"!==a.value&&(a.value="disconnected",h("warn","连接已断开"))}function k(e){h("error",`Socket错误: ${JSON.stringify(e)}`),a.value="error"}function y(e){a.value="connecting",h("warn",`重连中... (${e}/5)`)}function E(e){h("receive",`收到: ${JSON.stringify(e)}`);const a=e.body||e,{callBackMessage:n,groupName:o,command:l,groupId:r}=a||{};switch(l){case 3:s.value=l,c.value=r;break;case 7:s.value=l;break;case 1:t("log","at stores/friend-socket.js:199","有好友消息"),i.value=!0;break;case 9:t("log","at stores/friend-socket.js:204","群消息发送成功/有新群消息"),i.value=!0;break;default:h("info","未知事件类型")}}return{connectionStatus:a,messageString:o,logs:r,config:l,command:s,groupId:c,MessageReceived:i,isConnected:d,isConnecting:m,isDisconnected:v,isError:p,lastMessage:f,connect:function(e={}){n.value=[],o.value="",l.value={...l.value,...e},h("info",`准备连接FriendsWebSocket。Token:${l.value.token||"未设置"}。UserId: ${l.value.UserId||"未设置"}`),l.value.token&&l.value.UserId?(a.value="connecting",X.connect({token:l.value.token,UserId:l.value.UserId,onMessage:E,onError:k,onOpen:g,onClose:w,onReconnect:y}),setTimeout((()=>{"connecting"===a.value&&(a.value="error",h("error","连接超时(10s)"))}),1e4)):h("error","Token和UserId都不能为空")},disconnect:function(){X.close(),a.value="disconnected",h("warn","已主动断开连接")},send:async function(e){if(!d.value)throw h("error","发送失败: 连接未建立"),new Error("连接未建立");try{return await X.send(e),h("send","string"==typeof e?e:JSON.stringify(e)),!0}catch(t){throw h("error",`发送失败: ${t.message||t}`),t}},addLog:h,clearLogs:function(){r.value=[]},getStatusText:function(){return{connecting:"连接中",connected:"已连接",disconnected:"未连接",error:"连接错误"}[a.value]||"未知状态"}}})),{registerUTSInterface:Y,initUTSProxyClass:Q,initUTSProxyFunction:Z,initUTSPackageName:ee,initUTSIndexClassName:te,initUTSClassName:ae}=uni,ne="limeChooseFile",oe=Z(!1,{moduleName:"lime-choose-file 文件选择",moduleType:"",errMsg:"",main:!0,package:ee(ne,true),class:te(ne,true),name:"chooseFileByJs",keepAlive:!1,params:[{name:"options",type:"UTSSDKModulesLimeChooseFileChooseFileOptionJSONObject"}],return:""}),le=f({__name:"Chat",setup(l){const i=K(),r=()=>{i.isConnected||(Q.value&&Z.value?i.connect({token:Q.value,UserId:Z.value}):t("warn","at pages/Chat/Chat.vue:290","Token或UserId未准备好"))},u=W(),d=e.ref(0),m=(e,t)=>{let a='';return e.forEach(((e,n)=>{const o=0===n?"th":"td",l=e.split("|").filter((e=>""!==e.trim()));a+="",l.forEach(((e,n)=>{const l=t[n]?` style="text-align:${t[n]}"`:"";a+=`<${o}${l} style="padding:6px 10px;border:1px solid #ddd">${e.trim()}`})),a+=""})),a+="
    ",a},v=e=>{if(!e)return"";e=p(e);try{e=(e=>{const t=e.split("\n");let a=[],n=!1,o=[],l=[];for(let s=0;se.trim())).map((e=>e.trim().startsWith(":")&&e.trim().endsWith(":")?"center":e.trim().endsWith(":")?"right":"left"));continue}o.push(e),n=!0}else n&&o.length>0&&(a.push(m(o,l)),o=[],l=[],n=!1),a.push(e)}return n&&o.length>0&&a.push(m(o,l)),a.join("\n")})(e);return B(e)}catch(a){return t("error","at pages/Chat/Chat.vue:388","解析失败",a),e}},p=e=>{const t=/]*>([\s\S]*?)<\/script>/i.test(e),a=/<(form|input|select|textarea|button)\b[^>]*>/i.test(e);let n=e.replace(/]*>([\s\S]*?)<\/script>/gi,"");if(n=n.replace(/<\/?minimax:tool_call>/g,(e=>e.replace(//g,">"))).replace(/<\|[\w]+?\|>/g,(e=>e.replace(//g,">"))),t||a){return'

    表单仅预览,不可操作!!!

    '+n}return n},f=e=>{uni.previewImage({urls:[e]})},h=e=>{uni.downloadFile({url:e,success:e=>{uni.openDocument({filePath:e.tempFilePath,showMenu:!0})}})},g=e=>e?e<1?(1024*e).toFixed(0)+"KB":e.toFixed(2)+"MB":"0KB",E=e=>{if(!e||"string"!=typeof e)return{textContent:e||"",files:[]};const a=e.match(/\[文件信息:(\[.*?\])\]/);if(!a)return{textContent:e,files:[]};try{const t=JSON.parse(a[1]);return{textContent:e.replace(a[0],"").trim(),files:t}}catch(n){return t("error","at pages/Chat/Chat.vue:456","解析文件信息失败:",n),{textContent:e,files:[]}}},N=async()=>{try{const e="0123456789abcdef";let t="";for(let o=0;o<24;o++)t+=e[Math.floor(Math.random()*e.length)];const a=await(async(e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/create_workspace`,method:"POST",data:{access_token:e,name:t},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.workspace_id;if(t)a(t);else{const t=e.data.error||"创建工作区id出错啦";n(t)}}else n(`创建工作区id失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(Q.value,t);if(!a)return void uni.showToast({title:"工作区创建失败",icon:"none"});const n=uni.getStorageSync("yxd_login_info");let l="";n&&(l=n.username||"");const s=await(async(e,t,a,n)=>new Promise(((l,s)=>{uni.request({url:`${o}/create_conversation`,method:"POST",data:{access_token:e,workspace_id:t,title:a,sender:n},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data.conversation_id;if(t)l(t);else{const t=e.data.error||"创建新对话id出错啦";s(t)}}else s(`创建新对话失败:${e.statusCode}`)}})})))(Q.value,a,"新会话",l);if(!s)return void uni.showToast({title:"新会话创建失败",icon:"none"});ae()}catch(e){t("error","at pages/Chat/Chat.vue:498","新建普通会话失败:",e),uni.showToast({title:"创建会话失败,请重试",icon:"none"})}},b=e.ref(!1),V=()=>{b.value=!1},_=e.ref(!1),S=()=>{_.value=!_.value},x=()=>{Y.value&&uni.setStorageSync("currentSessionId",Y.value),uni.navigateTo({url:"/pages/WorkSpace/WorkSpace"})},T=()=>{Y.value&&uni.setStorageSync("currentSessionId",Y.value),uni.navigateTo({url:"/pages/CloudDatabase/CloudDatabase"})},D=()=>{uni.reLaunch({url:"/pages/Login/Login"})},j=e.ref([]),P=()=>{t("log","at pages/Chat/Chat.vue:547","点击了拍照上传"),uni.chooseImage({count:1,sourceType:["camera","album"],success:e=>{const t=e.tempFiles,a=e.tempFilePaths;t.forEach(((e,t)=>{j.value.push({path:a[t],name:e.name||`photo_${Date.now()}_${t}.jpg`,size:e.size,type:"image",tempFile:e})}))},fail:e=>{t("error","at pages/Chat/Chat.vue:565","选择图片失败",e)}})},$=e.ref([]),L=e.ref(!1),M=e.ref(!1),I=e.ref([]),z=async()=>{if(q.value.trim()||0!==j.value.length){if(j.value.length>0){M.value=!0,uni.showLoading({title:"上传文件中...",mask:!0});try{const e=[];for(const t of j.value){const a=await G(t.path);e.push(a)}I.value=e,j.value=[]}catch(e){return uni.hideLoading(),t("error","at pages/Chat/Chat.vue:671","文件上传失败:",e),uni.showToast({title:"文件上传失败,请重试",icon:"error"}),void(M.value=!1)}uni.hideLoading(),M.value=!1}0===d.value&&U(),1===d.value&&F(),2===d.value&&O()}},F=async()=>{i.isConnecting||await r();const e=uni.getStorageSync("receiverId"),t=I.value.length>0,a={command:1,sender:Z.value,receiver:e,avatar:"",sessionId:Y.value,message:q.value,callBackMessage:!1};t&&(a.contentType=1,a.uploadVos=I.value);const n={version:"1.1",body:a};i.send(n);const o={sender:Z.value,receiver:e,content:q.value,taskId:null,avatar:null,createTime:"",messageType:"null",contentJson:t?JSON.stringify(I.value):"null"};ue.value=[...ue.value,o],q.value="",I.value=[],setTimeout((()=>{fe()}),1e3)},O=async()=>{i.isConnecting||await r();const e=I.value.length>0,t={command:9,groupId:Y.value,message:q.value||"",callBackMessage:!e,messageType:e?1:0,sender:Z.value};e&&(t.uploadVos=I.value);const a={version:"1.1",body:t};i.send(a);const n={id:ue.value.length+1,message:q.value,messageType:e?1:0,groupId:null,createTime:"",contentJson:e?JSON.stringify(I.value):"",sender:Z.value};ue.value=[...ue.value,n],q.value="",I.value=[],setTimeout((()=>{he()}),1e3)};let A=null;const U=async()=>{try{await new Promise(((t,a)=>{if(u.isConnected)return t();const n=e.watch((()=>u.isConnected),(e=>{e&&(n(),t())})),o=e.watch((()=>u.connectionStatus),(e=>{"error"===e&&(n(),o(),a(new Error("连接失败")))}));u.connect({token:Q.value,conversationId:Y.value})}));let t=q.value;if(I.value.length){const e=JSON.stringify(I.value);t=t?`${t}\n[文件信息:${e}]`:`[文件信息:${e}]`}const a={type:"chat",conversation_id:Y.value,content:t};u.send(a),L.value=!0,A=setTimeout((()=>{uni.showToast({title:"AI回复超时,请重试",icon:"none"}),L.value=!1,q.value="",I.value=[]}),18e4)}catch(t){L.value=!1,uni.showToast({title:`用户发送消息失败${t}`,icon:"error"})}};e.watch((()=>u.isThinking),((e,a)=>{t("log","at pages/Chat/Chat.vue:833","isThinking 变化:",a,"→",e),a&&!e&&u.messageString&&(clearTimeout(A),t("log","at pages/Chat/Chat.vue:837","ai返回的消息:",u.messageString),t("log","at pages/Chat/Chat.vue:838","AI回复结束,刷新消息列表"),pe(),L.value=!1,q.value="",I.value=[])}));const q=e.ref(""),X=e.ref([]),Y=e.ref(""),Q=e.ref(""),Z=e.ref(""),ee=e.ref(""),te=e.ref(null),ae=async()=>{try{Q.value=k(),t("log","at pages/Chat/Chat.vue:874","token:",Q.value),X.value=await(async e=>new Promise(((t,a)=>{uni.request({url:`${o}/get_user_conversations`,method:"POST",data:{access_token:e},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const a=e.data.conversations;t(a)}else a(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(Q.value)||[];const e=y();e&&X.value.some((t=>t._id===e))?Y.value=e:X.value.length>0?Y.value=X.value[0]._id:Y.value="",t("log","at pages/Chat/Chat.vue:886","保存会话id:",Y.value),uni.setStorageSync("currentSessionId",Y.value)}catch(e){uni.showToast({title:`获取会话列表失败${e}`,icon:"error"})}},ne=e.ref([]),le=e=>{if(!e)return null;const t=ne.value.find((t=>t.receiver===e));return(null==t?void 0:t.avatar)||null},se=async e=>{if(!(null==e?void 0:e.length))return[];try{const t=e.map((e=>e.receiver)),a=await c(Q.value,t),n=new Map(a.map((e=>[e.user_id,e]))||[]);return e.map((e=>{const t=n.get(e.receiver);return{...e,avatar:(null==t?void 0:t.avatar)||null}}))}catch(a){return t("error","at pages/Chat/Chat.vue:942","获取好友头像失败",a),e}},ce=e.ref([]),ie=e.ref([]),re=e=>{if(!e)return null;const t=ie.value.find((t=>t.groupContactId===e));return(null==t?void 0:t.avatar)||null},ue=e.ref([]),de=e.ref("");e.ref(!1);const me=e.ref(1),ve=e.computed((()=>ue.value.slice(-100))),pe=async()=>{try{ue.value=await(async(e,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/get_conversation_messages`,method:"POST",data:{access_token:e,conversation_id:a},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const a=e.data;if(a)t("log","at utils/cloud-api.js:88","工作区id为:",a.workspace_id||"(无)"),a.workspace_id&&uni.setStorageSync("workspace_id",a.workspace_id),n(a.messages);else{const t=e.data.error||"获取消息出错啦";l(t)}}else l(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(Q.value,Y.value)||[],ke()}catch(e){uni.showToast({title:`获取ai会话内容失败${e}`,icon:"none"})}},fe=async()=>{try{ue.value=await(async(e,a=1)=>(t("log","at utils/friend-api.js:88","请求的好友消息id:",e),new Promise(((t,n)=>{uni.request({url:`${R}/api/message/list`,method:"POST",data:{sessionId:e,size:100,current:a,beginTime:"",endTime:""},header:{"Content-Type":"application/json"},success:e=>{var a;if(200===e.statusCode){const o=e.data;if(0===o.code){const e=((null==(a=null==o?void 0:o.data)?void 0:a.records)||[]).reverse();t(e)}else{const t=e.data.error||"获取好友消息出错啦";n(t)}}else n(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})}))))(Y.value)||[],t("log","at pages/Chat/Chat.vue:1033","好友消息:",JSON.stringify(ue.value)),ke()}catch(e){uni.showToast({title:`获取好友会话消息失败${e}`,icon:"none"})}},he=async()=>{try{ue.value=await(async(e,a=1)=>(t("log","at utils/friend-api.js:134","请求的群聊消息id:",e),new Promise(((n,o)=>{uni.request({url:`${R}/api/group/getGroupList`,method:"POST",data:{current:a,size:100,groupId:e,beginTime:"",endTime:""},header:{"Content-Type":"application/json"},success:e=>{var a;if(200===e.statusCode){const l=e.data;if(t("log","at utils/friend-api.js:152","获取到的群聊信息:",l),0===l.code){const e=((null==(a=null==l?void 0:l.data)?void 0:a.records)||[]).reverse();n(e)}else{const t=e.data.error||"获取群聊消息出错啦";o(t)}}else o(`请求失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";o(t)}})}))))(Y.value)||[],t("log","at pages/Chat/Chat.vue:1046","群聊消息:",ue.value);const e=await(async e=>new Promise(((t,a)=>{uni.request({url:`${R}/api/group/getGroupMemberList`,method:"POST",header:{"Content-Type":"application/json"},data:{groupId:e,current:1,size:100},success:e=>{if(200===e.statusCode){const n=e.data;if(0===n.code){const e=n.data.records;t(e)}else{const t=e.data.error||"获取群成员出错啦";a(t)}}else a(`请求群成员失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(Y.value);t("log","at pages/Chat/Chat.vue:1049","获取到的群成员列表:",e),e&&e.length?(ie.value=await(async e=>{if(!(null==e?void 0:e.length))return[];try{const a=e.map((e=>e.groupContactId));t("log","at pages/Chat/Chat.vue:971","请求头像的ID列表:",a);const n=await c(Q.value,a);t("log","at pages/Chat/Chat.vue:973","头像接口返回数据:",n);const o=new Map(n.map((e=>[e.user_id,e]))||[]);return t("log","at pages/Chat/Chat.vue:976","userMap的keys:",Array.from(o.keys())),e.map((e=>{const a=e.groupContactId,n=o.get(a);return t("log","at pages/Chat/Chat.vue:981",`查找 ${a} 的头像:`,n),{...e,avatar:(null==n?void 0:n.avatar)||null}}))}catch(a){return t("error","at pages/Chat/Chat.vue:988","获取群成员头像失败",a),e}})(e),t("log","at pages/Chat/Chat.vue:1052","群成员列表(带头像):",ie.value)):ie.value=[],ke()}catch(e){uni.showToast({title:`获取群聊会话失败${e}`,icon:"none"})}},ge=async()=>{if(t("log","at pages/Chat/Chat.vue:1067","加载更多信息"),ue.value.length>100*me.value){me.value+=1;const t=ue.value.slice(-100*me.value),a=t.length-ve.value.length;ve.value=t,await e.nextTick(),de.value="msg-"+(a+1)}},we=e=>{},ke=async()=>{await e.nextTick(),ve.value.length>0&&(de.value="msg-"+(ve.value.length-1))};return e.watch((()=>i.MessageReceived),(e=>{if(t("log","at pages/Chat/Chat.vue:1095","收到了好友消息"),e)switch(t("log","at pages/Chat/Chat.vue:1097","ChatType:",d.value),d.value){case 0:pe(),i.MessageReceived=!1;break;case 1:fe(),i.MessageReceived=!1;break;case 2:he(),i.MessageReceived=!1;break;default:t("log","at pages/Chat/Chat.vue:1113","default 分支"),i.MessageReceived=!1}}),{immediate:!0}),e.watch(Y,(e=>{if(e)switch(uni.setStorageSync("currentSessionId",Y.value),d.value){case 0:default:pe();break;case 1:fe();break;case 2:he()}}),{immediate:!0}),e.onMounted((()=>{})),n((async()=>{await(async()=>{try{Q.value=k(),te.value=await s(Q.value),Z.value=te.value._id,ee.value=te.value.avatar||"",t("log","at pages/Chat/Chat.vue:864","用户信息已加载:",Z.value,ee.value)}catch(e){t("error","at pages/Chat/Chat.vue:866","获取用户信息失败:",e)}})();const e=uni.getStorageSync("chatType");d.value=e;const a=y();a&&(Y.value=a),0===e?(await ae(),Y.value&&pe()):1===e?(await(async()=>{try{t("log","at pages/Chat/Chat.vue:901","开始获取好友列表");const e=await J(Z.value);t("log","at pages/Chat/Chat.vue:904","friendList:",e),e&&e.length?ne.value=await se(e):(ne.value=[],t("log","at pages/Chat/Chat.vue:909","好友列表为空"))}catch(e){t("error","at pages/Chat/Chat.vue:912","获取好友列表失败:",e),ne.value=[]}finally{X.value=ne.value}})(),fe(),r()):2===e&&(await(async()=>{try{t("log","at pages/Chat/Chat.vue:952","开始获取群聊列表"),ce.value=await H(Z.value)}catch(e){t("error","at pages/Chat/Chat.vue:957","获取群聊列表失败:",e),ce.value=[]}finally{X.value=ce.value}})(),await r(),await he())})),(n,o)=>{const l=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),b.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"ncd-overlay",onClick:V},[e.createElementVNode("view",{class:"ncd-card",onClick:o[0]||(o[0]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"ncd-header"},[e.createElementVNode("view",{class:"ncd-title-eng"},[e.createElementVNode("text",null,"NEW")]),e.createElementVNode("text",{class:"ncd-title-zh"},"创建对话"),e.createVNode(l,{type:"closeempty",color:"#ff0000",size:"24",onClick:V})]),e.createElementVNode("text",null,"选择对话类型,开启全新会话体验"),e.createElementVNode("view",{class:"ncd-options"},[e.createElementVNode("view",{class:"ncd-option ncd-normal"},[e.createElementVNode("view",{class:"ncd-opt-icon"},[e.createVNode(l,{type:"chat",color:"#000000",size:"30"})]),e.createElementVNode("view",{class:"ncd-opt-title",onClick:N},[e.createElementVNode("view",{class:"ncd-opt-title-1"},"普通会话"),e.createElementVNode("view",{class:"ncd-opt-title-2"},"与AI自由对话,探索任何话题")]),e.createVNode(l,{type:"arrow-right",class:"arrow-right-style"})]),e.createElementVNode("view",{class:"ncd-option ncd-intelligence"},[e.createElementVNode("view",{class:"ncd-opt-icon"},[e.createVNode(l,{type:"star",color:"#ffffff",size:"30"})]),e.createElementVNode("view",{class:"ncd-opt-title"},[e.createElementVNode("view",{class:"ncd-opt-title-1"},"智能体会话"),e.createElementVNode("view",{class:"ncd-opt-title-2"},"选择专属智能体,获得精准专业服务")]),e.createVNode(l,{type:"arrow-right",class:"arrow-right-style"})])])])])):e.createCommentVNode("",!0),L.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"ncd-overlay",onClick:V},[e.createElementVNode("view",{class:"ncd-card ai-card",onClick:o[1]||(o[1]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"thinking-content"},[e.createElementVNode("view",{class:"loading-dots"},[e.createElementVNode("view",{class:"dot"}),e.createElementVNode("view",{class:"dot"}),e.createElementVNode("view",{class:"dot"})]),e.createElementVNode("text",{class:"thinking-text"},"AI 正在思考中...")])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"chat-page page-container"},[_.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"mask",onClick:S})):e.createCommentVNode("",!0),e.createElementVNode("view",{class:e.normalizeClass(["chat-sidebar",{"sidebar-show":_.value}])},[e.createVNode(C,{chatList:X.value,showNewChatModal:b.value,"onUpdate:showNewChatModal":o[2]||(o[2]=e=>b.value=e),currentSessionId:Y.value,"onUpdate:currentSessionId":o[3]||(o[3]=e=>Y.value=e),chatType:d.value,"onUpdate:chatType":o[4]||(o[4]=e=>d.value=e),onRefreshConversations:ae},null,8,["chatList","showNewChatModal","currentSessionId","chatType"])],2),e.createElementVNode("view",{class:"chat-wrapper"},[e.createElementVNode("view",{class:"chat-hearder"},[e.createElementVNode("view",{class:"chat-btn-group"},[e.createElementVNode("view",{class:"head-btn",onClick:S},[e.createElementVNode("view",{class:"iconfont icon-caidan"})]),e.createElementVNode("view",{class:"head-btn",onClick:x},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"})]),e.createElementVNode("view",{class:"head-btn",onClick:T},[e.createElementVNode("view",{class:"iconfont icon-cloud"})]),e.createElementVNode("view",{class:"head-btn log-out",onClick:D},[e.createElementVNode("view",{class:"iconfont icon-tuichu"})])])]),e.createElementVNode("view",{class:"main-chat"},[e.createElementVNode("scroll-view",{class:"chat-messages",direction:"vertical","scroll-y":"","scroll-into-view":de.value,onScrolltoupper:ge,"upper-threshold":0,"scroll-with-animation":!0,onScroll:we},[0===d.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(ve.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":"user"===t.role}]),key:a,id:"msg-"+a},["user"===t.role?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":"user"===t.role}])},["user"===t.role&&(null==(n=te.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:te.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"iconfont icon-yonghuziliao"}))],2)):e.createCommentVNode("",!0),t.content&&""!==String(t.content).trim()?(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["chat-content",{"chat-content-user":"user"===t.role}])},[E(t.content).textContent?(e.openBlock(),e.createElementBlock("view",{key:0,innerHTML:v(E(t.content).textContent)},null,8,["innerHTML"])):e.createCommentVNode("",!0),E(t.content).files.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E(t.content).files,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"file-item"},[["jpg","jpeg","png","gif","webp","bmp"].includes(t.extendName.toLowerCase())?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.url,mode:"widthFix",class:"message-image",onClick:e=>f(t.url)},null,8,["src","onClick"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file",onClick:e=>h(t.url)},[e.createElementVNode("view",{class:"file-icon"},"📄"),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-size"},e.toDisplayString(g(t.fileSize)),1)],8,["onClick"]))])))),128))])):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],10,["id"])})),128)):e.createCommentVNode("",!0),1===d.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(ve.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":t.sender===Z.value}]),key:a,id:"msg-"+a},[e.createElementVNode("view",{class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":t.sender===Z.value}])},[t.sender===Z.value&&(null==(n=te.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:te.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):le(t.sender)?(e.openBlock(),e.createElementBlock("image",{key:1,src:le(t.sender),class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"iconfont icon-yonghuziliao"}))],2),e.createElementVNode("view",{class:e.normalizeClass(["chat-content",{"chat-content-user":t.sender===Z.value}])},[t.content&&""!==String(t.content).trim()?(e.openBlock(),e.createElementBlock("view",{key:0,innerHTML:v(t.content)},null,8,["innerHTML"])):e.createCommentVNode("",!0),t.contentJson?(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(JSON.parse(t.contentJson),((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"file-item"},[["jpg","jpeg","png","gif","webp","bmp"].includes(t.extendName.toLowerCase())?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.url,mode:"widthFix",class:"message-image",onClick:e=>f(t.url)},null,8,["src","onClick"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file",onClick:e=>h(t.url)},[e.createElementVNode("view",{class:"file-icon"},"📄"),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-size"},e.toDisplayString(g(t.fileSize)),1)],8,["onClick"]))])))),128))])):e.createCommentVNode("",!0)],2)],10,["id"])})),128)):e.createCommentVNode("",!0),2===d.value?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(ve.value,((t,a)=>{var n;return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["chat-message",{"message-user":t.sender===Z.value}]),key:a,id:"msg-"+a},[e.createElementVNode("view",{class:e.normalizeClass(["chat-avatar",{"chat-avatar-user":t.sender===Z.value}])},[t.sender===Z.value&&(null==(n=te.value)?void 0:n.avatar)?(e.openBlock(),e.createElementBlock("image",{key:0,src:te.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):ie.value.length>0&&re(t.sender)?(e.openBlock(),e.createElementBlock("image",{key:1,src:re(t.sender),class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"iconfont icon-yonghuziliao"}))],2),e.createElementVNode("view",{class:e.normalizeClass(["chat-content",{"chat-content-user":t.sender===Z.value}])},[t.message&&""!==String(t.message).trim()?(e.openBlock(),e.createElementBlock("view",{key:0,innerHTML:v(t.message)},null,8,["innerHTML"])):e.createCommentVNode("",!0),t.contentJson?(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(JSON.parse(t.contentJson),((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:"file-item"},[["jpg","jpeg","png","gif","webp","bmp"].includes(t.extendName.toLowerCase())?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.url,mode:"widthFix",class:"message-image",onClick:e=>f(t.url)},null,8,["src","onClick"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"message-file",onClick:e=>h(t.url)},[e.createElementVNode("view",{class:"file-icon"},"📄"),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-size"},e.toDisplayString(g(t.fileSize)),1)],8,["onClick"]))])))),128))])):e.createCommentVNode("",!0)],2)],10,["id"])})),128)):e.createCommentVNode("",!0)],40,["scroll-into-view"]),e.createElementVNode("view",{class:"chat-interactive-container"},[e.createElementVNode("view",{class:"chat-interactive-group"},[e.createElementVNode("view",{class:"chat-interactive-btn",onClick:P},"拍照上传"),e.createElementVNode("view",{class:"chat-interactive-btn",onClick:o[5]||(o[5]=e=>(t("log","at pages/Chat/Chat.vue:588","点击了上传文件"),void oe({count:5,type:"all",success:e=>{t("log","at pages/Chat/Chat.vue:593","成功了"),$.value=e.tempFiles,j.value.push(...e.tempFiles),uni.showToast({title:`已选择 ${e.tempFiles.length} 个文件`,icon:"success"})},fail:e=>{t("error","at pages/Chat/Chat.vue:604","选择失败:",e),uni.showToast({title:"选择失败",icon:"error"})}})))},"上传文件")]),j.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"image-list"},[e.createElementVNode("view",{class:"image-title"},"已选择: ("+e.toDisplayString(j.value.length)+")",1),e.createElementVNode("view",{class:"image-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(j.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"image-item",key:a},[e.createElementVNode("view",{class:"image-info"},[e.createElementVNode("text",{class:"image-name"},e.toDisplayString(t.name),1),e.createElementVNode("text",{class:"delete-btn",onClick:e.withModifiers((e=>(e=>{uni.showModal({title:"提示",content:"确定要删除这张图片吗?",success:t=>{t.confirm&&(j.value.splice(e,1),uni.showToast({title:"删除成功",icon:"success"}))}})})(a)),["stop"])},"删除",8,["onClick"])])])))),128))])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"chat-input-container"},[e.withDirectives(e.createElementVNode("textarea",{class:"message-input",placeholder:"输入消息...",onConfirm:z,"confirm-type":"send","onUpdate:modelValue":o[6]||(o[6]=e=>q.value=e),"auto-height":""},null,544),[[e.vModelText,q.value]]),e.createElementVNode("view",{class:"input-btn-group"},[e.createElementVNode("view",{class:"iconfont icon-tingzhi icon-btn"})])])])])])])],64)}}},[["__scopeId","data-v-92a1a532"]]),se=f({__name:"WorkSpace",setup(n){const l=e.ref(""),s=e.ref(""),c=e.ref(""),i=e.ref("工作区"),d=e.ref(!1),m=e.ref([]),v=e.ref(!1),p=e.ref(!1),f=e.ref(""),h=()=>{v.value=!1,f.value=""},g=()=>{oe({count:10,type:"all",success:async e=>{const t=e.tempFiles||[];0!==t.length?await y(t):uni.showToast({title:"未选择文件",icon:"none"})},fail:e=>{t("error","at pages/WorkSpace/WorkSpace.vue:176","选择文件失败:",e)}})},y=async e=>{uni.showLoading({title:"上传中..."});try{const a=M.value.length>0?"./"+M.value.map((e=>e.name)).join("/")+"/":"/",n=await((e,a,n)=>new Promise(((l,s)=>{const c=(Array.isArray(a)?a:[a]).map((e=>({name:"files",uri:"string"==typeof e?e:e.tempFilePath||e.path||e})));t("log","at utils/cloud-api.js:587","uploadFileToShortStorage 参数:",{workspacesId:e,fileCount:c.length,filePath:n}),uni.uploadFile({url:`${o}/cloud_api/file/temp/upload`,method:"POST",formData:{workspaces_id:e,file_path:n||"/",overwrite:"true"},files:c,success:e=>{if(t("log","at utils/cloud-api.js:599","uploadFileToShortStorage 响应状态:",e.statusCode,"数据:",e.data),200===e.statusCode)try{const t=JSON.parse(e.data);if(Array.isArray(t)&&t.length>0)l(t);else if(t.success)l([{url:t.url||t.message,success:!0}]);else{const e=(null==t?void 0:t.error)||(null==t?void 0:t.message)||"上传文件(到短存云端)获取URL出错啦";s(e)}}catch(a){s("接口返回数据格式异常: "+e.data)}else s(`上传文件(到短存云端)获取URL失败:${e.statusCode} - ${e.data}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})))(s.value,e,a),c=n.filter((e=>e.success)).map((e=>e.url));if(0===c.length){const e=n.filter((e=>!e.success)).map((e=>e.error)).join("; ");throw new Error(e||"所有文件上传失败")}await((e,t,a,n)=>new Promise(((l,s)=>{const c=Array.isArray(a)?a:a?[a]:[];uni.request({url:`${o}/cloud_api/phone/workspace/upload`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,workspaces_id:t,dir_path:n||"/",urls:c},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)l(t);else{const e=(t.results||[]).filter((e=>!e.success)).map((e=>e.error||"未知错误")),a=e.length>0?`上传失败 ${t.failed_count}/${t.total_files}:${e[0]}`:t.summary||(null==t?void 0:t.error)||"上传文件到工作区出错啦";s(a)}}else s(`上传文件到工作区失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})))(l.value,s.value,c,a),uni.hideLoading();const i=e.length,r=i-c.length,u=r>0?`上传完成:成功 ${c.length},失败 ${r}`:`成功上传 ${i} 个文件`;uni.showToast({title:u,icon:c.length>0?"success":"error"}),F()}catch(a){uni.hideLoading(),t("error","at pages/WorkSpace/WorkSpace.vue:229","上传文件失败:",a),uni.showToast({title:"string"==typeof a?a:"上传失败,请重试",icon:"error"})}},E=e.computed((()=>0===M.value.length?"根目录":"/"+M.value.map((e=>e.name)).join("/"))),N=e.computed((()=>{const e=M.value.map((e=>e.name)).join("/"),t=f.value.trim();return t?e?`./${e}/${t}`:`./${t}`:e?`./${e}/`:"./"})),C=async()=>{const e=f.value.trim();if(e)try{const t=M.value.map((e=>e.name)).join("/"),a=t?`./${t}/${e}`:`./${e}`;await u(l.value,s.value,a),uni.showToast({title:"创建成功",icon:"success"}),h(),F()}catch(a){t("error","at pages/WorkSpace/WorkSpace.vue:275","创建文件夹失败:",a),uni.showToast({title:"创建失败,请重试",icon:"error"})}else uni.showToast({title:"请输入目录名称",icon:"none"})},b=async e=>{var a,n,c;if("directory"!==e.type)try{uni.showLoading({title:"获取下载链接..."});const i=e.path.startsWith("./")?e.path.slice(2):e.path,r=await(a=l.value,n=s.value,c=i,new Promise(((e,t)=>{uni.request({url:`${o}/cloud_api/phone/workspace/downloadFile`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:a,workspaces_id:n,file_path:c},success:a=>{if(200===a.statusCode){const n=a.data;if(n.success)e(n.message||n.data);else if(Array.isArray(n))e(n);else{const e=(null==n?void 0:n.error)||"获取工作区文URL出错啦";t(e)}}else t(`获取工作区文URL失败:${a.statusCode}`)}})})));uni.hideLoading();const u=Array.isArray(r)?r[0]:r;if(!u||!u.url)return void uni.showToast({title:"获取下载链接失败",icon:"error"});const d=u.url,m=e.name;uni.showLoading({title:"下载中..."}),uni.downloadFile({url:d,name:m,success:e=>{if(uni.hideLoading(),200===e.statusCode){const t=e.tempFilePath;V(m,t)}else uni.showToast({title:"下载失败",icon:"error"})},fail:e=>{uni.hideLoading(),t("error","at pages/WorkSpace/WorkSpace.vue:406","下载文件失败:",e),uni.showToast({title:"下载失败,请重试",icon:"error"})}})}catch(i){uni.hideLoading(),t("error","at pages/WorkSpace/WorkSpace.vue:415","获取下载链接失败:",i),uni.showToast({title:"获取下载链接失败,请重试",icon:"error"})}else uni.showToast({title:"暂不支持下载目录",icon:"none"})},V=(e,a)=>{const n="/storage/emulated/0/yxd/";var o;o=o=>{plus.io.resolveLocalFileSystemURL(a,(l=>{l.copyTo(o,e,(()=>{const a=n+e;t("log","at pages/WorkSpace/WorkSpace.vue:464","文件已保存到:",a),_(e,a)}),(n=>{t("error","at pages/WorkSpace/WorkSpace.vue:468","复制文件失败:",JSON.stringify(n)),_(e,a)}))}),(n=>{t("error","at pages/WorkSpace/WorkSpace.vue:473","读取临时文件失败:",JSON.stringify(n)),_(e,a)}))},plus.io.resolveLocalFileSystemURL(n,(e=>{o(e)}),(()=>{plus.io.resolveLocalFileSystemURL("/storage/emulated/0/",(n=>{n.getDirectory("yxd",{create:!0},(e=>{o(e)}),(n=>{t("error","at pages/WorkSpace/WorkSpace.vue:439","创建 yxd 目录失败:",JSON.stringify(n)),uni.showToast({title:"创建目录失败",icon:"error"}),_(e,a)}))}),(n=>{t("error","at pages/WorkSpace/WorkSpace.vue:447","访问外部存储根目录失败:",JSON.stringify(n)),uni.showToast({title:"无法访问存储目录",icon:"error"}),_(e,a)}))}))},_=(e,t)=>{uni.showActionSheet({title:`${e} 下载完成`,itemList:["打开文件","选择其他应用打开","仅保存"],success:e=>{switch(e.tapIndex){case 0:B(t);break;case 1:S(t);break;case 2:uni.showToast({title:"文件已保存到 yxd 目录",icon:"success"})}},fail:()=>{uni.showToast({title:"文件已保存到 yxd 目录",icon:"success"})}})},B=e=>{uni.openDocument({filePath:e,success:()=>uni.showToast({title:"打开成功",icon:"success"}),fail:e=>{t("error","at pages/WorkSpace/WorkSpace.vue:530","打开文件失败:",e),uni.showToast({title:"无法打开此文件",icon:"error"})}})},S=e=>{uni.openDocument({filePath:e,showMenu:!0,success:()=>uni.showToast({title:"打开成功",icon:"success"}),fail:e=>{t("error","at pages/WorkSpace/WorkSpace.vue:549","打开文件失败:",e),uni.showToast({title:"无法打开此文件",icon:"error"})}})},x=e=>{uni.showModal({title:"提示",content:`确定要删除"${e.name}"吗?`,success:async a=>{if(a.confirm)try{const a=`./${e.path}`;t("log","at pages/WorkSpace/WorkSpace.vue:568","删除的是:",a),await r(l.value,s.value,a),uni.showToast({title:"删除成功",icon:"success"}),F()}catch(n){t("error","at pages/WorkSpace/WorkSpace.vue:576","删除失败:",n),uni.showToast({title:"删除失败,请重试",icon:"error"})}}})},T=e.ref(!1),D=()=>{T.value=!T.value},j=e.ref(""),P=e.ref(!1),$=()=>{P.value=!P.value},L=e.ref({}),M=e.ref([]),I=e.ref([]),z=()=>{var e,a;t("log","at pages/WorkSpace/WorkSpace.vue:657","当前路径为:",JSON.stringify(M.value));const n=M.value.length>0?M.value[M.value.length-1].path:".";if("."===n)return(null==(e=L.value)?void 0:e.children)||[];const o=(e,t)=>{var a;for(const n of e){if(n.path===t)return n;if("directory"===n.type&&(null==(a=n.children)?void 0:a.length)){const e=o(n.children,t);if(e)return e}}return null},l=o((null==(a=L.value)?void 0:a.children)||[],n);return l?l.children:[]},F=async()=>{var e,a;s.value=uni.getStorageSync("workspace_id"),l.value=k(),t("log","at pages/WorkSpace/WorkSpace.vue:684","getWorkspaceId:",s.value),L.value=await(e=l.value,a=s.value,new Promise(((t,n)=>{uni.request({url:`${o}/cloud_api/phone/workspace/list`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,workspaces_id:a,format:"tree",parent_path:"",filter_type:""},success:e=>{if(200===e.statusCode){const a=e.data;if(a.success)t(a.data);else{const e=(null==a?void 0:a.error)||"获取工作区文件目录出错啦";n(e)}}else n(`获取工作区文件目录失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})}))),I.value=z()},O=()=>{d.value?m.value.length===I.value.length?m.value=[]:m.value=I.value.map((e=>e.path)):M.value.length>0?(M.value.pop(),0===M.value.length?(i.value="工作区",c.value=null):(i.value=M.value[M.value.length-1].name,c.value=M.value.length>1?M.value[M.value.length-2].name:"工作区"),F(),j.value="",P.value=!1):uni.navigateBack({delta:1,fail(){t("log","at pages/WorkSpace/WorkSpace.vue:741","返回失败,进入兜底跳转"),uni.reLaunch({url:"/pages/Chat/Chat"})}})};return e.onMounted((()=>{F()})),(t,n)=>{const o=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-overlay",onClick:h},[e.createElementVNode("view",{class:"popup-card",onClick:n[3]||(n[3]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:h},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"新建工作区目录"),e.createElementVNode("view",{class:"new-folder-name"},"目录名称"),e.createElementVNode("view",{class:e.normalizeClass(["create-folder-name",{"has-value":p.value||f.value}])},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[0]||(n[0]=e=>f.value=e),onFocus:n[1]||(n[1]=e=>p.value=!0),onBlur:n[2]||(n[2]=e=>p.value=!1),type:"text",placeholder:"输入目录名称,如:项目资料/设计图"},null,544),[[e.vModelText,f.value]])],2),e.createElementVNode("view",{class:"nf-path-label"},"当前路径"),e.createElementVNode("view",{class:"nf-path-display"},e.toDisplayString(E.value),1),e.createElementVNode("view",{class:"nf-path-label"},"路径预览"),e.createElementVNode("view",{class:"nf-path-preview"},e.toDisplayString(N.value),1),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:h},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:C},"确认")])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"workspace-container page-container"},[e.createElementVNode("view",{class:"workspace-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:n[4]||(n[4]=(...e)=>O&&O(...e))},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"}),e.createElementVNode("view",{class:"navbar-before-title workspace-text"},e.toDisplayString(d.value?"全选":c.value),1)]),e.createElementVNode("view",{class:"navbar-title workspace-text"},e.toDisplayString(i.value),1),e.createElementVNode("view",{class:"navbar-right"},[d.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right-text workspace-text",onClick:n[5]||(n[5]=e=>(d.value&&(m.value=[]),void(d.value=!d.value)))}," 完成")):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["iconfont icon-gengduo",T.value?"menu-open":"custom-navbar-icon"]),onClick:D},null,2))]),T.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:n[6]||(n[6]=e=>{g(),D()})},"上传文件"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item",onClick:n[7]||(n[7]=e=>{v.value=!0,D()})},"新建文件夹")])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"search-file-warpper"},[e.createElementVNode("view",{class:"search-file"},[e.createElementVNode("view",{class:"iconfont icon-sousuo"}),e.withDirectives(e.createElementVNode("input",{class:"search-file-input",placeholder:"搜索",onFocus:$,"onUpdate:modelValue":n[8]||(n[8]=e=>j.value=e)},null,544),[[e.vModelText,j.value]])]),P.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"cancel-search",onClick:$},"取消")):e.createCommentVNode("",!0)])]),e.createElementVNode("view",{class:"workspace-content"},[0===I.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createTextVNode(" 文件夹为空 ")])):e.createCommentVNode("",!0),I.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"folder-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(t=>{return e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["folder-item",{"select-folder":m.value.includes(t.path)}]),key:t.path,onClick:e=>d.value?(e=>{const t=m.value.indexOf(e);-1!==t?m.value.splice(t,1):m.value.push(e)})(t.path):(e=>{"directory"===e.type&&(M.value.push({path:e.path,name:e.name}),i.value=e.name,c.value=M.value.length>1?M.value[M.value.length-2].name:"工作区",I.value=z(),j.value="",P.value=!1)})(t),onLongpress:e=>(e=>{d.value||uni.showActionSheet({itemList:["下载","删除"],success:t=>{switch(t.tapIndex){case 0:b(e);break;case 1:x(e)}}})})(t)},["directory"===t.type?(e.openBlock(),e.createElementBlock("view",{key:0,class:"iconfont icon-a-wenjianjiawenjian folder-item-style"})):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["iconfont folder-item-style",(a=t.extension,{".png":"icon-wenjiantupian",".jpg":"icon-wenjiantupian",".jpeg":"icon-wenjiantupian",".gif":"icon-wenjiantupian",".svg":"icon-SVG",".bmp":"icon-wenjiantupian",".webp":"icon-wenjiantupian",".mp4":"icon-wenjianshipin",".avi":"icon-wenjianshipin",".mov":"icon-wenjianshipin",".wmv":"icon-wenjianshipin",".flv":"icon-wenjianshipin",".mkv":"icon-wenjianshipin",".mp3":"icon-wenjianyinpin",".wav":"icon-wenjianyinpin",".flac":"icon-wenjianyinpin",".aac":"icon-wenjianyinpin",".pdf":"icon-PDF",".doc":"icon-DOC",".docx":"icon-DOC",".xls":"icon-XLS",".xlsx":"icon-XLS",".ppt":"icon-PPT",".pptx":"icon-PPT",".txt":"icon-TXT",".md":"icon-file-markdown-fill",".zip":"icon-wenjianyasuo",".rar":"icon-wenjianyasuo",".7z":"icon-wenjianyasuo",".tar":"icon-wenjianyasuo",".gz":"icon-wenjianyasuo",".js":"icon-JS",".ts":"icon-daimawenjia",".vue":"icon-daimawenjia",".html":"icon-HTML",".css":"icon-CSS",".py":"icon-daimawenjian",".java":"icon-daimawenjian",".json":"icon-JSON"}[null==a?void 0:a.toLowerCase()]||"icon-qitawenjian")])},null,2)),e.createElementVNode("view",{class:"folder-name"},e.toDisplayString(t.name),1),d.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:e.normalizeClass(["folder-checkbox",{"select-folder":m.value.includes(t.path)}])},[m.value.includes(t.path)?(e.openBlock(),e.createBlock(o,{key:0,type:"checkmarkempty",color:"#fff"})):e.createCommentVNode("",!0)],2)):e.createCommentVNode("",!0)],42,["onClick","onLongpress"]);var a})),128))])):e.createCommentVNode("",!0)]),d.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["workspace-footer",{"folder-actions":m.value.length>0}])},[e.createElementVNode("view",{class:"iconfont icon-shangchuan",onClick:g}),e.createElementVNode("view",{class:"iconfont icon-del"})],2)):e.createCommentVNode("",!0)])],64)}}},[["__scopeId","data-v-02673744"]]),ce=f({__name:"UserProfileModal",setup(n){const l=()=>{t("log","at pages/UserProfileModal/UserProfileModal.vue:55","点击了返回"),uni.navigateBack({delta:1,fail(){uni.reLaunch({url:"/pages/Chat/Chat"})}})},c=async()=>{if(d.value.trim()){uni.showLoading({title:"保存中...",mask:!0});try{await(e=i.value,a=r.value,n=d.value.trim(),s=m.value.trim(),c=u.value,new Promise(((t,l)=>{uni.request({url:`${o}/cloud_api/update_user_profile`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,user_id:a,username:n,"email:":s,avatar:c},success:e=>{if(200===e.statusCode){const a=e.data;if(a.success)t(a.message);else{const e=(null==a?void 0:a.error)||"修改用户信息出错啦";l(e)}}else l(`修改用户信息失败:${e.statusCode}`)}})}))),uni.hideLoading(),uni.showToast({title:"保存成功",icon:"success"}),setTimeout((()=>{l()}),800)}catch(v){uni.hideLoading();const e="string"==typeof v?v:"保存失败,请稍后重试";uni.showToast({title:e,icon:"none"}),t("error","at pages/UserProfileModal/UserProfileModal.vue:93","保存用户信息失败:",v)}var e,a,n,s,c}else uni.showToast({title:"用户名不能为空",icon:"none"})},i=e.ref(""),r=e.ref(""),u=e.ref(""),d=e.ref(""),m=e.ref(""),v=e.ref(!1),p=e.ref(!1),f=()=>{uni.chooseImage({count:1,sizeType:["compressed"],sourceType:["album","camera"],success:e=>{const t=e.tempFilePaths[0];h(t)},fail:e=>{t("log","at pages/UserProfileModal/UserProfileModal.vue:116","选择图片失败",e)}})},h=e=>{u.value=e};return e.onMounted((async()=>{i.value=k();try{const e=await s(i.value);r.value=e._id||"",u.value=e.avatar||"",d.value=e.username||"",m.value=e.email||""}catch(e){t("error","at pages/UserProfileModal/UserProfileModal.vue:135","获取用户信息失败:",e),uni.showToast({title:"加载用户信息失败",icon:"none"})}})),(t,n)=>{const o=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"user-profile page-container"},[e.createElementVNode("view",{class:"modal-header"},[e.createElementVNode("view",{class:"modal-left",onClick:l},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"})]),e.createElementVNode("view",{class:"modal-title"},[e.createElementVNode("view",{class:"title-text"},"编辑资料")]),e.createElementVNode("view",{class:"modal-right",onClick:c},[e.createElementVNode("view",{class:"save-btn"},"保存")])]),e.createElementVNode("view",{class:"modal-body"},[e.createElementVNode("view",{class:"avatar-upload-section",onClick:f},[e.createElementVNode("view",{class:"avatar-upload-container"},[u.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"avatar-preview"},[e.createElementVNode("image",{src:u.value,mode:"aspectFill"},null,8,["src"])])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"avatar-placeholder"},[e.createVNode(o,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))])]),e.createElementVNode("view",{class:"form-card"},[e.createElementVNode("view",{class:"form-field"},[e.createElementVNode("view",{class:"form-text"},"用户名"),e.withDirectives(e.createElementVNode("input",{"adjust-position":"false",class:e.normalizeClass(["form-field-input form-field-username",{"edit-input-focus":v.value}]),"onUpdate:modelValue":n[0]||(n[0]=e=>d.value=e),onFocus:n[1]||(n[1]=e=>v.value=!0),onBlur:n[2]||(n[2]=e=>v.value=!1)},null,34),[[e.vModelText,d.value]])]),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"form-field"},[e.createElementVNode("view",{class:"form-text"},"邮箱"),e.withDirectives(e.createElementVNode("input",{"adjust-position":"false",class:e.normalizeClass(["form-field-input form-field-emile",{"edit-input-focus":p.value}]),"onUpdate:modelValue":n[3]||(n[3]=e=>m.value=e),onFocus:n[4]||(n[4]=e=>p.value=!0),onBlur:n[5]||(n[5]=e=>p.value=!1)},null,34),[[e.vModelText,m.value]])])]),e.createElementVNode("view",{class:"prompt-content"},"*保存后再返回哟")])])],64)}}},[["__scopeId","data-v-8fad524d"]]),ie=f({__name:"ContactPages",setup(n){const o=K(),l=()=>{uni.navigateBack({delta:1,fail(){uni.reLaunch({url:"/pages/Chat/Chat"})}})},r=(e,t="")=>{uni.setStorageSync("chatType",e),t&&uni.setStorageSync("currentSessionId",t),uni.reLaunch({url:"/pages/Chat/Chat"})},u=e.ref(0),d=e.reactive([{name:"contacts",label:"通讯录",icon:"📞"},{name:"createGroup",label:"新建群聊",icon:"👥"},{name:"addFriend",label:"添加好友",icon:"➕"},{name:"friendRequest",label:"好友申请",icon:"📨"}]),m=e=>{u.value=e.detail.current},v=e.ref(""),p=e.ref(""),f="宇恒一号",h=e.ref([]),g=async()=>{try{t("log","at pages/ContactPages/ContactPages.vue:442","开始获取好友列表"),v.value=k();const e=await s(v.value);p.value=e._id,t("log","at pages/ContactPages/ContactPages.vue:446","UserId.value:",p.value);const a=await J(p.value);t("log","at pages/ContactPages/ContactPages.vue:448","friendList:",a),a&&a.length?h.value=await y(a):(h.value=[],t("log","at pages/ContactPages/ContactPages.vue:453","好友列表为空"))}catch(e){t("error","at pages/ContactPages/ContactPages.vue:456","获取好友列表失败:",e),h.value=[]}},y=async e=>{if(!(null==e?void 0:e.length))return[];try{const t=e.map((e=>e.receiver)),a=await c(v.value,t),n=new Map(a.map((e=>[e.user_id,e]))||[]);return e.map((e=>{const t=n.get(e.receiver);return{...e,avatar:(null==t?void 0:t.avatar)||null}}))}catch(a){return t("error","at pages/ContactPages/ContactPages.vue:477","获取好友头像失败",a),e}};e.onMounted((async()=>{await g(),await N(),await z(),o.isConnected||(v.value&&p.value?o.connect({token:v.value,UserId:p.value}):t("warn","at pages/ContactPages/ContactPages.vue:341","Token或UserId未准备好"))}));const E=e.ref([]),N=async()=>{try{t("log","at pages/ContactPages/ContactPages.vue:494","开始获取群聊列表"),v.value=k();const e=await s(v.value);p.value=e._id,t("log","at pages/ContactPages/ContactPages.vue:498","UserId.value:",p.value),E.value=await H(p.value)}catch(e){t("error","at pages/ContactPages/ContactPages.vue:501","获取群聊列表失败:",e),E.value=[]}},C=e.ref(""),b=e.ref(),V=async()=>{try{if(!C.value)return void uni.showToast({title:"群名称不能为空",icon:"none"});if(0===B.value.length)return void uni.showToast({title:"请选择群成员",icon:"none"});await new Promise(((e,a)=>{if(o.isConnected)return void e();if(!v.value||!p.value)return void a(new Error("Token或UserId未准备好"));t("log","at pages/ContactPages/ContactPages.vue:522","friendSocket 未连接,正在建立连接..."),o.connect({token:v.value,UserId:p.value});const n=setInterval((()=>{o.isConnected&&(clearInterval(n),t("log","at pages/ContactPages/ContactPages.vue:531","friendSocket 连接已建立"),e())}),100);setTimeout((()=>{clearInterval(n),o.isConnected||a(new Error("连接超时"))}),1e4)}));const e=B.value.map((e=>e.id));b.value={version:"1.1",body:{command:3,userIds:e,message:"我来邀请你们了",sender:p.value,callBackMessage:!0,groupName:C.value,teamCreateReq:{access_token:v.value}}};await o.send(b.value)?await _():t("log","at pages/ContactPages/ContactPages.vue:587","发送新建群聊消息失败")}catch(e){t("log","at pages/ContactPages/ContactPages.vue:590",e),uni.showToast({title:`新建群聊失败${e}`,icon:"none"})}},_=()=>new Promise(((a,n)=>{const l=setTimeout((()=>{n(new Error("超时未返回群聊创建结果"))}),18e4),s=e.watch((()=>o.command),(async e=>{if(t("log","at pages/ContactPages/ContactPages.vue:609","创建一个一次性监听器"),e&&3===o.command){t("log","at pages/ContactPages/ContactPages.vue:611","监听到command的值是3,检查群聊是否创建成功",o.command);try{await N();const e=E.value.find((e=>e.id===o.groupId));e?(t("log","at pages/ContactPages/ContactPages.vue:618","✅ 新建群聊成功",e),B.value=[],u.value=0):t("log","at pages/ContactPages/ContactPages.vue:623","❌ 新建群聊失败 / 群组不存在")}catch(a){t("error","at pages/ContactPages/ContactPages.vue:627","保存AI回复失败:",a),n(a)}finally{o.command=null,o.groupId=null,s(),clearTimeout(l)}}}))})),B=e.ref([]),S=e.ref(!1),x=e.ref(""),T=e.ref([]),D=async()=>{if(!x.value.trim())return void(T.value=[]);const e=x.value.toLowerCase().trim();T.value=await i(v.value,e),t("log","at pages/ContactPages/ContactPages.vue:676","searchResultList.value:",JSON.stringify(T.value))},j=()=>{S.value=!S.value},P=e.ref(null),$=()=>{P.value=null,M.value=!1},L=e.ref("");e.ref(!1),e.ref(!1);const M=e.ref(!1),I=e.ref([]),z=async()=>{try{if(!p.value)return;const e=await(async e=>new Promise(((t,a)=>{uni.request({url:`${R}/api/friendship/getFriendship`,method:"POST",data:{current:1,size:100,sendId:e},success:e=>{var n;if(200===e.statusCode){const o=e.data;if(0===(null==o?void 0:o.code)||"成功"===(null==o?void 0:o.msg)){const e=(null==(n=null==o?void 0:o.data)?void 0:n.records)||[];t(e)}else{const t=e.data.msg||"获取添加我的好友出错啦";a(t)}}else a(`获取添加我的好友失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(p.value);e&&e.length?I.value=await F(e):I.value=[]}catch(e){t("error","at pages/ContactPages/ContactPages.vue:732","获取好友申请列表失败:",e),I.value=[]}},F=async e=>{if(!(null==e?void 0:e.length))return[];try{const t=e.map((e=>e.sendId)),a=await c(v.value,t),n=new Map(a.map((e=>[e.user_id,e]))||[]);return e.map((e=>{const t=n.get(e.sendId);return{...e,avatar:(null==t?void 0:t.avatar)||null}}))}catch(a){return t("error","at pages/ContactPages/ContactPages.vue:751","获取申请人头像失败",a),e}},O=async()=>{if(M.value)try{const e=P.value.sendId,t=L.value||P.value.friendNickName||"",a=P.value.sessionId||Date.now(),n=P.value.id;await(async e=>new Promise(((t,a)=>{uni.request({url:`${R}/api/chatList/save`,method:"POST",header:{"Content-Type":"application/json"},data:e,success:e=>{if(200===e.statusCode){const n=e.data;if(0===(null==n?void 0:n.code)||"成功"===(null==n?void 0:n.msg))t("保存好友成功");else{const e=(null==n?void 0:n.msg)||"保存好友出错啦";a(e)}}else a(`保存好友失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))([{friendNickName:t,sender:p.value,receiver:e,sessionId:a,friendRelationshipId:n},{friendNickName:"",sender:e,receiver:p.value,sessionId:a,friendRelationshipId:n}]),uni.showToast({title:"已同意好友申请",icon:"none"});const o=I.value.find((t=>t.sendId===e));o&&(o.status=1),$(),await g()}catch(e){t("error","at pages/ContactPages/ContactPages.vue:795","同意好友申请失败:",e),uni.showToast({title:"操作失败",icon:"none"})}else try{const e=P.value._id,a=await(async(e,a,n)=>new Promise(((o,l)=>{t("log","at utils/friend-api.js:239","进入sendFriendRequest"),uni.request({url:`${R}/api/friendship/saveShip`,method:"POST",data:{sendId:e,friendNickName:a,recipientId:n},success:e=>{if(200===e.statusCode){const t=e.data;if(0===(null==t?void 0:t.code)||"成功"===(null==t?void 0:t.msg))o("已成功发送好友申请");else{const t=e.data.msg||"发送好友申请出错啦";l(t)}}else l(`发送好友申请失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(p.value,L.value,e);uni.showToast({title:a,icon:"none"}),$()}catch(e){t("error","at pages/ContactPages/ContactPages.vue:806","发送好友申请失败:",e),uni.showToast({title:"发送申请失败",icon:"none"})}};return(n,o)=>{const s=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),P.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-overlay"},[e.createElementVNode("view",{class:"popup-card"},[e.createElementVNode("view",{class:"close-popup-card",onClick:$},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},e.toDisplayString(M.value?"通过好友申请":"申请添加朋友"),1),e.createElementVNode("view",{class:"friend-card"},[e.createElementVNode("view",{class:"friend-card-left"},[P.value.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:P.value.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(s,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(P.value.username),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(P.value.sessionId),1)])]),e.createElementVNode("view",{class:"nickname-wrapper"},[e.createElementVNode("view",null,"好友备注"),e.withDirectives(e.createElementVNode("input",{class:"input-nickname",placeholder:"请输入好友名称","onUpdate:modelValue":o[0]||(o[0]=e=>L.value=e)},null,512),[[e.vModelText,L.value]])]),e.createElementVNode("view",{class:"text-btn confirm-btn",onClick:O},e.toDisplayString(M.value?"确认通过":"发送申请"),1)])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"tabbar-page page-container"},[e.createElementVNode("swiper",{class:"content-swiper",current:u.value,duration:300,onChange:m},[e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:l}),e.createElementVNode("view",{class:"tabpage-title"},"通讯录")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[e.createElementVNode("view",{class:"friend-card",onClick:o[1]||(o[1]=e=>r(0))},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar",style:{"background-color":"#38bdf8"}},[e.createElementVNode("view",{class:"iconfont icon-Robot",style:{"font-size":"80rpx",color:"#fff"}})])]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(f),1),e.createElementVNode("view",{class:"friend-label"})]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(s,{type:"right"})])]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.sessionId,onClick:e=>r(t.type,t.sessionId)},[e.createElementVNode("view",{class:"friend-card-left"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(s,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.friendNickName),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.sessionId),1)]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(s,{type:"right"})])],8,["onClick"])))),128)),e.createElementVNode("view",null,"群聊"),e.createElementVNode("view",{class:"solid-line"}),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.id,onClick:e=>r(t.type,t.id)},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar",style:{"background-color":"#ffaaff"}},[e.createElementVNode("view",{class:"iconfont icon-qunliao",style:{"font-size":"80rpx",color:"#fff"}})])]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.createTime),1)]),e.createElementVNode("view",{class:"friend-card-right"},[e.createVNode(s,{type:"right"})])],8,["onClick"])))),128))])])])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:l}),e.createElementVNode("view",{class:"tabpage-title"},"新建群聊")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("view",{class:"group-info"},[e.createElementVNode("view",{class:"group-name"},[e.createElementVNode("view",null,"群名称"),e.withDirectives(e.createElementVNode("input",{class:"input",placeholder:"请输入群名称","onUpdate:modelValue":o[2]||(o[2]=e=>C.value=e)},null,512),[[e.vModelText,C.value]])]),e.createElementVNode("view",{class:"group-member-wrapper"},[e.createElementVNode("view",{class:"member-title"},"群成员"),e.createElementVNode("view",{class:"group-ismember-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"group-ismember-info",key:a},[e.createElementVNode("view",{class:"group-ismember-name"},e.toDisplayString(t.friendNickName),1)])))),128))])]),e.createElementVNode("view",{class:"create-group-btn",onClick:V},"创建群聊")]),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(a=>{var n;return e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:a.receiver},[e.createElementVNode("view",{class:"friend-card-left"},[a.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:a.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(s,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(a.friendNickName),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(a.email),1)]),e.createElementVNode("view",{class:"friend-card-right",onClick:e=>(e=>{t("log","at pages/ContactPages/ContactPages.vue:648","选择的好友id:",e),t("log","at pages/ContactPages/ContactPages.vue:649","selectGroupMember.value=",JSON.stringify(B.value));const a=B.value.findIndex((t=>t.id===e));if(-1===a){const t=h.value.find((t=>t.receiver===e));t&&B.value.push({id:t.receiver,friendNickName:t.friendNickName})}else B.value.splice(a,1)})(a.receiver)},[e.createElementVNode("view",{class:"friend-checkbox"},[(null==(n=B.value)?void 0:n.find((e=>e.id===a.receiver)))?(e.openBlock(),e.createBlock(s,{key:0,type:"checkmarkempty"})):e.createCommentVNode("",!0)])],8,["onClick"])])})),128))])])])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:l}),e.createElementVNode("view",{class:"tabpage-title"},"添加好友")]),e.createElementVNode("view",{class:"tabpage-body"},[e.createElementVNode("view",{class:"search-warpper"},[e.withDirectives(e.createElementVNode("input",{class:e.normalizeClass(["search-file-input",{active:S.value}]),onFocus:j,onBlur:j,"onUpdate:modelValue":o[3]||(o[3]=e=>x.value=e),"confirm-type":"search",onConfirm:D},null,34),[[e.vModelText,x.value]]),e.createElementVNode("view",{class:"iconfont icon-sousuo",onClick:D})]),x.value?T.value.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"search-result"},[e.createElementVNode("scroll-view",{class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.value,(a=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:a.id},[e.createElementVNode("view",{class:"friend-card-left"},[e.createElementVNode("view",{class:"friend-avatar"},[e.createElementVNode("image",{class:"friend-avatar",src:a.avatar,mode:"aspectFill"},null,8,["src"])])]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(a.nickname),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(a.email),1)]),e.createElementVNode("view",{class:"friend-card-right",onClick:e=>(e=>{const a=T.value.find((t=>t._id===e));a?P.value={...a}:(t("warn","at pages/ContactPages/ContactPages.vue:697","未找到该好友"),P.value=null)})(a._id)},[e.createElementVNode("view",{class:"add-btn text-btn"},"添加")],8,["onClick"])])))),128))])])])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"no-result"},"未找到相关用户,请尝试其他关键词")):(e.openBlock(),e.createElementBlock("view",{key:0,class:"search-tip"},"请输入用户名或邮箱进行搜索"))])])]),e.createElementVNode("swiper-item",{class:"content-swiper-item"},[e.createElementVNode("view",{class:"tabpage-containner"},[e.createElementVNode("view",{class:"tabpage-header"},[e.createElementVNode("view",{class:"iconfont icon-fanhui",onClick:l}),e.createElementVNode("view",{class:"tabpage-title"},"好友申请")]),e.createElementVNode("view",{class:"tabpage-body"},[I.value.length?(e.openBlock(),e.createElementBlock("scroll-view",{key:1,class:"group-member",direction:"vertical","scroll-y":"true"},[e.createElementVNode("view",{class:"friend-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(I.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"friend-card",key:t.id},[e.createElementVNode("view",{class:"friend-card-left"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"friend-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-avatar"},[e.createVNode(s,{type:"person-filled",size:"100rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"friend-card-middle"},[e.createElementVNode("view",{class:"friend-name"},e.toDisplayString(t.friendNickName||t.sendId),1),e.createElementVNode("view",{class:"friend-label"},e.toDisplayString(t.message||"请求添加你为好友"),1)]),e.createElementVNode("view",{class:"friend-card-right"},[0===t.state?(e.openBlock(),e.createElementBlock("view",{key:0,class:"friend-option"},[e.createElementVNode("view",{class:"agree-btn text-btn",onClick:e=>(e=>{M.value=!0,P.value={...e,username:e.friendNickName||e.sendId}})(t)},"同意",8,["onClick"])])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"friend-status agreed"},"已同意"))])])))),128))])])):(e.openBlock(),e.createElementBlock("view",{key:0,class:"no-result"},"暂无好友申请"))])])])],40,["current"]),e.createElementVNode("view",{class:"bottom-tabbar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:t.name,onClick:e=>(e=>{u.value=e})(a),class:"tab-item"},[e.createElementVNode("view",{class:"tab-icon"},e.toDisplayString(t.icon),1),e.createElementVNode("view",{class:"tab-label"},e.toDisplayString(t.label),1)],8,["onClick"])))),128))])])],64)}}},[["__scopeId","data-v-d6fd7c06"]]),re=f({__name:"TemplateSpace",setup(a){const n=e=>{if(!e)return"";const t=Math.floor(e),a=new Date(1e3*t);return`${a.getFullYear()}-${(a.getMonth()+1).toString().padStart(2,"0")}-${a.getDate().toString().padStart(2,"0")} ${a.getHours().toString().padStart(2,"0")}:${a.getMinutes().toString().padStart(2,"0")}:${a.getSeconds().toString().padStart(2,"0")}`},o=e=>{if(!e||0===e)return"0 B";const t=["B","KB","MB","GB","TB"];let a=e,n=0;for(;a>=1024&&n{t("log","at pages/WorkSpace/TemplateSpace/TemplateSpace.vue:188","点击了编辑模板")},c=e.ref(""),i=e.ref([]),r=e=>{c.value=e,"all"===e&&(d.value="全部模板",i.value=y.value),"like"===e&&(d.value="收藏模板",i.value=y.value.filter((e=>!0===e.is_favorite)))},u=e.ref(""),d=e.ref("模板区"),m=e.ref(!1),v=e.ref([]),p=()=>{m.value&&(v.value=[]),m.value=!m.value},f=e.ref(!1),h=()=>{f.value=!f.value},g=e.ref(""),w=e.ref(!1),k=()=>{w.value=!w.value},y=e.ref([{name:"SKILL.md",type:"file",path:"SKILL.md",children:[],file_count:0,directory_count:0,size:4768,modified_time:1776827361.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"该回家看了的法国红酒看来法帝国海军快来尝尝v吧给v复仇计划曝光vi计划日方提供与i哦的风格和健康"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"的法国红酒看来法帝国海军快来尝尝v吧给"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:""},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"},{name:"222.md",type:"file",path:"222.md",children:[],file_count:0,directory_count:0,size:5558,modified_time:1776827666.9123552,extension:".md",is_favorite:!1,usage_count:0,sort:0,content:"khgvshbbthvgbihepiubjhrviifdhiuhrviuehrviuawhiuvrhy"}]),E=()=>{m.value?v.value.length===i.value.length?v.value=[]:v.value=i.value.map((e=>e.id)):(!m.value&&i.value&&(i.value=[],c.value="",d.value="模板区"),m.value||i.value||uni.navigateBack({delta:1,fail(){t("log","at pages/WorkSpace/TemplateSpace/TemplateSpace.vue:468","返回失败,进入兜底跳转"),uni.reLaunch({url:"/pages/Chat/Chat"})}}))};return(t,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),e.createElementVNode("view",{class:"popup-overlay"},[e.createElementVNode("view",{class:"popup-card"},[e.createElementVNode("view",{class:"close-popup-card"},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"编辑模板"),e.createElementVNode("view",{class:"edit-template-wrapper"},[e.createElementVNode("view",{class:"edit-template-name"},[e.createElementVNode("view",null,"模板名称"),e.withDirectives(e.createElementVNode("input",{"placeholder-style":"请输入模板名称","onUpdate:modelValue":a[0]||(a[0]=e=>l.value=e)},null,512),[[e.vModelText,l.value]])]),e.createElementVNode("view",{class:"edit-template-name"},[e.createElementVNode("view",null,"模板内容"),e.createElementVNode("view",{class:"markdown-editor-pane"},[e.createElementVNode("view",{class:"markdown-pane-header"}," 编辑 "),e.createElementVNode("textarea")]),e.createElementVNode("view",{class:"markdown-preview-pane"},[e.createElementVNode("view",{class:"markdown-pane-header"}," 预览 "),e.createElementVNode("view")])])])])]),e.createElementVNode("view",{class:"workspace-container page-container"},[e.createElementVNode("view",{class:"workspace-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:a[1]||(a[1]=(...e)=>E&&E(...e))},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"}),e.createElementVNode("view",{class:"navbar-before-title workspace-text"},e.toDisplayString(m.value?"全选":u.value),1)]),e.createElementVNode("view",{class:"navbar-title workspace-text"},e.toDisplayString(d.value),1),c.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right"},[m.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-right-text workspace-text",onClick:a[2]||(a[2]=e=>p())}," 完成")):(e.openBlock(),e.createElementBlock("view",{key:1,class:e.normalizeClass(["iconfont icon-gengduo",f.value?"menu-open":"custom-navbar-icon"]),onClick:h},null,2))])):e.createCommentVNode("",!0),f.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:a[3]||(a[3]=e=>{p(),h()})},"选择"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item"},"新建模板"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item"},"上传模板")])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"search-file-warpper"},[e.createElementVNode("view",{class:"search-file"},[e.createElementVNode("view",{class:"iconfont icon-sousuo"}),e.withDirectives(e.createElementVNode("input",{class:"search-file-input",placeholder:"搜索",onFocus:k,"onUpdate:modelValue":a[4]||(a[4]=e=>g.value=e)},null,544),[[e.vModelText,g.value]])]),w.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"cancel-search",onClick:k},"取消")):e.createCommentVNode("",!0)])]),c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-grid"},[e.createElementVNode("view",{class:"folder-item",onClick:a[5]||(a[5]=e=>r("all"))},[e.createElementVNode("view",{class:"iconfont icon-a-wenjianjiawenjian folder-item-style"}),e.createElementVNode("view",{class:"folder-name"},"全部模板")]),e.createElementVNode("view",{class:"folder-item",onClick:a[6]||(a[6]=e=>r("like"))},[e.createElementVNode("view",{class:"iconfont icon-a-wenjianjiawenjian folder-item-style"}),e.createElementVNode("view",{class:"folder-name"},"收藏模板")])])),c.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"workspace-content"},[0===i.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createTextVNode(" 暂无模板 ")])):e.createCommentVNode("",!0),i.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"template-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"template-card",key:a},[e.createElementVNode("view",{class:"template-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"template-content"},[e.createElementVNode("view",{class:"template-content-text"},e.toDisplayString(t.content),1)]),e.createElementVNode("view",{class:"template-info-wrapper"},[e.createElementVNode("view",{class:"template-item"},[e.createElementVNode("view",{class:"template-time background-style"},e.toDisplayString(n(t.modified_time)),1),e.createElementVNode("view",{class:"template-cache background-style"},e.toDisplayString(o(t.size)),1)]),e.createElementVNode("view",{class:"template-option"},[e.createElementVNode("view",{class:e.normalizeClass(["iconfont",t.is_favorite?"icon-favorite-fill":"icon-favorite"]),onClick:e=>(e=>{let t;"all"===c.value?t=y.value[e]:"like"===c.value&&(t=y.value.filter((e=>e.is_favorite))[e]);t&&(t.is_favorite=!t.is_favorite),"all"===c.value?i.value=[...y.value]:i.value=y.value.filter((e=>e.is_favorite))})(a)},null,10,["onClick"]),e.createElementVNode("view",{class:"iconfont icon-edit-fill",onClick:s}),e.createElementVNode("view",{class:"iconfont icon-choose-fill"})])])])))),128))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:e.normalizeClass(["workspace-footer",{"folder-actions":v.value.length>0}])},[e.createElementVNode("view",{class:"iconfont icon-shangchuan"}),e.createElementVNode("view",{class:"iconfont icon-fuzhi"}),e.createElementVNode("view",{class:"iconfont icon-wenjian"}),e.createElementVNode("view",{class:"iconfont icon-del"}),e.createElementVNode("view",{class:"iconfont icon-gengduo"})],2)):e.createCommentVNode("",!0)])],64))}},[["__scopeId","data-v-2acd55d4"]]),ue={__name:"text",setup(t){const a=e.ref("");return e.onMounted((()=>{a.value='\n明白了!您希望在我的回复中直接嵌入可编辑的表单卡片。让我试试:\n\n---\n\n
    \n

    \n✏️ 直接在下方编辑任务\n

    \n\n
    \n
    \n\n\n
    \n\n
    \n\n\n
    \n\n
    \n
    \n\n\n
    \n
    \n\n\n
    \n
    \n\n
    \n\n\n
    \n\n
    \n\n
    \n\n\n\n
    \n
    \n\n
    \n\n
    \n\n\n\n\n
    \n
    \n\n
    \n\n\n
    \n
    \n
    \n\n\n\n---\n\n**✅ 您现在可以直接在上方的卡片中填写任务信息,点击"添加任务"即可!**\n\n填写完成后告诉我"已填好"或"添加",我会帮您确认是否成功!\n'})),(t,n)=>{return e.openBlock(),e.createElementBlock("view",null,[e.createElementVNode("view",{innerHTML:(o=a.value,o.replace(/<\/?script>/gi,(e=>{let t="";for(let a=0;a{const e=n.connectionStatus;return{"status-connected":"connected"===e,"status-connecting":"connecting"===e,"status-error":"error"===e,"status-disconnected":"disconnected"===e}})),i=()=>{o.value.token?n.connect({token:o.value.token,conversationId:y()}):uni.showToast({title:"请输入Token",icon:"none"})},r=()=>{n.disconnect()},u=async()=>{try{await n.sendPing()}catch(e){uni.showToast({title:"发送失败",icon:"none"})}},d=async()=>{if(l.value.trim())try{const e={ws_event:"message",data:{task_call_id:E(),result:{tools:[]}}};await n.send(e),l.value=""}catch(e){uni.showToast({title:"发送失败",icon:"none"})}},m=()=>{if(l.value.trim())try{const e=JSON.parse(l.value);l.value=JSON.stringify(e,null,2)}catch{uni.showToast({title:"不是有效的JSON",icon:"none"})}},v=()=>{};return e.watch((()=>n.isDisconnected),(e=>{e&&n.messageString&&t("log","at pages/text/text2.vue:253",n.messageString)})),e.onMounted((()=>{n.addLog("info","=== Socket测试页面 ==="),n.addLog("info","页面已加载"),n.isConnected&&n.addLog("info","当前已处于连接状态")})),e.onUnmounted((()=>{n.addLog("info","页面卸载")})),(t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"container"},[e.createElementVNode("view",{class:"status-card"},[e.createElementVNode("text",{class:"status-label"},"连接状态"),e.createElementVNode("view",{class:e.normalizeClass(["status-value",c.value])},[e.createElementVNode("text",null,e.toDisplayString(e.unref(n).getStatusText()),1)],2),e.unref(n).reconnectAttempts>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"status-info"},[e.createElementVNode("text",{class:"reconnect-info"},"重连次数: "+e.toDisplayString(e.unref(n).reconnectAttempts),1)])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"config-card"},[e.createElementVNode("text",{class:"section-title"},"连接配置"),e.createElementVNode("view",{class:"input-group"},[e.createElementVNode("text",{class:"input-label"},"Token"),e.withDirectives(e.createElementVNode("input",{class:"input-field","onUpdate:modelValue":a[0]||(a[0]=e=>o.value.token=e),placeholder:"请输入Token"},null,512),[[e.vModelText,o.value.token]])]),e.createElementVNode("view",{class:"input-group"},[e.createElementVNode("text",{class:"input-label"},"Conversation ID"),e.withDirectives(e.createElementVNode("input",{class:"input-field","onUpdate:modelValue":a[1]||(a[1]=e=>o.value.conversationId=e),placeholder:"请输入会话ID(可选)"},null,512),[[e.vModelText,o.value.conversationId]])])]),e.createElementVNode("view",{class:"control-card"},[e.createElementVNode("button",{class:"btn btn-primary",disabled:e.unref(n).isConnected||e.unref(n).isConnecting,onClick:i},e.toDisplayString(e.unref(n).isConnecting?"连接中...":"连接"),9,["disabled"]),e.createElementVNode("button",{class:"btn btn-danger",disabled:!e.unref(n).isConnected,onClick:r}," 断开 ",8,["disabled"]),e.createElementVNode("button",{class:"btn btn-secondary",onClick:u,disabled:!e.unref(n).isConnected}," Ping ",8,["disabled"])]),e.createElementVNode("view",{class:"send-card"},[e.createElementVNode("text",{class:"section-title"},"发送消息"),e.createElementVNode("view",{class:"send-input-wrapper"},[e.withDirectives(e.createElementVNode("textarea",{class:"send-input","onUpdate:modelValue":a[2]||(a[2]=e=>l.value=e),placeholder:"输入要发送的消息(JSON格式)",disabled:!e.unref(n).isConnected},null,8,["disabled"]),[[e.vModelText,l.value]]),e.createElementVNode("view",{class:"send-buttons"},[e.createElementVNode("button",{class:"btn btn-primary btn-small",disabled:!e.unref(n).isConnected||!l.value.trim(),onClick:d}," 发送 ",8,["disabled"]),e.createElementVNode("button",{class:"btn btn-outline btn-small",disabled:!l.value.trim(),onClick:m}," 格式化 ",8,["disabled"])])]),e.createElementVNode("view",{class:"quick-messages"},[e.createElementVNode("text",{class:"quick-label"},"快捷消息:"),e.createElementVNode("view",{class:"quick-btns"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(t=>(e.openBlock(),e.createElementBlock("button",{key:t.label,class:"quick-btn",disabled:!e.unref(n).isConnected,onClick:e=>(async e=>{const t={ws_event:"message",data:{task_call_id:E(),token:k(),conversation_id:y()}};try{await n.send(t)}catch(a){uni.showToast({title:"发送失败",icon:"none"})}})(t.data)},e.toDisplayString(t.label),9,["disabled","onClick"])))),128))])])]),e.createElementVNode("view",{class:"log-card"},[e.createElementVNode("view",{class:"log-header"},[e.createElementVNode("view",{class:"log-title-wrapper"},[e.createElementVNode("text",{class:"section-title"},"日志"),e.createElementVNode("text",{class:"log-count"},"("+e.toDisplayString(e.unref(n).logs.length)+")",1)]),e.createElementVNode("view",{class:"log-actions"},[e.createElementVNode("button",{class:"btn btn-small btn-secondary",onClick:a[3]||(a[3]=(...t)=>e.unref(n).clearLogs&&e.unref(n).clearLogs(...t))},"清空")])]),e.createElementVNode("scroll-view",{class:"log-list","scroll-y":"",onScrolltoupper:v},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(n).logs,((t,a)=>(e.openBlock(),e.createElementBlock("view",{key:a,class:e.normalizeClass(["log-item","log-"+t.type])},[e.createElementVNode("text",{class:"log-time"},e.toDisplayString(t.time),1),e.createElementVNode("text",{class:"log-content"},e.toDisplayString(t.content),1)],2)))),128))],32)])]))}},[["__scopeId","data-v-939e1d1d"]]),me=f({__name:"CloudDatabase",setup(n){const l=e.ref(""),c=e.ref(""),p=e.ref(""),f=e.ref("user"),h=e=>{f.value=e,T.value=[],M()},g=e.ref("云端数据"),y=e.ref(!1),E=e.ref(!1),N=e.ref([]),C=()=>{y.value=!y.value},b=e.computed((()=>{var e;return 0===T.value.length?"":1===T.value.length?"云端数据":(null==(e=T.value[T.value.length-2])?void 0:e.name)||"云端数据"})),V=()=>{T.value.length>0?(T.value.pop(),g.value=T.value.length>0?T.value[T.value.length-1].name:"云端数据",M()):uni.navigateBack({delta:1,fail(){uni.reLaunch({url:"/pages/Chat/Chat"})}})},_=e.ref([]),B=e.ref([]),S=e.ref([]),x=e.ref([]),T=e.ref([]),D=e=>"folder"===e.type,j=e=>{if(D(e))return"icon-a-wenjianjiawenjian";const t=(e=>{if(D(e))return"folder";const t=e.name||"",a=t.lastIndexOf(".");return-1===a?"":t.slice(a).toLowerCase()})(e),a=(e.type||"").toLowerCase(),n={".png":"icon-wenjiantupian",".jpg":"icon-wenjiantupian",".jpeg":"icon-wenjiantupian",".gif":"icon-wenjiantupian",".svg":"icon-SVG",".bmp":"icon-wenjiantupian",".webp":"icon-wenjiantupian",".mp4":"icon-wenjianshipin",".avi":"icon-wenjianshipin",".mov":"icon-wenjianshipin",".wmv":"icon-wenjianshipin",".flv":"icon-wenjianshipin",".mkv":"icon-wenjianshipin",".mp3":"icon-wenjianyinpin",".wav":"icon-wenjianyinpin",".flac":"icon-wenjianyinpin",".aac":"icon-wenjianyinpin",".pdf":"icon-PDF",".doc":"icon-DOC",".docx":"icon-DOC",".xls":"icon-XLS",".xlsx":"icon-XLS",".ppt":"icon-PPT",".pptx":"icon-PPT",".txt":"icon-TXT",".md":"icon-file-markdown-fill",".zip":"icon-wenjianyasuo",".rar":"icon-wenjianyasuo",".7z":"icon-wenjianyasuo",".tar":"icon-wenjianyasuo",".gz":"icon-wenjianyasuo",".js":"icon-JS",".ts":"icon-daimawenjia",".vue":"icon-daimawenjia",".html":"icon-HTML",".css":"icon-CSS",".py":"icon-daimawenjian",".java":"icon-daimawenjian",".json":"icon-JSON"};return t&&n[t]?n[t]:a.startsWith("image/")?"icon-wenjiantupian":a.startsWith("video/")?"icon-wenjianshipin":a.startsWith("audio/")?"icon-wenjianyinpin":a.includes("spreadsheet")||a.includes("excel")?"icon-XLS":a.includes("document")||a.includes("word")?"icon-DOC":a.includes("presentation")||a.includes("powerpoint")?"icon-PPT":a.includes("pdf")?"icon-PDF":a.includes("zip")||a.includes("rar")||a.includes("tar")||a.includes("gzip")?"icon-wenjianyasuo":"icon-qitawenjian"},P=e=>e?e<1024?e+" B":e<1048576?(e/1024).toFixed(1)+" KB":(e/1048576).toFixed(1)+" MB":"",$=e.computed((()=>0===T.value.length?"根目录 (/)":"/"+T.value.map((e=>e.name)).join("/"))),L=e.computed((()=>_.value.length)),M=()=>{const e="user"===f.value?_.value:B.value;if(0===T.value.length)"user"===f.value?S.value=e:x.value=e;else{const e=T.value[T.value.length-1].children||[];"user"===f.value?S.value=e:x.value=e}},I=async()=>{try{l.value=k();const e=await s(l.value);c.value=e._id,p.value=uni.getStorageSync("workspace_id")||"";const t=await d(l.value,"user");_.value=t||[],"user"===f.value&&(S.value=t||[])}catch(e){t("error","at pages/CloudDatabase/CloudDatabase.vue:689","获取文件列表失败:",e),_.value=[],S.value=[]}},z=async e=>{try{e=null==e?"":String(e);const a=await d(l.value,"team","/",e);t("log","at pages/CloudDatabase/CloudDatabase.vue:700","团队云端文件:",JSON.stringify(a)),B.value=a||[],x.value=a||[]}catch(a){t("error","at pages/CloudDatabase/CloudDatabase.vue:704","获取团队文件列表失败:",a),B.value=[],x.value=[]}},F=e=>{D(e)?(T.value.push({path:e.path,name:e.name,children:e.children||[]}),g.value=e.name,M()):A(e)},O=e=>{if(E.value){const t=N.value.indexOf(e.id);return void(-1!==t?N.value.splice(t,1):N.value.push(e.id))}const t=D(e)?["重命名","删除"]:["下载","重命名","删除"];uni.showActionSheet({itemList:t,success:t=>{if(D(e))switch(t.tapIndex){case 0:J(e);break;case 1:H(e)}else switch(t.tapIndex){case 0:A(e);break;case 1:J(e);break;case 2:H(e)}}})},A=async e=>{var a,n;if(D(e))uni.showToast({title:"暂不支持下载目录",icon:"none"});else try{uni.showLoading({title:"获取下载链接..."});const t=await(a=l.value,n=e.id,new Promise(((e,t)=>{uni.request({url:`${o}/cloud_api/file/download`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:a,file_id:n},success:a=>{if(200===a.statusCode){const n=a.data;if(n.success)e(n.data.download_url);else{const e=(null==n?void 0:n.error)||"获取云端文件url出错啦";t(e)}}else t(`获取云端文件url失败:${a.statusCode}`)},fail:e=>{const a=e.errMsg||"网络错误";t(a)}})})));if(uni.hideLoading(),!t)return void uni.showToast({title:"获取下载链接失败",icon:"error"});uni.showLoading({title:"下载中..."}),uni.downloadFile({url:t,success:t=>{if(uni.hideLoading(),200===t.statusCode){const a=t.tempFilePath;U(e.name,a)}else uni.showToast({title:"下载失败",icon:"error"})},fail:()=>{uni.hideLoading(),uni.showToast({title:"下载失败,请重试",icon:"error"})}})}catch(s){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:821","下载失败:",s),uni.showToast({title:"下载失败,请重试",icon:"error"})}},U=(e,a)=>{const n="/storage/emulated/0/yxd/";var o;o=o=>{plus.io.resolveLocalFileSystemURL(a,(l=>{l.copyTo(o,e,(()=>{const a=n+e;t("log","at pages/CloudDatabase/CloudDatabase.vue:864","文件已保存到:",a),q(e,a)}),(n=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:868","复制文件失败:",JSON.stringify(n)),q(e,a)}))}),(n=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:873","读取临时文件失败:",JSON.stringify(n)),q(e,a)}))},plus.io.resolveLocalFileSystemURL(n,(e=>{o(e)}),(()=>{plus.io.resolveLocalFileSystemURL("/storage/emulated/0/",(n=>{n.getDirectory("yxd",{create:!0},(e=>{o(e)}),(n=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:845","创建 yxd 目录失败:",JSON.stringify(n)),uni.showToast({title:"创建目录失败",icon:"error"}),q(e,a)}))}),(n=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:850","访问外部存储根目录失败:",JSON.stringify(n)),uni.showToast({title:"无法访问存储目录",icon:"error"}),q(e,a)}))}))},q=(e,t)=>{uni.showActionSheet({title:`${e} 下载完成`,itemList:["打开文件","选择其他应用打开","仅保存"],success:e=>{switch(e.tapIndex){case 0:W(t);break;case 1:R(t);break;case 2:uni.showToast({title:"文件已保存到 yxd 目录",icon:"success"})}},fail:()=>{uni.showToast({title:"文件已保存到 yxd 目录",icon:"success"})}})},W=e=>{uni.openDocument({filePath:e,success:()=>uni.showToast({title:"打开成功",icon:"success"}),fail:a=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:936","打开文件失败:",a),R(e)}})},R=e=>{plus.runtime.openFile(e,{},(e=>{t("log","at pages/CloudDatabase/CloudDatabase.vue:948","文件打开成功")}))},J=e=>{uni.showModal({title:"重命名",content:"请输入新名称",editable:!0,placeholderText:e.name,success:e=>{e.confirm&&e.content&&(uni.showToast({title:"重命名成功",icon:"success"}),G())}})},H=e=>{const a=D(e)?`确定要删除目录"${e.name}"吗?目录内所有文件将被一并删除。`:`确定要删除文件"${e.name}"吗?`;uni.showModal({title:"删除确认",content:a,confirmText:"删除",confirmColor:"#e74c3c",success:async a=>{if(a.confirm){uni.showLoading({title:"删除中..."});try{await(n=l.value,s=e.id,new Promise(((e,t)=>{uni.request({url:`${o}/cloud_api/file/delete`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:n,file_id:s},success:a=>{if(200===a.statusCode){const n=a.data;if(n.success)e(n.message);else{const e=(null==n?void 0:n.error)||"删除云端文件出错啦";t(e)}}else t(`删除云端文件失败:${a.statusCode}`)},fail:e=>{const a=e.errMsg||"网络错误";t(a)}})}))),uni.hideLoading(),uni.showToast({title:"删除成功",icon:"success"}),G()}catch(c){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1014","deleteCloudFile 失败,尝试 daleteWorkspace:",c);try{const t=e.path||"/"+e.name;p.value&&await r(l.value,p.value,t),uni.showToast({title:"删除成功",icon:"success"}),G()}catch(i){t("error","at pages/CloudDatabase/CloudDatabase.vue:1026","删除失败:",i),uni.showToast({title:"删除失败,请重试",icon:"error"})}}}var n,s}})},G=async()=>{"user"===f.value?await I():await z(Te.value)},X=e.ref(!1),K=e.ref(""),Y=()=>{X.value=!1,K.value=""},Q=async()=>{const e=K.value.trim();if(e)try{if(p.value){const t=("根目录 (/)"===$.value?"/":$.value)+e;await u(l.value,p.value,t)}uni.showToast({title:"创建成功",icon:"success"}),Y(),G()}catch(a){t("error","at pages/CloudDatabase/CloudDatabase.vue:1083","创建文件夹失败:",a),uni.showToast({title:"创建失败,请重试",icon:"error"})}else uni.showToast({title:"请输入目录名称",icon:"none"})},Z=e.ref(!1),ee=e.ref("/"),te=()=>{Z.value=!0,ee.value="/"},ae=()=>{Z.value=!1},ne=()=>{ee.value.trim()||(ee.value="/"),Z.value=!1,le()},le=()=>{oe({count:10,type:"all",success:e=>{const t=(e.tempFiles||[]).map((e=>({tempFilePath:e.path||e.tempFilePath,name:e.name})));0!==t.length?se(t):uni.showToast({title:"未选择文件",icon:"none"})},fail:e=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:1133","选择文件失败:",e)}})},se=async e=>{uni.showLoading({title:"上传中..."});try{const t=ee.value.trim()||"/",a="user"===f.value?"user":"team",n="team"===f.value?Te.value:"";await((e,t,a,n,l)=>new Promise(((s,c)=>{const i=null==l?"":String(l);uni.uploadFile({url:`${o}/cloud_api/file/upload`,method:"POST",header:{},formData:{access_token:e,path:a||"/",type:t,team_id:i},files:n.map((e=>({uri:e.tempFilePath,name:"files"}))),success:e=>{if(200===e.statusCode)try{const t=JSON.parse(e.data);if(t.success)s(t.message);else{const e=(null==t?void 0:t.error)||"获取云端文件url出错啦";c(e)}}catch(t){c("接口返回数据格式异常")}else c(`获取云端文件url失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";c(t)}})})))(l.value,a,t,e,n),uni.hideLoading(),uni.showToast({title:"上传成功",icon:"success"}),G()}catch(a){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1159","上传文件失败:",a),uni.showToast({title:"上传失败,请重试",icon:"error"})}},ce=e.ref([]),ie=e.ref(!1),re=e.computed((()=>ce.value)),ue=e.computed((()=>ce.value.filter((e=>e.team_id&&String(e.team_id)===String(Te.value))))),de=e.ref(!1),me=e.ref(""),ve=async()=>{ie.value=!0;try{const e=k(),t=await(e=>new Promise(((t,a)=>{uni.request({url:`${o}/cloud_api/database/list`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e},success:e=>{if(200===e.statusCode){const n=e.data;if(n.success)t(n.databases);else{const e=(null==n?void 0:n.error)||"获取用户可访问的数据库列表出错啦";a(e)}}else a(`获取用户可访问的数据库列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";a(t)}})})))(e);ce.value=t||[]}catch(e){t("error","at pages/CloudDatabase/CloudDatabase.vue:1185","获取数据库列表失败:",e),ce.value=[]}finally{ie.value=!1}},pe=()=>{de.value=!0,me.value=""},fe=()=>{de.value=!1,me.value=""},he=async()=>{const e=me.value.trim();if(e){uni.showLoading({title:"创建中..."});try{const t=k();await((e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/database/create`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,database_name:t},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)a(t.message);else{const e=(null==t?void 0:t.error)||"创建数据库出错啦";n(e)}}else n(`创建数据库失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(t,e),uni.hideLoading(),uni.showToast({title:"创建成功",icon:"success"}),fe(),await ve()}catch(a){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1216","创建数据库失败:",a),uni.showToast({title:"创建失败,请重试",icon:"error"})}}else uni.showToast({title:"请输入数据库名称",icon:"none"})},ge=e.ref(!1),we=e.ref(""),ke=e.ref(""),ye=()=>{ge.value=!0,we.value="",ke.value=""},Ee=()=>{ge.value=!1},Ne=()=>{oe({count:1,type:"all",success:e=>{const t=e.tempFiles[0];we.value=t.name||"unknown",ke.value=t.path},fail:e=>{t("error","at pages/CloudDatabase/CloudDatabase.vue:1245","选择文件失败:",e),uni.showToast({title:"选择文件失败",icon:"none"})}})},Ce=async()=>{var e;if(!ke.value)return void uni.showToast({title:"请选择数据库文件",icon:"none"});const a=null==(e=we.value.split(".").pop())?void 0:e.toLowerCase();if(["db","sqlite","sqlite3"].includes(a)){uni.showLoading({title:"上传中..."});try{const e=k();await((e,t)=>new Promise(((a,n)=>{const l="string"==typeof t?t:t.tempFilePath||t.path||t,s="string"==typeof t?t.split("/").pop()||"database.db":t.name||"database.db";uni.uploadFile({url:`${o}/cloud_api/database/upload/db`,method:"POST",header:{},formData:{access_token:e},file:{name:s,uri:l},files:[{name:"file",uri:l}],success:e=>{if(200===e.statusCode)try{const t=JSON.parse(e.data);if(t.success)a(t.message);else{const e=(null==t?void 0:t.error)||"上传db出错啦";n(e)}}catch(t){n("接口返回数据格式异常")}else n(`上传db失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(e,ke.value),uni.hideLoading(),uni.showToast({title:"上传成功",icon:"success"}),Ee(),await ve()}catch(n){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1273","上传数据库失败:",n),uni.showToast({title:"上传失败,请重试",icon:"error"})}}else uni.showToast({title:"仅支持 .db / .sqlite / .sqlite3 文件",icon:"none"})},be=e=>{uni.showModal({title:"删除数据库",content:`确定要删除数据库"${e.database_name}"吗?此操作不可恢复。`,success:async a=>{if(a.confirm){uni.showLoading({title:"删除中..."});try{const t=k();await((e,t)=>new Promise(((a,n)=>{uni.request({url:`${o}/cloud_api/database/delete`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,database_id:t},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)a(t.message);else{const e=(null==t?void 0:t.error)||"删除数据库出错啦";n(e)}}else n(`删除数据库失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";n(t)}})})))(t,e.database_id),uni.hideLoading(),uni.showToast({title:"删除成功",icon:"success"}),await ve()}catch(n){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1293","删除数据库失败:",n),uni.showToast({title:"删除失败,请重试",icon:"error"})}}}})},Ve=e=>{uni.navigateTo({url:`/pages/CloudDbDetail/CloudDbDetail?databaseId=${e.database_id}&databaseName=${encodeURIComponent(e.database_name)}&teamId=${e.team_id||""}`})},_e=e=>{if(!e)return"";const t=new Date(1e3*e);return`${t.getFullYear()}-${String(t.getMonth()+1).padStart(2,"0")}-${String(t.getDate()).padStart(2,"0")}`},Be=e=>({0:"无权限",1:"只读",2:"读写",3:"管理"}[e]||"未知"),Se=e.ref(!1),xe=e.ref([]),Te=e.ref(""),De=e.ref([]),je=e.ref(""),Pe=e.computed((()=>{if(!Te.value)return"";const e=xe.value.find((e=>e.id===Te.value));return(null==e?void 0:e.description)||""})),$e=e.computed((()=>{if(!Te.value)return"";const e=xe.value.find((e=>e.id===Te.value));return(null==e?void 0:e.type)||""})),Le=e.computed((()=>{if(!c.value||0===De.value.length)return"member";const e=De.value.find((e=>e.receiver===c.value||e.user_id===c.value));return(null==e?void 0:e.role)||"member"}));e.computed((()=>{const e=Le.value;return"admin"===e||"owner"===e}));const Me=async()=>{try{const e=k(),t=await m(e);xe.value=t||[]}catch(e){t("error","at pages/CloudDatabase/CloudDatabase.vue:1362","获取团队列表失败:",e),xe.value=[]}},Ie=async e=>{t("log","at pages/CloudDatabase/CloudDatabase.vue:1368","团队id为",e),Te.value=e;try{const t=k(),a=await v(t,e);De.value=(a||[]).map((e=>{var t,a,n,o,l;return{id:e._id,receiver:e.user_id,user_id:e.user_id,friendNickName:(null==(t=e.user)?void 0:t.username)||"",username:(null==(a=e.user)?void 0:a.username)||"",avatar:(null==(n=e.user)?void 0:n.avatar)||"",email:(null==(o=e.user)?void 0:o.email)||"",role:e.role||(null==(l=e.user)?void 0:l.role)||"member"}}))}catch(a){t("error","at pages/CloudDatabase/CloudDatabase.vue:1385","获取团队成员失败:",a),De.value=[]}T.value=[],g.value="云端数据",await z(e)},ze=async()=>{if(Te.value)try{const e=k(),t=await v(e,Te.value),a=(t||[]).find((e=>e.user_id===c.value)),n=(null==a?void 0:a.role)||"member";if("admin"!==n&&"owner"!==n)return void uni.showToast({title:"仅管理员可管理团队",icon:"none"});De.value=(t||[]).map((e=>{var t,a,n,o,l;return{id:e._id,receiver:e.user_id,user_id:e.user_id,friendNickName:(null==(t=e.user)?void 0:t.username)||"",username:(null==(a=e.user)?void 0:a.username)||"",avatar:(null==(n=e.user)?void 0:n.avatar)||"",email:(null==(o=e.user)?void 0:o.email)||"",role:e.role||(null==(l=e.user)?void 0:l.role)||"member"}}))}catch(e){return t("error","at pages/CloudDatabase/CloudDatabase.vue:1419","获取团队成员失败:",e),void uni.showToast({title:"获取团队信息失败",icon:"none"})}else if(xe.value.length>0){await Ie(xe.value[0].id),Se.value=!0;const e=De.value.find((e=>(e.receiver||e.user_id)===c.value)),t=(null==e?void 0:e.role)||"member";if("admin"!==t&&"owner"!==t)return Se.value=!1,void uni.showToast({title:"仅管理员可管理团队",icon:"none"})}Se.value=!0},Fe=()=>{Se.value=!1,je.value="",Ke.value=[],Ye.value=!1},Oe=e.ref(!1),Ae=e.ref(""),Ue=e.ref(""),qe=e.ref(""),We=()=>{const e=xe.value.find((e=>e.id===Te.value));e?(Ae.value=e.name||"",Ue.value=e.description||"",qe.value=e.type||"",Oe.value=!0):uni.showToast({title:"请先选择团队",icon:"none"})},Re=()=>{Oe.value=!1},Je=async()=>{const e=Ae.value.trim();if(e){uni.showLoading({title:"修改中..."});try{const t=k();await((e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/team/update`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_id:t,...a},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.message);else{const e=(null==t?void 0:t.error)||"修改团队信息出错啦";l(e)}}else l(`修改团队信息失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(t,Te.value,{team_name:e,team_description:Ue.value.trim(),team_type:qe.value.trim()}),uni.hideLoading(),uni.showToast({title:"修改成功",icon:"success"}),Re(),await Me(),Te.value=Te.value}catch(a){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1491","修改团队信息失败:",a),uni.showToast({title:"修改失败,请重试",icon:"error"})}}else uni.showToast({title:"请输入团队名称",icon:"none"})},He=async(e,a)=>{const n=e.friendNickName||e.username||e.name;uni.showModal({title:"admin"===a?"设为管理员":"降为成员",content:`确定将"${n}"${"admin"===a?"设为管理员":"降为普通成员"}吗?`,success:async n=>{if(n.confirm){uni.showLoading({title:"操作中..."});try{const t=k(),n=e.receiver||e.user_id;await((e,t,a,n)=>new Promise(((l,s)=>{uni.request({url:`${o}/cloud_api/team/adjust_member_role`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_id:t,user_id:a,role:n},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)l(t.message);else{const e=(null==t?void 0:t.error)||"调整团员身份出错啦";s(e)}}else s(`调整团员身份失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})))(t,Te.value,n,a),uni.hideLoading(),uni.showToast({title:"已"+("admin"===a?"设为管理员":"降为成员"),icon:"success"}),await Xe()}catch(l){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1516","调整成员身份失败:",l),uni.showToast({title:"操作失败,请重试",icon:"error"})}}}})},Ge=async e=>{const a=e.friendNickName||e.username||e.name;uni.showModal({title:"移除成员",content:`确定要移除"${a}"吗?`,success:async a=>{if(a.confirm){uni.showLoading({title:"移除中..."});try{const t=k(),a=e.receiver||e.user_id;await((e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/team/remove_member`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_id:t,user_ids:a},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.message);else{const e=(null==t?void 0:t.error)||"移除团队成员出错啦";l(e)}}else l(`移除团队成员失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(t,Te.value,[a]),uni.hideLoading(),uni.showToast({title:"已移除",icon:"success"}),await Xe()}catch(n){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1542","移除团队成员失败:",n),uni.showToast({title:"移除失败,请重试",icon:"error"})}}}})},Xe=async()=>{const e=k(),t=await v(e,Te.value);De.value=(t||[]).map((e=>{var t,a,n,o;return{id:e._id,receiver:e.user_id,user_id:e.user_id,friendNickName:(null==(t=e.user)?void 0:t.username)||"",username:(null==(a=e.user)?void 0:a.username)||"",avatar:(null==(n=e.user)?void 0:n.avatar)||"",email:(null==(o=e.user)?void 0:o.email)||"",role:e.role||"member"}}))},Ke=e.ref([]),Ye=e.ref(!1),Qe=async()=>{const e=je.value.trim();if(e)try{const t=k(),a=await i(t,e);Ke.value=a||[],Ye.value=!0,Ke.value.length}catch(a){t("error","at pages/CloudDatabase/CloudDatabase.vue:1584","搜索用户失败:",a),Ke.value=[],Ye.value=!0}else uni.showToast({title:"请输入用户名或邮箱",icon:"none"})},Ze=e=>{uni.showModal({title:"添加成员",content:`确定将"${e.username}"添加到当前团队吗?`,success:async a=>{if(a.confirm){uni.showLoading({title:"添加中..."});try{const t=k();await((e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/team/add_member`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,team_id:t,user_ids:a,role:"admin"},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.message);else{const e=(null==t?void 0:t.error)||"添加团队成员出错啦";l(e)}}else l(`添加团队成员失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(t,Te.value,[e._id]),uni.hideLoading(),uni.showToast({title:"添加成功",icon:"success"}),je.value="",Ke.value=[],Ye.value=!1,await Xe()}catch(n){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1610","添加团队成员失败:",n),uni.showToast({title:"添加失败,请重试",icon:"error"})}}}})},et=()=>{const e=xe.value.find((e=>e.id===Te.value)),a=e?e.name:"当前团队";uni.showModal({title:"删除团队",content:`确定要删除团队"${a}"吗?此操作不可撤销,团队内所有文件和数据将被永久删除。`,confirmText:"删除",confirmColor:"#e74c3c",success:async e=>{if(e.confirm){uni.showLoading({title:"删除中..."});try{await(a=l.value,n=Te.value,new Promise(((e,t)=>{uni.request({url:`${o}/cloud_api/team/delete`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:a,team_id:n},success:a=>{if(200===a.statusCode){const n=a.data;if(n.success)e(n.message);else{const e=(null==n?void 0:n.error)||"删除团队出错啦";t(e)}}else t(`删除团队失败:${a.statusCode}`)},fail:e=>{const a=e.errMsg||"网络错误";t(a)}})}))),uni.hideLoading(),uni.showToast({title:"团队已删除",icon:"success"}),Te.value="",De.value=[],x.value=[],T.value=[],g.value="云端数据",await Me(),Fe()}catch(s){uni.hideLoading(),t("error","at pages/CloudDatabase/CloudDatabase.vue:1644","删除团队失败:",s),uni.showToast({title:"删除失败,请重试",icon:"error"})}}var a,n}})};return e.onMounted((async()=>{await I(),await Me(),await ve()})),(t,n)=>{const o=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("view",{class:"status-bar"}),Se.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-overlay",onClick:Fe},[e.createElementVNode("view",{class:"popup-card",onClick:n[1]||(n[1]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:Fe},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"团队管理"),e.createElementVNode("scroll-view",{class:"team-manage-body","scroll-y":""},[0===De.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},"暂无团队成员")):(e.openBlock(),e.createElementBlock("view",{key:1,class:"member-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(De.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"member-item",key:t._id||t.receiver},[e.createElementVNode("view",{class:"member-avatar"},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"default-avatar"},[e.createVNode(o,{type:"person-filled",size:"60rpx",color:"#ffffff"})]))]),e.createElementVNode("view",{class:"member-info"},[e.createElementVNode("view",{class:"member-name"},e.toDisplayString(t.friendNickName||t.username||t.name),1),e.createElementVNode("view",{class:"member-label"},e.toDisplayString(t.email||t.sessionId||""),1)]),e.createElementVNode("view",{class:"member-actions"},[(t.receiver||t.user_id)===c.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:e.normalizeClass(["member-role",Le.value])},e.toDisplayString("owner"===Le.value?"创建者":"管理员"),3)):"owner"===t.role?(e.openBlock(),e.createElementBlock("view",{key:1,class:"member-role owner"},"创建者")):"admin"===t.role?(e.openBlock(),e.createElementBlock("view",{key:2,class:"member-actions-right"},[e.createElementVNode("view",{class:"member-action-btn demote-admin",onClick:e=>He(t,"member")},"降为成员",8,["onClick"]),e.createElementVNode("view",{class:"member-action-btn remove-member",onClick:e=>Ge(t)},"移除",8,["onClick"])])):(e.openBlock(),e.createElementBlock("view",{key:3,class:"member-actions-right"},[e.createElementVNode("view",{class:"member-action-btn set-admin",onClick:e=>He(t,"admin")},"设为管理",8,["onClick"]),e.createElementVNode("view",{class:"member-action-btn remove-member",onClick:e=>Ge(t)},"移除",8,["onClick"])]))])])))),128))]))]),e.createElementVNode("view",{class:"invite-section"},[e.createElementVNode("view",{class:"invite-input-wrapper"},[e.withDirectives(e.createElementVNode("input",{class:"invite-input",placeholder:"输入用户名或邮箱搜索","onUpdate:modelValue":n[0]||(n[0]=e=>je.value=e),onConfirm:Qe},null,544),[[e.vModelText,je.value]]),e.createElementVNode("view",{class:"invite-btn text-btn",onClick:Qe},"搜索")]),Ke.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"search-result-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Ke.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"search-result-item",key:t._id,onClick:e=>Ze(t)},[t.avatar?(e.openBlock(),e.createElementBlock("image",{key:0,src:t.avatar,class:"result-avatar",mode:"aspectFill"},null,8,["src"])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"result-default-avatar"},[e.createVNode(o,{type:"person-filled",size:"40rpx",color:"#fff"})])),e.createElementVNode("view",{class:"result-info"},[e.createElementVNode("text",{class:"result-name"},e.toDisplayString(t.username),1),e.createElementVNode("text",{class:"result-email"},e.toDisplayString(t.email),1)]),e.createElementVNode("view",{class:"result-add-btn"},"添加")],8,["onClick"])))),128))])):je.value&&Ye.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"search-empty"},"未找到匹配用户")):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"edit-team-section"},[e.createElementVNode("view",{class:"edit-team-btn",onClick:We},"修改团队信息")]),e.createElementVNode("view",{class:"delete-team-section"},[e.createElementVNode("view",{class:"delete-team-btn",onClick:et},"删除团队")])])])):e.createCommentVNode("",!0),Oe.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"popup-overlay",onClick:Re},[e.createElementVNode("view",{class:"popup-card",onClick:n[4]||(n[4]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:Re},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"修改团队信息"),e.createElementVNode("view",{class:"edit-team-form"},[e.createElementVNode("view",{class:"form-label"},"团队名称"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[2]||(n[2]=e=>Ae.value=e),type:"text",placeholder:"输入团队名称"},null,512),[[e.vModelText,Ae.value]])]),e.createElementVNode("view",{class:"form-label"},"团队描述"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[3]||(n[3]=e=>Ue.value=e),type:"text",placeholder:"输入团队描述"},null,512),[[e.vModelText,Ue.value]])])]),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:Re},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:Je},"确认修改")])])])):e.createCommentVNode("",!0),X.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:"popup-overlay",onClick:Y},[e.createElementVNode("view",{class:"popup-card",onClick:n[6]||(n[6]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:Y},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"新建"+e.toDisplayString("user"===f.value?"个人":"团队")+"目录",1),e.createElementVNode("view",{class:"new-folder-name"},"目录名称"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[5]||(n[5]=e=>K.value=e),type:"text",placeholder:"输入目录名称"},null,512),[[e.vModelText,K.value]])]),e.createElementVNode("view",{class:"nf-path-label"},"当前路径"),e.createElementVNode("view",{class:"nf-path-display"},e.toDisplayString($.value),1),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:Y},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:Q},"确认")])])])):e.createCommentVNode("",!0),Z.value?(e.openBlock(),e.createElementBlock("view",{key:3,class:"popup-overlay",onClick:ae},[e.createElementVNode("view",{class:"popup-card",onClick:n[8]||(n[8]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:ae},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"上传文件"),e.createElementVNode("view",{class:"upload-path-label"},"上传路径"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[7]||(n[7]=e=>ee.value=e),type:"text",placeholder:"输入上传路径,如:/myfolder"},null,512),[[e.vModelText,ee.value]])]),e.createElementVNode("view",{class:"upload-path-hint"},"默认为根目录 /,后端会自动创建不存在的文件夹"),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:ae},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:ne},"确认上传")])])])):e.createCommentVNode("",!0),de.value?(e.openBlock(),e.createElementBlock("view",{key:4,class:"popup-overlay",onClick:fe},[e.createElementVNode("view",{class:"popup-card",onClick:n[10]||(n[10]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:fe},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"新建个人数据库"),e.createElementVNode("view",{class:"new-folder-name"},"数据库名称"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":n[9]||(n[9]=e=>me.value=e),type:"text",placeholder:"输入数据库名称"},null,512),[[e.vModelText,me.value]])]),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:fe},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:he},"确认")])])])):e.createCommentVNode("",!0),ge.value?(e.openBlock(),e.createElementBlock("view",{key:5,class:"popup-overlay",onClick:Ee},[e.createElementVNode("view",{class:"popup-card",onClick:n[11]||(n[11]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:Ee},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"上传数据库文件"),e.createElementVNode("view",{class:"upload-db-hint"},"支持 .db / .sqlite / .sqlite3 格式的 SQLite 数据库文件"),e.createElementVNode("view",{class:"upload-file-area",onClick:Ne},[we.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"selected-file"},e.toDisplayString(we.value),1)):(e.openBlock(),e.createElementBlock("view",{key:1,class:"upload-hint"},"点击选择数据库文件"))]),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:Ee},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:Ce},"确认上传")])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"cloud-db-container page-container"},[e.createElementVNode("view",{class:"cloud-db-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:V},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"}),T.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"navbar-before-title"},e.toDisplayString(b.value),1)):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"navbar-title"},e.toDisplayString(g.value),1),e.createElementVNode("view",{class:"navbar-right"}),y.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:n[12]||(n[12]=e=>{E.value=!E.value,E.value||(N.value=[]),C()})},"选择"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item",onClick:n[13]||(n[13]=e=>{X.value=!0,K.value="",C()})},"新建文件夹")])):e.createCommentVNode("",!0)]),e.createElementVNode("view",{class:"category-tabs"},[e.createElementVNode("view",{class:e.normalizeClass(["category-tab",{active:"user"===f.value}]),onClick:n[14]||(n[14]=e=>h("user"))}," 个人 ",2),e.createElementVNode("view",{class:e.normalizeClass(["category-tab",{active:"team"===f.value}]),onClick:n[15]||(n[15]=e=>h("team"))}," 团队 ",2)])]),e.createElementVNode("scroll-view",{class:"cloud-db-content","scroll-y":""},["user"===f.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("view",{class:"section-block"},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createElementVNode("text",null,"云端文件"),e.createElementVNode("text",{class:"file-count"},e.toDisplayString(L.value>0?"("+L.value+")":""),1)]),e.createElementVNode("view",{class:"section-actions"},[e.createElementVNode("view",{class:"action-btn",onClick:te},[e.createVNode(o,{type:"upload",size:"16"}),e.createElementVNode("text",null,"上传文件")])])]),e.createElementVNode("view",{class:"section-body"},[0===S.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"empty-tip"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createElementVNode("text",null,"暂无云端文件")])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"file-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"file-item",key:t.id,onClick:e=>F(t),onLongpress:e=>O(t)},[e.createElementVNode("view",{class:e.normalizeClass(["file-icon",D(t)?"is-directory":"is-file"])},[e.createElementVNode("view",{class:e.normalizeClass(["iconfont",j(t)])},null,2)],2),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-meta"},[e.createElementVNode("text",{class:"file-type-tag"},e.toDisplayString(D(t)?"目录":"文件"),1),t.size?(e.openBlock(),e.createElementBlock("text",{key:0,class:"file-size"},e.toDisplayString(P(t.size)),1)):e.createCommentVNode("",!0)])],40,["onClick","onLongpress"])))),128))]))])]),e.createElementVNode("view",{class:"section-divider"}),e.createElementVNode("view",{class:"section-block"},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-shujuku"}),e.createElementVNode("text",null,"云端数据库"),e.createElementVNode("text",{class:"file-count"},e.toDisplayString(!ie.value&&re.value.length>0?"("+re.value.length+")":""),1)]),e.createElementVNode("view",{class:"section-actions"},[e.createElementVNode("view",{class:"action-btn",onClick:ye},[e.createVNode(o,{type:"upload",size:"16"}),e.createElementVNode("text",null,"上传数据库")]),e.createElementVNode("view",{class:"action-btn",onClick:pe},[e.createVNode(o,{type:"plus",size:"16"}),e.createElementVNode("text",null,"新建数据库")])])]),e.createElementVNode("view",{class:"section-body"},[ie.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"loading-area"},[e.createElementVNode("view",{class:"loading-spinner"}),e.createElementVNode("text",{class:"loading-text"},"加载中...")])):0===re.value.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"empty-tip"},[e.createElementVNode("view",{class:"iconfont icon-shujuku"}),e.createElementVNode("text",null,"暂无数据库")])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"table-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(re.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"table-item",key:t.database_id,onClick:e=>Ve(t),onLongpress:e=>be(t)},[e.createElementVNode("view",{class:"table-icon"},[e.createVNode(o,{type:"compose",size:"22",color:"#3b86ff"})]),e.createElementVNode("view",{class:"table-info"},[e.createElementVNode("view",{class:"table-name"},[e.createTextVNode(e.toDisplayString(t.database_name)+" ",1),e.createElementVNode("text",{class:e.normalizeClass(["db-tag",t.team_id?"tag-team":"tag-personal"])},e.toDisplayString(t.team_id?"团队共享":"个人私有"),3)]),e.createElementVNode("view",{class:"table-desc"},e.toDisplayString(t.table_count||0)+" 张表 · "+e.toDisplayString(Be(t.access_level)),1)]),e.createElementVNode("view",{class:"table-meta"},[e.createElementVNode("text",{class:"table-rows"},e.toDisplayString(_e(t.modified_time)),1),e.createVNode(o,{type:"right",size:"14",color:"#999"})])],40,["onClick","onLongpress"])))),128))]))])])],64)):e.createCommentVNode("",!0),"team"===f.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("view",{class:"section-block team-manage-block",onClick:ze},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-qunliao"}),e.createElementVNode("text",null,"团队管理")]),e.createElementVNode("view",{class:"section-actions"},[e.createElementVNode("text",{class:"team-count"},e.toDisplayString(xe.value.length)+" 个团队",1),e.createVNode(o,{type:"right",size:"14",color:"#999"})])])]),e.createElementVNode("view",{class:"section-divider"}),xe.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:0,class:"team-selector"},[e.createElementVNode("scroll-view",{"scroll-x":"",class:"team-scroll"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(xe.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["team-chip",{active:Te.value===t.id}]),key:t.id,onClick:e=>Ie(t.id)},e.toDisplayString(t.name),11,["onClick"])))),128))]),$e.value||Pe.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"team-info"},[$e.value?(e.openBlock(),e.createElementBlock("text",{key:0,class:"team-type-tag"},e.toDisplayString($e.value),1)):e.createCommentVNode("",!0),Pe.value?(e.openBlock(),e.createElementBlock("text",{key:1,class:"team-desc-text"},e.toDisplayString(Pe.value),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),!Te.value&&xe.value.length>0?(e.openBlock(),e.createElementBlock("view",{key:1,class:"empty-tip select-team-tip"},[e.createElementVNode("view",{class:"iconfont icon-qunliao"}),e.createElementVNode("text",null,"请选择一个团队")])):e.createCommentVNode("",!0),Te.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:"section-block"},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createElementVNode("text",null,"团队云端文件")]),e.createElementVNode("view",{class:"section-actions"},[e.createElementVNode("view",{class:"action-btn",onClick:te},[e.createVNode(o,{type:"upload",size:"16"}),e.createElementVNode("text",null,"上传文件")])])]),e.createElementVNode("view",{class:"section-body"},[0===x.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"empty-tip"},[e.createElementVNode("view",{class:"iconfont icon-wenjianjia"}),e.createElementVNode("text",null,"暂无团队云端文件")])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"file-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"file-item",key:t.id,onClick:e=>F(t),onLongpress:e=>O(t)},[e.createElementVNode("view",{class:e.normalizeClass(["file-icon",D(t)?"is-directory":"is-file"])},[e.createElementVNode("view",{class:e.normalizeClass(["iconfont",j(t)])},null,2)],2),e.createElementVNode("view",{class:"file-name"},e.toDisplayString(t.name),1),e.createElementVNode("view",{class:"file-meta"},[e.createElementVNode("text",{class:"file-type-tag"},e.toDisplayString(D(t)?"目录":"文件"),1),t.size?(e.openBlock(),e.createElementBlock("text",{key:0,class:"file-size"},e.toDisplayString(P(t.size)),1)):e.createCommentVNode("",!0)])],40,["onClick","onLongpress"])))),128))]))])])):e.createCommentVNode("",!0),Te.value?(e.openBlock(),e.createElementBlock("view",{key:3,class:"section-divider"})):e.createCommentVNode("",!0),Te.value?(e.openBlock(),e.createElementBlock("view",{key:4,class:"section-block"},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-shujuku"}),e.createElementVNode("text",null,"团队云端数据库")])]),e.createElementVNode("view",{class:"section-body"},[ie.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"loading-area"},[e.createElementVNode("view",{class:"loading-spinner"}),e.createElementVNode("text",{class:"loading-text"},"加载中...")])):0===ue.value.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"empty-tip"},[e.createElementVNode("view",{class:"iconfont icon-shujuku"}),e.createElementVNode("text",null,"暂无团队数据库")])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"table-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ue.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"table-item",key:t.database_id,onClick:e=>Ve(t)},[e.createElementVNode("view",{class:"table-icon"},[e.createVNode(o,{type:"compose",size:"22",color:"#3b86ff"})]),e.createElementVNode("view",{class:"table-info"},[e.createElementVNode("view",{class:"table-name"},[e.createTextVNode(e.toDisplayString(t.database_name)+" ",1),e.createElementVNode("text",{class:"db-tag tag-team"},"团队共享")]),e.createElementVNode("view",{class:"table-desc"},e.toDisplayString(t.table_count||0)+" 张表 · "+e.toDisplayString(Be(t.access_level)),1)]),e.createElementVNode("view",{class:"table-meta"},[e.createElementVNode("text",{class:"table-rows"},e.toDisplayString(_e(t.modified_time)),1),e.createVNode(o,{type:"right",size:"14",color:"#999"})])],8,["onClick"])))),128))]))])])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)])])],64)}}},[["__scopeId","data-v-2d96f7d1"]]),ve=f({__name:"CloudDbDetail",props:{databaseId:{type:String,default:""},databaseName:{type:String,default:""},teamId:{type:String,default:""}},setup(n){const l=n,s=e.ref(l.databaseId||""),c=e.ref(l.databaseName||""),i=e.ref(l.teamId||""),r=e.ref(2),u=e.ref(0),d=e.ref([]),v=e.ref(!1),f=e.ref(null),h=e.ref([]),g=e.computed((()=>{var e;if(h.value.length>0){const e=new Set;return h.value.forEach((t=>Object.keys(t).forEach((t=>e.add(t))))),Array.from(e).filter((e=>"_row_id"!==e&&"_id"!==e))}return(null==(e=f.value)?void 0:e.columns)?f.value.columns.map((e=>e.name)).filter((e=>"_row_id"!==e)):[]})),y=e.ref(!1),E=()=>{y.value=!y.value},C=()=>{uni.navigateBack()},b=async()=>{v.value=!0;try{const e=k(),t=await((e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/database/tables`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,database_id:t,is_detail:a},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)n(t.tables);else{const e=(null==t?void 0:t.error)||"获取用户可访问的数据库列表出错啦";l(e)}}else l(`获取用户可访问的数据库列表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(e,s.value,!0);d.value=(t||[]).map((e=>({table_name:e.name,row_count:e.row_count||0,columns:e.columns||[]}))),u.value=d.value.length}catch(e){t("error","at pages/CloudDbDetail/CloudDbDetail.vue:282","获取表列表失败:",e),d.value=[]}finally{v.value=!1}},V=async e=>{f.value=e,h.value=[],uni.showLoading({title:"加载中..."});try{const t=k(),a=await((e,t,a,n="20",l="0")=>new Promise(((s,c)=>{uni.request({url:`${o}/cloud_api/database/table/data`,method:"POST",header:{"Content-Type":"application/json"},data:{access_token:e,database_id:t,table_name:a,limit:n,offset:l},success:e=>{if(200===e.statusCode){const t=e.data;if(t.success)s(t.data);else{const e=(null==t?void 0:t.error)||"获取表数据出错啦";c(e)}}else c(`获取表数据失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";c(t)}})})))(t,s.value,e.table_name);h.value=a||[],uni.hideLoading()}catch(t){uni.hideLoading(),uni.showToast({title:"string"==typeof t?t:"加载表数据失败",icon:"none"}),h.value=[]}},_=e=>{uni.showModal({title:"删除表",content:`确定要删除表"${e.table_name}"吗?此操作不可恢复。`,success:async a=>{var n;if(a.confirm){uni.showLoading({title:"删除中..."});try{const t=k();await(async(e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/database/table/drop`,method:"POST",data:{access_token:e,database_id:t,table_name:a},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)n(t.message);else{const e=t.error||"删除数据库中的表出错啦";l(e)}}else l(`删除数据库中的表失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(t,s.value,e.table_name),uni.hideLoading(),uni.showToast({title:"删除成功",icon:"success"}),(null==(n=f.value)?void 0:n.table_name)===e.table_name&&(f.value=null,h.value=[]),await b()}catch(l){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:335","删除表失败:",l),uni.showToast({title:"删除失败,请重试",icon:"error"})}}}})},B=e=>{const a=e._row_id||e._id;if(!a)return void uni.showToast({title:"无法识别该行",icon:"none"});const n=g.value;if(0===n.length)return void uni.showToast({title:"无可用列",icon:"none"});const l=n[0];uni.showModal({title:`编辑 ${l}`,editable:!0,placeholderText:e[l]||"",content:"",success:async n=>{if(n.confirm&&void 0!==n.content){uni.showLoading({title:"更新中..."});try{const t=k();await((e,t,a,n,l)=>new Promise(((s,c)=>{uni.request({url:`${o}/cloud_api/database/table/update/by/id`,method:"POST",data:{access_token:e,database_id:t,table_name:a,where_data:n,update_data:l},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)s(t.message);else{const e=t.error||"更新表数据出错啦";c(e)}}else c(`更新表数据失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";c(t)}})})))(t,s.value,f.value.table_name,{_row_id:a},{[l]:n.content}),uni.hideLoading(),uni.showToast({title:"更新成功",icon:"success"}),e[l]=n.content}catch(c){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:397","更新失败:",c),uni.showToast({title:c,icon:"error"})}}}})},S=e.ref(!1),x=e.ref(""),T=e.ref(""),D=e.ref(""),j=()=>{S.value=!1},P=()=>{oe({count:1,type:"all",success:e=>{const t=e.tempFiles[0];T.value=t.name||"unknown",D.value=t.path},fail:e=>{t("error","at pages/CloudDbDetail/CloudDbDetail.vue:434","选择文件失败:",e),uni.showToast({title:"选择文件失败",icon:"none"})}})},$=async()=>{const e=x.value.trim()||"";if(D.value){uni.showLoading({title:"导入中..."});try{const t=k();await((e,t,a,n,l)=>new Promise(((s,c)=>{const i="string"==typeof n?n:n.tempFilePath||n.path||n,r="string"==typeof n?n.split("/").pop()||"file":n.name||"file";uni.uploadFile({url:`${o}/cloud_api/database/import`,method:"POST",header:{},formData:{access_token:e,force_overwrite:t,database_id:a,table_name:l},file:{name:r,uri:i},files:[{name:"file",uri:i}],success:e=>{if(200===e.statusCode)try{const t=JSON.parse(e.data);if(t.success)s(t.message);else{const e=(null==t?void 0:t.error)||"导入文件到数据库出错啦";c(e)}}catch(t){c("接口返回数据格式异常")}else c(`导入文件到数据库失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";c(t)}})})))(t,!1,s.value,D.value,e),uni.hideLoading(),uni.showToast({title:"导入成功",icon:"success"}),j(),await b()}catch(a){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:474","导入失败:",a),"table_exists"===a?uni.showToast({title:"文件已存在",icon:"error"}):uni.showToast({title:"导入失败,请重试",icon:"error"})}}else uni.showToast({title:"请选择文件",icon:"none"})},L=e.ref(!1),M=e.ref([]),I=async()=>{L.value=!0,uni.showLoading({title:"加载中..."});try{const e=k();let t;t=i.value?await p(e,s.value,"team_id",i.value):await p(e,s.value,"user_id",N());const a=Array.isArray(t)?t:[];M.value=a.map((e=>{var t,a,n;return e.team?{_id:e._id,database_id:e.database_id,access_level:e.access_level,permType:"team_id",id:e.team._id||e.team.id,name:e.team.name}:e.team_id?{database_id:e.database_id,access_level:e.access_level,permType:"team_id",id:e.team_id,name:(null==(t=e.database)?void 0:t.database_name)||""}:{database_id:e.database_id,access_level:e.access_level,permType:"user_id",id:e.user_id||(null==(a=e.database)?void 0:a.user_id)||N(),name:(null==(n=e.database)?void 0:n.database_name)||""}}))}catch(e){t("error","at pages/CloudDbDetail/CloudDbDetail.vue:544","获取权限失败:",e),M.value=[]}uni.hideLoading()},z=()=>{L.value=!1},F=(e,a)=>{if("delete"===a)uni.showModal({title:"移除权限",content:`确定要移除"${e.name}"的权限吗?`,success:async a=>{if(a.confirm){uni.showLoading({title:"移除中..."});try{const t=k();await((e,t,a,n)=>new Promise(((l,s)=>{const c={access_token:e,database_id:t};"user_id"===a?c.user_id=n:"team_id"===a&&(c.team_id=n),uni.request({url:`${o}/cloud_api/database/permission/delete`,method:"POST",data:c,header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)l(t.message);else{const e=t.error||"删除 团队/用户 对数据库权限出错啦";s(e)}}else s(`删除 团队/用户 对数据库权限失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";s(t)}})})))(t,s.value,e.permType,e.id),uni.hideLoading(),uni.showToast({title:"已移除",icon:"success"}),await I()}catch(n){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:574","移除权限失败:",n),uni.showToast({title:"操作失败,请重试",icon:"error"})}}}});else{const a=["无权限访问","仅访问","管理员完全控制","团队完全控制"],n=e.access_level||0;uni.showActionSheet({title:"选择权限级别",itemList:a.map(((e,t)=>`${t}. ${e}`)),success:async a=>{const l=a.tapIndex;if(l!==n){uni.showLoading({title:"更新中..."});try{const t=k();await((e,t,a,n,l)=>new Promise(((s,c)=>{const i={access_token:e,database_id:t,access_level:l};"user_id"===a?i.user_id=n:"team_id"===a&&(i.team_id=n),uni.request({url:`${o}/cloud_api/database/permission/update`,method:"POST",data:i,header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)s(t.message);else{const e=t.error||"修改/增加 团队/用户 对数据库权限出错啦";c(e)}}else c(`修改/增加 团队/用户 对数据库权限失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";c(t)}})})))(t,s.value,e.permType,e.id,l),uni.hideLoading(),uni.showToast({title:"已更新",icon:"success"}),await I()}catch(c){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:608","更新权限失败:",c),uni.showToast({title:"操作失败,请重试",icon:"error"})}}}})}},O=e.ref(!1),A=e.ref([]),U=e.ref(""),q=()=>{O.value=!1},W=async()=>{U.value?uni.showModal({title:"确认移交",content:"移交后数据库将归属于该团队,确定继续吗?",success:async e=>{if(e.confirm){uni.showLoading({title:"移交中..."});try{const e=k();await(async(e,t,a)=>new Promise(((n,l)=>{uni.request({url:`${o}/cloud_api/database/transfer_to_team`,method:"POST",data:{access_token:e,database_id:t,team_id:a},header:{"Content-Type":"application/json"},success:e=>{if(200===e.statusCode){const t=e.data;if(null==t?void 0:t.success)n(t.message);else{const e=t.error||"个人数据库移交团队出错啦";l(e)}}else l(`个人数据库移交团队失败:${e.statusCode}`)},fail:e=>{const t=e.errMsg||"网络错误";l(t)}})})))(e,s.value,U.value),uni.hideLoading(),uni.showToast({title:"移交成功",icon:"success"}),q(),setTimeout((()=>{uni.navigateBack()}),1e3)}catch(a){uni.hideLoading(),t("error","at pages/CloudDbDetail/CloudDbDetail.vue:670","移交失败:",a),uni.showToast({title:"移交失败,请重试",icon:"error"})}}}}):uni.showToast({title:"请选择目标团队",icon:"none"})},R=e=>({0:"无权限访问",1:"仅访问",2:"管理员完全控制",3:"团队完全控制"}[e]||"未知");return e.onMounted((()=>{var e;const t=getCurrentPages(),a=t[t.length-1],n=(null==(e=a.$page)?void 0:e.options)||a.options||{};s.value=n.databaseId||"",c.value=decodeURIComponent(n.databaseName||"数据库详情"),i.value=n.teamId||"",s.value&&b()})),(n,o)=>{const l=a(e.resolveDynamicComponent("uni-icons"),w);return e.openBlock(),e.createElementBlock("view",{class:"cloud-db-detail-wrapper"},[e.createElementVNode("view",{class:"status-bar"}),S.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"popup-overlay",onClick:j},[e.createElementVNode("view",{class:"popup-card",onClick:o[1]||(o[1]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:j},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"导入文件到数据库"),e.createElementVNode("view",{class:"new-folder-name"},"表名称"),e.createElementVNode("view",{class:"create-folder-name"},[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":o[0]||(o[0]=e=>x.value=e),type:"text",placeholder:"输入表名称"},null,512),[[e.vModelText,x.value]])]),e.createElementVNode("view",{class:"new-folder-name"},"文件"),e.createElementVNode("view",{class:"upload-file-area",onClick:P},[T.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"selected-file"},e.toDisplayString(T.value),1)):(e.openBlock(),e.createElementBlock("view",{key:1,class:"upload-hint"},"点击选择文件(支持 CSV/Excel/SQLite)"))]),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:j},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:$},"确认导入")])])])):e.createCommentVNode("",!0),L.value?(e.openBlock(),e.createElementBlock("view",{key:1,class:"popup-overlay",onClick:z},[e.createElementVNode("view",{class:"popup-card",onClick:o[2]||(o[2]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:z},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"权限管理"),e.createElementVNode("scroll-view",{class:"permission-body","scroll-y":""},[0===M.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},"暂无权限记录")):(e.openBlock(),e.createElementBlock("view",{key:1,class:"permission-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"permission-item",key:t._id||t.id},[e.createElementVNode("view",{class:"perm-info"},[e.createElementVNode("text",{class:"perm-type"},e.toDisplayString("team_id"===t.permType?"团队":"个人"),1)]),e.createElementVNode("view",{class:"perm-level"},e.toDisplayString(R(t.access_level)),1),e.createElementVNode("view",{class:"perm-actions"},[e.createElementVNode("view",{class:"perm-action-btn",onClick:e=>F(t,"change")},"修改",8,["onClick"]),e.createElementVNode("view",{class:"perm-action-btn delete",onClick:e=>F(t,"delete")},"移除",8,["onClick"])])])))),128))]))]),e.createElementVNode("view",{class:"close-permission-btn",onClick:z},"关闭")])])):e.createCommentVNode("",!0),O.value?(e.openBlock(),e.createElementBlock("view",{key:2,class:"popup-overlay",onClick:q},[e.createElementVNode("view",{class:"popup-card",onClick:o[3]||(o[3]=e.withModifiers((()=>{}),["stop"]))},[e.createElementVNode("view",{class:"close-popup-card",onClick:q},[e.createElementVNode("view",{class:"iconfont icon-quxiao"})]),e.createElementVNode("view",{class:"popup-title"},"移交数据库到团队"),e.createElementVNode("scroll-view",{class:"transfer-body","scroll-y":""},[0===A.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"folder-null"},"暂无可用团队")):(e.openBlock(),e.createElementBlock("view",{key:1,class:"transfer-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:e.normalizeClass(["transfer-item",{active:U.value===t.id}]),key:t.id,onClick:e=>U.value=t.id},[e.createElementVNode("text",{class:"transfer-name"},e.toDisplayString(t.name),1),U.value===t.id?(e.openBlock(),e.createBlock(l,{key:0,type:"checkmarkempty",size:"20",color:"#3b86ff"})):e.createCommentVNode("",!0)],10,["onClick"])))),128))]))]),e.createElementVNode("view",{class:"option-wrapper"},[e.createElementVNode("view",{class:"opt-btn opt-cancel",onClick:q},"取消"),e.createElementVNode("view",{class:"opt-btn opt-confirm",onClick:W},"确认移交")])])])):e.createCommentVNode("",!0),e.createElementVNode("view",{class:"cloud-db-detail page-container"},[e.createElementVNode("view",{class:"cloud-db-header"},[e.createElementVNode("view",{class:"custom-navbar"},[e.createElementVNode("view",{class:"navbar-left",onClick:C},[e.createElementVNode("view",{class:"iconfont icon-fanhui custom-navbar-icon"})]),e.createElementVNode("view",{class:"navbar-title"},e.toDisplayString(c.value),1),e.createElementVNode("view",{class:"navbar-right"},[e.createElementVNode("view",{class:"iconfont icon-gengduo custom-navbar-icon",onClick:E})])]),y.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"menu-card"},[e.createElementVNode("view",{class:"menu-card-item",onClick:o[4]||(o[4]=e=>{S.value=!0,x.value="",T.value="",D.value="",E()})},"导入文件"),e.createElementVNode("view",{class:"solid-line"}),e.createElementVNode("view",{class:"menu-card-item",onClick:o[5]||(o[5]=e=>{I(),E()})},"权限管理"),i.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:0,class:"solid-line"})),i.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("view",{key:1,class:"menu-card-item",onClick:o[6]||(o[6]=e=>{(async()=>{O.value=!0,U.value="";try{const e=k(),t=await m(e);A.value=t||[]}catch(e){t("error","at pages/CloudDbDetail/CloudDbDetail.vue:632","获取团队列表失败:",e),A.value=[]}})(),E()})},"移交团队"))])):e.createCommentVNode("",!0)]),e.createElementVNode("scroll-view",{class:"cloud-db-content","scroll-y":""},[e.createElementVNode("view",{class:"db-info-bar"},[e.createElementVNode("text",{class:"db-info-text"},e.toDisplayString(u.value)+" 张表",1),e.createElementVNode("text",{class:"db-info-text"},"权限:"+e.toDisplayString(R(r.value)),1)]),e.createElementVNode("view",{class:"section-block"},[e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-biaoge"}),e.createElementVNode("text",null,"数据表")])]),e.createElementVNode("view",{class:"section-body"},[v.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"loading-area"},[e.createElementVNode("view",{class:"loading-spinner"}),e.createElementVNode("text",{class:"loading-text"},"加载中...")])):0===d.value.length?(e.openBlock(),e.createElementBlock("view",{key:1,class:"empty-tip"},[e.createElementVNode("view",{class:"iconfont icon-shujuku"}),e.createElementVNode("text",null,"暂无数据表")])):(e.openBlock(),e.createElementBlock("view",{key:2,class:"table-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(t=>(e.openBlock(),e.createElementBlock("view",{class:"table-item",key:t.table_name,onClick:e=>V(t),onLongpress:e=>_(t)},[e.createElementVNode("view",{class:"table-icon"},[e.createVNode(l,{type:"compose",size:"22",color:"#3b86ff"})]),e.createElementVNode("view",{class:"table-info"},[e.createElementVNode("view",{class:"table-name"},e.toDisplayString(t.table_name),1),e.createElementVNode("view",{class:"table-desc"},e.toDisplayString(t.row_count||0)+" 条记录",1)]),e.createElementVNode("view",{class:"table-meta"},[e.createVNode(l,{type:"right",size:"14",color:"#999"})])],40,["onClick","onLongpress"])))),128))]))])]),f.value?(e.openBlock(),e.createElementBlock("view",{key:0,class:"section-block"},[e.createElementVNode("view",{class:"section-divider"}),e.createElementVNode("view",{class:"section-header"},[e.createElementVNode("view",{class:"section-title"},[e.createElementVNode("view",{class:"iconfont icon-biaoge"}),e.createElementVNode("text",null,e.toDisplayString(f.value.table_name),1)]),e.createElementVNode("view",{class:"section-actions"},[e.createElementVNode("text",{class:"row-count"},e.toDisplayString(h.value.length)+" / "+e.toDisplayString(f.value.row_count||0)+" 条",1)])]),e.createElementVNode("view",{class:"section-body"},[0===h.value.length?(e.openBlock(),e.createElementBlock("view",{key:0,class:"empty-tip"},[e.createElementVNode("text",null,"暂无数据")])):(e.openBlock(),e.createElementBlock("view",{key:1,class:"data-table-wrapper"},[e.createElementVNode("scroll-view",{"scroll-x":"",class:"data-table-scroll"},[e.createElementVNode("view",{class:"data-table"},[e.createElementVNode("view",{class:"data-row data-header"},[e.createElementVNode("view",{class:"data-cell index-cell"},"#"),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(t=>(e.openBlock(),e.createElementBlock("view",{key:t,class:"data-cell"},e.toDisplayString(t),1)))),128))]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,((t,a)=>(e.openBlock(),e.createElementBlock("view",{class:"data-row",key:t._row_id||a,onClick:e=>B(t)},[e.createElementVNode("view",{class:"data-cell index-cell"},e.toDisplayString(a+1),1),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(a=>{return e.openBlock(),e.createElementBlock("view",{key:a,class:"data-cell"},e.toDisplayString(null==(n=t[a])?"":"object"==typeof n?JSON.stringify(n):String(n)),1);var n})),128))],8,["onClick"])))),128))])])]))])])):e.createCommentVNode("",!0)])])])}}},[["__scopeId","data-v-144a6cf9"]]);__definePage("pages/Login/Login",h),__definePage("pages/Chat/Chat",le),__definePage("pages/WorkSpace/WorkSpace",se),__definePage("pages/UserProfileModal/UserProfileModal",ce),__definePage("pages/ContactPages/ContactPages",ie),__definePage("pages/WorkSpace/TemplateSpace/TemplateSpace",re),__definePage("pages/text/text",ue),__definePage("pages/text/text2",de),__definePage("pages/CloudDatabase/CloudDatabase",me),__definePage("pages/CloudDbDetail/CloudDbDetail",ve);const pe={onLaunch:function(){t("log","at App.vue:4","App Launch")},onShow:function(){t("log","at App.vue:7","App Show")},onHide:function(){t("log","at App.vue:10","App Hide")}};const{app:fe,Vuex:he,Pinia:ge}=function(){const t=e.createVueApp(pe),a=function(){const t=e.effectScope(!0),a=t.run((()=>e.ref({})));let n=[],o=[];const l=e.markRaw({install(e){x(l),l._a=e,e.provide(T,l),e.config.globalProperties.$pinia=l,o.forEach((e=>n.push(e))),o=[]},use(e){return this._a?n.push(e):o.push(e),this},_p:n,_a:null,_e:t,_s:new Map,state:a});return l}();return t.use(a),{app:t,pinia:a}}();uni.Vuex=he,uni.Pinia=ge,fe.provide("__globalStyles",__uniConfig.styles),fe._component.mpType="app",fe._component.render=()=>{},fe.mount("#app")}(Vue); diff --git a/unpackage/dist/build/app-plus/app.css b/unpackage/dist/build/app-plus/app.css index 766d33e..526cbeb 100644 --- a/unpackage/dist/build/app-plus/app.css +++ b/unpackage/dist/build/app-plus/app.css @@ -1,3 +1,3 @@ *{margin:0;-webkit-tap-highlight-color:rgba(0,0,0,0);-webkit-tap-highlight-color:transparent}html,body{-webkit-user-select:none;user-select:none;width:100%}html{height:100%;height:100vh;width:100%;width:100vw}body{overflow-x:hidden;background-color:#fff;height:100%;font-size:16px}#app{height:100%}input[type=search]::-webkit-search-cancel-button{display:none}.uni-loading,uni-button[loading]:before{background:transparent url(data:image/svg+xml;base64,\ PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMjAiIGhlaWdodD0iMTIwIiB2aWV3Qm94PSIwIDAgMTAwIDEwMCI+PHBhdGggZmlsbD0ibm9uZSIgZD0iTTAgMGgxMDB2MTAwSDB6Ii8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjRTlFOUU5IiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0idHJhbnNsYXRlKDAgLTMwKSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iIzk4OTY5NyIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgzMCAxMDUuOTggNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjOUI5OTlBIiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKDYwIDc1Ljk4IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0EzQTFBMiIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSg5MCA2NSA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNBQkE5QUEiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoMTIwIDU4LjY2IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0IyQjJCMiIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgxNTAgNTQuMDIgNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjQkFCOEI5IiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKDE4MCA1MCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNDMkMwQzEiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTE1MCA0NS45OCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNDQkNCQ0IiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTEyMCA0MS4zNCA2NSkiLz48cmVjdCB3aWR0aD0iNyIgaGVpZ2h0PSIyMCIgeD0iNDYuNSIgeT0iNDAiIGZpbGw9IiNEMkQyRDIiIHJ4PSI1IiByeT0iNSIgdHJhbnNmb3JtPSJyb3RhdGUoLTkwIDM1IDY1KSIvPjxyZWN0IHdpZHRoPSI3IiBoZWlnaHQ9IjIwIiB4PSI0Ni41IiB5PSI0MCIgZmlsbD0iI0RBREFEQSIgcng9IjUiIHJ5PSI1IiB0cmFuc2Zvcm09InJvdGF0ZSgtNjAgMjQuMDIgNjUpIi8+PHJlY3Qgd2lkdGg9IjciIGhlaWdodD0iMjAiIHg9IjQ2LjUiIHk9IjQwIiBmaWxsPSIjRTJFMkUyIiByeD0iNSIgcnk9IjUiIHRyYW5zZm9ybT0icm90YXRlKC0zMCAtNS45OCA2NSkiLz48L3N2Zz4=) no-repeat}.uni-loading{width:20px;height:20px;display:inline-block;vertical-align:middle;animation:uni-loading 1s steps(12,end) infinite;background-size:100%}@keyframes uni-loading{0%{transform:rotate3d(0,0,1,0)}to{transform:rotate3d(0,0,1,360deg)}}@media (prefers-color-scheme: dark){html{--UI-BG-COLOR-ACTIVE: #373737;--UI-BORDER-COLOR-1: #373737;--UI-BG: #000;--UI-BG-0: #191919;--UI-BG-1: #1f1f1f;--UI-BG-2: #232323;--UI-BG-3: #2f2f2f;--UI-BG-4: #606060;--UI-BG-5: #2c2c2c;--UI-FG: #fff;--UI-FG-0: hsla(0, 0%, 100%, .8);--UI-FG-HALF: hsla(0, 0%, 100%, .6);--UI-FG-1: hsla(0, 0%, 100%, .5);--UI-FG-2: hsla(0, 0%, 100%, .3);--UI-FG-3: hsla(0, 0%, 100%, .05)}body{background-color:var(--UI-BG-0);color:var(--UI-FG-0)}}[nvue] uni-view,[nvue] uni-label,[nvue] uni-swiper-item,[nvue] uni-scroll-view{display:flex;flex-shrink:0;flex-grow:0;flex-basis:auto;align-items:stretch;align-content:flex-start}[nvue] uni-button{margin:0}[nvue-dir-row] uni-view,[nvue-dir-row] uni-label,[nvue-dir-row] uni-swiper-item{flex-direction:row}[nvue-dir-column] uni-view,[nvue-dir-column] uni-label,[nvue-dir-column] uni-swiper-item{flex-direction:column}[nvue-dir-row-reverse] uni-view,[nvue-dir-row-reverse] uni-label,[nvue-dir-row-reverse] uni-swiper-item{flex-direction:row-reverse}[nvue-dir-column-reverse] uni-view,[nvue-dir-column-reverse] uni-label,[nvue-dir-column-reverse] uni-swiper-item{flex-direction:column-reverse}[nvue] uni-view,[nvue] uni-image,[nvue] uni-input,[nvue] uni-scroll-view,[nvue] uni-swiper,[nvue] uni-swiper-item,[nvue] uni-text,[nvue] uni-textarea,[nvue] uni-video{position:relative;border:0px solid #000000;box-sizing:border-box}[nvue] uni-swiper-item{position:absolute}@keyframes once-show{0%{top:0}}uni-resize-sensor,uni-resize-sensor>div{position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden}uni-resize-sensor{display:block;z-index:-1;visibility:hidden;animation:once-show 1ms}uni-resize-sensor>div>div{position:absolute;left:0;top:0}uni-resize-sensor>div:first-child>div{width:100000px;height:100000px}uni-resize-sensor>div:last-child>div{width:200%;height:200%}uni-text[selectable]{cursor:auto;-webkit-user-select:text;user-select:text}uni-text{white-space:pre-line}uni-view{display:block}uni-view[hidden]{display:none}uni-ad .uni-ad-container{width:100%;height:100%;min-height:1px}uni-button{position:relative;display:block;margin-left:auto;margin-right:auto;padding-left:14px;padding-right:14px;box-sizing:border-box;font-size:18px;text-align:center;text-decoration:none;line-height:2.55555556;border-radius:5px;-webkit-tap-highlight-color:transparent;overflow:hidden;color:#000;background-color:#f8f8f8;cursor:pointer}uni-button[hidden]{display:none!important}uni-button:after{content:" ";width:200%;height:200%;position:absolute;top:0;left:0;border:1px solid rgba(0,0,0,.2);transform:scale(.5);transform-origin:0 0;box-sizing:border-box;border-radius:10px}uni-button[native]{padding-left:0;padding-right:0}uni-button[native] .uni-button-cover-view-wrapper{border:inherit;border-color:inherit;border-radius:inherit;background-color:inherit}uni-button[native] .uni-button-cover-view-inner{padding-left:14px;padding-right:14px}uni-button uni-cover-view{line-height:inherit;white-space:inherit}uni-button[type=default]{color:#000;background-color:#f8f8f8}uni-button[type=primary]{color:#fff;background-color:#007aff}uni-button[type=warn]{color:#fff;background-color:#e64340}uni-button[disabled]{color:rgba(255,255,255,.6);cursor:not-allowed}uni-button[disabled][type=default],uni-button[disabled]:not([type]){color:rgba(0,0,0,.3);background-color:#f7f7f7}uni-button[disabled][type=primary]{background-color:rgba(0,122,255,.6)}uni-button[disabled][type=warn]{background-color:#ec8b89}uni-button[type=primary][plain]{color:#007aff;border:1px solid #007aff;background-color:transparent}uni-button[type=primary][plain][disabled]{color:rgba(0,0,0,.2);border-color:rgba(0,0,0,.2)}uni-button[type=primary][plain]:after{border-width:0}uni-button[type=default][plain]{color:#353535;border:1px solid #353535;background-color:transparent}uni-button[type=default][plain][disabled]{color:rgba(0,0,0,.2);border-color:rgba(0,0,0,.2)}uni-button[type=default][plain]:after{border-width:0}uni-button[plain]{color:#353535;border:1px solid #353535;background-color:transparent}uni-button[plain][disabled]{color:rgba(0,0,0,.2);border-color:rgba(0,0,0,.2)}uni-button[plain]:after{border-width:0}uni-button[plain][native] .uni-button-cover-view-inner{padding:0}uni-button[type=warn][plain]{color:#e64340;border:1px solid #e64340;background-color:transparent}uni-button[type=warn][plain][disabled]{color:rgba(0,0,0,.2);border-color:rgba(0,0,0,.2)}uni-button[type=warn][plain]:after{border-width:0}uni-button[size=mini]{display:inline-block;line-height:2.3;font-size:13px;padding:0 1.34em}uni-button[size=mini][native]{padding:0}uni-button[size=mini][native] .uni-button-cover-view-inner{padding:0 1.34em}uni-button[loading]:not([disabled]){cursor:progress}uni-button[loading]:before{content:" ";display:inline-block;width:18px;height:18px;vertical-align:middle;animation:uni-loading 1s steps(12,end) infinite;background-size:100%}uni-button[loading][type=primary]{color:rgba(255,255,255,.6);background-color:#0062cc}uni-button[loading][type=primary][plain]{color:#007aff;background-color:transparent}uni-button[loading][type=default]{color:rgba(0,0,0,.6);background-color:#dedede}uni-button[loading][type=default][plain]{color:#353535;background-color:transparent}uni-button[loading][type=warn]{color:rgba(255,255,255,.6);background-color:#ce3c39}uni-button[loading][type=warn][plain]{color:#e64340;background-color:transparent}uni-button[loading][native]:before{content:none}.button-hover{color:rgba(0,0,0,.6);background-color:#dedede}.button-hover[plain]{color:rgba(53,53,53,.6);border-color:rgba(53,53,53,.6);background-color:transparent}.button-hover[type=primary]{color:rgba(255,255,255,.6);background-color:#0062cc}.button-hover[type=primary][plain]{color:rgba(0,122,255,.6);border-color:rgba(0,122,255,.6);background-color:transparent}.button-hover[type=default]{color:rgba(0,0,0,.6);background-color:#dedede}.button-hover[type=default][plain]{color:rgba(53,53,53,.6);border-color:rgba(53,53,53,.6);background-color:transparent}.button-hover[type=warn]{color:rgba(255,255,255,.6);background-color:#ce3c39}.button-hover[type=warn][plain]{color:rgba(230,67,64,.6);border-color:rgba(230,67,64,.6);background-color:transparent}@media (prefers-color-scheme: dark){uni-button,uni-button[type=default]{color:#d6d6d6;background-color:#343434}.button-hover,.button-hover[type=default]{color:#d6d6d6;background-color:rgba(255,255,255,.1)}uni-button[disabled][type=default],uni-button[disabled]:not([type]){color:rgba(255,255,255,.2);background-color:rgba(255,255,255,.08)}uni-button[type=primary][plain][disabled]{color:rgba(255,255,255,.2);border-color:rgba(255,255,255,.2)}uni-button[type=default][plain]{color:#d6d6d6;border:1px solid #d6d6d6}.button-hover[type=default][plain]{color:rgba(150,150,150,.6);border-color:rgba(150,150,150,.6);background-color:rgba(50,50,50,.2)}uni-button[type=default][plain][disabled]{border-color:rgba(255,255,255,.2);color:rgba(255,255,255,.2)}}uni-canvas{width:300px;height:150px;display:block;position:relative}uni-canvas>.uni-canvas-canvas{position:absolute;top:0;left:0;width:100%;height:100%}uni-checkbox{-webkit-tap-highlight-color:transparent;display:inline-block;cursor:pointer}uni-checkbox[hidden]{display:none}uni-checkbox[disabled]{cursor:not-allowed}.uni-checkbox-wrapper{display:inline-flex;align-items:center;vertical-align:middle}.uni-checkbox-input{margin-right:5px;-webkit-appearance:none;appearance:none;outline:0;border:1px solid #d1d1d1;background-color:#fff;border-radius:3px;width:22px;height:22px;position:relative}.uni-checkbox-input svg{color:#007aff;font-size:22px;position:absolute;top:50%;left:50%;transform:translate(-50%,-48%) scale(.73)}@media (hover: hover){uni-checkbox:not([disabled]) .uni-checkbox-input:hover{border-color:var(--HOVER-BD-COLOR, #007aff)!important}}uni-checkbox-group{display:block}uni-checkbox-group[hidden]{display:none}uni-cover-image{display:block;line-height:1.2;overflow:hidden;height:100%;width:100%;pointer-events:auto}uni-cover-image[hidden]{display:none}uni-cover-image .uni-cover-image{width:100%;height:100%}uni-cover-view{display:block;line-height:1.2;overflow:hidden;white-space:nowrap;pointer-events:auto}uni-cover-view[hidden]{display:none}uni-cover-view .uni-cover-view{width:100%;height:100%;visibility:hidden;text-overflow:inherit;white-space:inherit;align-items:inherit;justify-content:inherit;flex-direction:inherit;flex-wrap:inherit;display:inherit;overflow:inherit}.ql-container{display:block;position:relative;box-sizing:border-box;-webkit-user-select:text;user-select:text;outline:none;overflow:hidden;width:100%;height:200px;min-height:200px}.ql-container[hidden]{display:none}.ql-container .ql-editor{position:relative;font-size:inherit;line-height:inherit;font-family:inherit;min-height:inherit;width:100%;height:100%;padding:0;overflow-x:hidden;overflow-y:auto;-webkit-tap-highlight-color:transparent;-webkit-touch-callout:none;-webkit-overflow-scrolling:touch}.ql-container .ql-editor::-webkit-scrollbar{width:0!important}.ql-container .ql-editor.scroll-disabled{overflow:hidden}.ql-container .ql-image-overlay{display:flex;position:absolute;box-sizing:border-box;border:1px dashed #ccc;justify-content:center;align-items:center;-webkit-user-select:none;user-select:none}.ql-container .ql-image-overlay .ql-image-size{position:absolute;padding:4px 8px;text-align:center;background-color:#fff;color:#888;border:1px solid #ccc;box-sizing:border-box;opacity:.8;right:4px;top:4px;font-size:12px;display:inline-block;width:auto}.ql-container .ql-image-overlay .ql-image-toolbar{position:relative;text-align:center;box-sizing:border-box;background:#000;border-radius:5px;color:#fff;font-size:0;min-height:24px;z-index:100}.ql-container .ql-image-overlay .ql-image-toolbar span{display:inline-block;cursor:pointer;padding:5px;font-size:12px;border-right:1px solid #fff}.ql-container .ql-image-overlay .ql-image-toolbar span:last-child{border-right:0}.ql-container .ql-image-overlay .ql-image-toolbar span.triangle-up{padding:0;position:absolute;top:-12px;left:50%;transform:translate(-50%);width:0;height:0;border-width:6px;border-style:solid;border-color:transparent transparent black transparent}.ql-container .ql-image-overlay .ql-image-handle{position:absolute;height:12px;width:12px;border-radius:50%;border:1px solid #ccc;box-sizing:border-box;background:#fff}.ql-container img{display:inline-block;max-width:100%}.ql-clipboard p{margin:0;padding:0}.ql-editor{box-sizing:border-box;height:100%;outline:none;overflow-y:auto;tab-size:4;-moz-tab-size:4;text-align:left;white-space:pre-wrap;word-wrap:break-word}.ql-editor>*{cursor:text}.ql-editor p,.ql-editor ol,.ql-editor ul,.ql-editor pre,.ql-editor blockquote,.ql-editor h1,.ql-editor h2,.ql-editor h3,.ql-editor h4,.ql-editor h5,.ql-editor h6{margin:0;padding:0;counter-reset:list-1 list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9}.ql-editor ol>li,.ql-editor ul>li{list-style-type:none}.ql-editor ul>li:before{content:"•"}.ql-editor ul[data-checked=true],.ql-editor ul[data-checked=false]{pointer-events:none}.ql-editor ul[data-checked=true]>li *,.ql-editor ul[data-checked=false]>li *{pointer-events:all}.ql-editor ul[data-checked=true]>li:before,.ql-editor ul[data-checked=false]>li:before{color:#777;cursor:pointer;pointer-events:all}.ql-editor ul[data-checked=true]>li:before{content:"☑"}.ql-editor ul[data-checked=false]>li:before{content:"☐"}.ql-editor ol,.ql-editor ul{padding-left:1.5em}.ql-editor li:not(.ql-direction-rtl):before{margin-left:-1.5em}.ql-editor li.ql-direction-rtl:before{margin-right:-1.5em}.ql-editor li:before{display:inline-block;white-space:nowrap;width:2em}.ql-editor ol li{counter-reset:list-1 list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9;counter-increment:list-0}.ql-editor ol li:before{content:counter(list-0,decimal) ". "}.ql-editor ol li.ql-indent-1{counter-increment:list-1}.ql-editor ol li.ql-indent-1:before{content:counter(list-1,lower-alpha) ". "}.ql-editor ol li.ql-indent-1{counter-reset:list-2 list-3 list-4 list-5 list-6 list-7 list-8 list-9}.ql-editor ol li.ql-indent-2{counter-increment:list-2}.ql-editor ol li.ql-indent-2:before{content:counter(list-2,lower-roman) ". "}.ql-editor ol li.ql-indent-2{counter-reset:list-3 list-4 list-5 list-6 list-7 list-8 list-9}.ql-editor ol li.ql-indent-3{counter-increment:list-3}.ql-editor ol li.ql-indent-3:before{content:counter(list-3,decimal) ". "}.ql-editor ol li.ql-indent-3{counter-reset:list-4 list-5 list-6 list-7 list-8 list-9}.ql-editor ol li.ql-indent-4{counter-increment:list-4}.ql-editor ol li.ql-indent-4:before{content:counter(list-4,lower-alpha) ". "}.ql-editor ol li.ql-indent-4{counter-reset:list-5 list-6 list-7 list-8 list-9}.ql-editor ol li.ql-indent-5{counter-increment:list-5}.ql-editor ol li.ql-indent-5:before{content:counter(list-5,lower-roman) ". "}.ql-editor ol li.ql-indent-5{counter-reset:list-6 list-7 list-8 list-9}.ql-editor ol li.ql-indent-6{counter-increment:list-6}.ql-editor ol li.ql-indent-6:before{content:counter(list-6,decimal) ". "}.ql-editor ol li.ql-indent-6{counter-reset:list-7 list-8 list-9}.ql-editor ol li.ql-indent-7{counter-increment:list-7}.ql-editor ol li.ql-indent-7:before{content:counter(list-7,lower-alpha) ". "}.ql-editor ol li.ql-indent-7{counter-reset:list-8 list-9}.ql-editor ol li.ql-indent-8{counter-increment:list-8}.ql-editor ol li.ql-indent-8:before{content:counter(list-8,lower-roman) ". "}.ql-editor ol li.ql-indent-8{counter-reset:list-9}.ql-editor ol li.ql-indent-9{counter-increment:list-9}.ql-editor ol li.ql-indent-9:before{content:counter(list-9,decimal) ". "}.ql-editor .ql-indent-1:not(.ql-direction-rtl){padding-left:2em}.ql-editor li.ql-indent-1:not(.ql-direction-rtl){padding-left:2em}.ql-editor .ql-indent-1.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-1.ql-direction-rtl.ql-align-right{padding-right:2em}.ql-editor .ql-indent-2:not(.ql-direction-rtl){padding-left:4em}.ql-editor li.ql-indent-2:not(.ql-direction-rtl){padding-left:4em}.ql-editor .ql-indent-2.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-2.ql-direction-rtl.ql-align-right{padding-right:4em}.ql-editor .ql-indent-3:not(.ql-direction-rtl){padding-left:6em}.ql-editor li.ql-indent-3:not(.ql-direction-rtl){padding-left:6em}.ql-editor .ql-indent-3.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-3.ql-direction-rtl.ql-align-right{padding-right:6em}.ql-editor .ql-indent-4:not(.ql-direction-rtl){padding-left:8em}.ql-editor li.ql-indent-4:not(.ql-direction-rtl){padding-left:8em}.ql-editor .ql-indent-4.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-4.ql-direction-rtl.ql-align-right{padding-right:8em}.ql-editor .ql-indent-5:not(.ql-direction-rtl){padding-left:10em}.ql-editor li.ql-indent-5:not(.ql-direction-rtl){padding-left:10em}.ql-editor .ql-indent-5.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-5.ql-direction-rtl.ql-align-right{padding-right:10em}.ql-editor .ql-indent-6:not(.ql-direction-rtl){padding-left:12em}.ql-editor li.ql-indent-6:not(.ql-direction-rtl){padding-left:12em}.ql-editor .ql-indent-6.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-6.ql-direction-rtl.ql-align-right{padding-right:12em}.ql-editor .ql-indent-7:not(.ql-direction-rtl){padding-left:14em}.ql-editor li.ql-indent-7:not(.ql-direction-rtl){padding-left:14em}.ql-editor .ql-indent-7.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-7.ql-direction-rtl.ql-align-right{padding-right:14em}.ql-editor .ql-indent-8:not(.ql-direction-rtl){padding-left:16em}.ql-editor li.ql-indent-8:not(.ql-direction-rtl){padding-left:16em}.ql-editor .ql-indent-8.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-8.ql-direction-rtl.ql-align-right{padding-right:16em}.ql-editor .ql-indent-9:not(.ql-direction-rtl){padding-left:18em}.ql-editor li.ql-indent-9:not(.ql-direction-rtl){padding-left:18em}.ql-editor .ql-indent-9.ql-direction-rtl.ql-align-right,.ql-editor li.ql-indent-9.ql-direction-rtl.ql-align-right{padding-right:18em}.ql-editor .ql-direction-rtl{direction:rtl;text-align:inherit}.ql-editor .ql-align-center{text-align:center}.ql-editor .ql-align-justify{text-align:justify}.ql-editor .ql-align-right{text-align:right}.ql-editor.ql-blank:before{color:rgba(0,0,0,.6);content:attr(data-placeholder);font-style:italic;pointer-events:none;position:absolute}.ql-container.ql-disabled .ql-editor ul[data-checked]>li:before{pointer-events:none}.ql-clipboard{left:-100000px;height:1px;overflow-y:hidden;position:absolute;top:50%}uni-icon{display:inline-block;font-size:0;box-sizing:border-box}uni-icon[hidden]{display:none}uni-image{width:320px;height:240px;display:inline-block;overflow:hidden;position:relative}uni-image[hidden]{display:none}uni-image>div{width:100%;height:100%;background-repeat:no-repeat}uni-image>img{-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;display:block;position:absolute;top:0;left:0;width:100%;height:100%;opacity:0}uni-image>.uni-image-will-change{will-change:transform}uni-input{display:block;font-size:16px;line-height:1.4em;height:1.4em;min-height:1.4em;overflow:hidden}uni-input[hidden]{display:none}.uni-input-wrapper,.uni-input-placeholder,.uni-input-form,.uni-input-input{outline:none;border:none;padding:0;margin:0;text-decoration:inherit}.uni-input-wrapper,.uni-input-form{display:flex;position:relative;width:100%;height:100%;flex-direction:column;justify-content:center}.uni-input-placeholder,.uni-input-input{width:100%}.uni-input-placeholder{position:absolute;top:auto!important;left:0;color:gray;overflow:hidden;text-overflow:clip;white-space:pre;word-break:keep-all;pointer-events:none;line-height:inherit}.uni-input-input{position:relative;display:block;height:100%;background:none;color:inherit;opacity:1;font:inherit;line-height:inherit;letter-spacing:inherit;text-align:inherit;text-indent:inherit;text-transform:inherit;text-shadow:inherit}.uni-input-input[type=search]::-webkit-search-cancel-button,.uni-input-input[type=search]::-webkit-search-decoration{display:none}.uni-input-input::-webkit-outer-spin-button,.uni-input-input::-webkit-inner-spin-button{-webkit-appearance:none;appearance:none;margin:0}.uni-input-input[type=number]{-moz-appearance:textfield}.uni-input-input:disabled{-webkit-text-fill-color:currentcolor}.uni-label-pointer{cursor:pointer}uni-live-pusher{width:320px;height:240px;display:inline-block;line-height:0;overflow:hidden;position:relative}uni-live-pusher[hidden]{display:none}.uni-live-pusher-container{width:100%;height:100%;position:absolute;top:0;left:0;overflow:hidden;background-color:#000}.uni-live-pusher-slot{position:absolute;top:0;width:100%;height:100%;overflow:hidden;pointer-events:none}uni-map{width:300px;height:225px;display:inline-block;line-height:0;overflow:hidden;position:relative}uni-map[hidden]{display:none}.uni-map-container{width:100%;height:100%;position:absolute;top:0;left:0;overflow:hidden;background-color:transparent}.uni-map-slot{position:absolute;top:0;width:100%;height:100%;overflow:hidden;pointer-events:none}uni-map.web{position:relative;width:300px;height:150px;display:block}uni-map.web[hidden]{display:none}uni-map.web .amap-marker-label{padding:0;border:none;background-color:transparent}uni-map.web .amap-marker>.amap-icon>img{left:0!important;top:0!important}uni-map.web .uni-map-control{position:absolute;width:0;height:0;top:0;left:0;z-index:999}uni-map.web .uni-map-control-icon{position:absolute;max-width:initial}.uni-system-choose-location{display:block;position:fixed;left:0;top:0;width:100%;height:100%;background:#f8f8f8;z-index:999}.uni-system-choose-location .map{position:absolute;top:0;left:0;width:100%;height:300px}.uni-system-choose-location .map-location{position:absolute;left:50%;bottom:50%;width:32px;height:52px;margin-left:-16px;cursor:pointer;background-size:100%}.uni-system-choose-location .map-move{position:absolute;bottom:50px;right:10px;width:40px;height:40px;box-sizing:border-box;line-height:40px;background-color:#fff;border-radius:50%;pointer-events:auto;cursor:pointer;box-shadow:0 0 5px 1px rgba(0,0,0,.3)}.uni-system-choose-location .map-move>svg{display:block;width:100%;height:100%;box-sizing:border-box;padding:8px}.uni-system-choose-location .nav{position:absolute;top:0;left:0;width:100%;height:calc(44px + var(--status-bar-height));background-color:transparent;background-image:linear-gradient(to bottom,rgba(0,0,0,.3),rgba(0,0,0,0))}.uni-system-choose-location .nav-btn{position:absolute;box-sizing:border-box;top:var(--status-bar-height);left:0;width:60px;height:44px;padding:6px;line-height:32px;font-size:26px;color:#fff;text-align:center;cursor:pointer}.uni-system-choose-location .nav-btn.confirm{left:auto;right:0}.uni-system-choose-location .nav-btn.disable{opacity:.4}.uni-system-choose-location .nav-btn>svg{display:block;width:100%;height:100%;border-radius:2px;box-sizing:border-box;padding:3px}.uni-system-choose-location .nav-btn.confirm>svg{background-color:#007aff;padding:5px}.uni-system-choose-location .menu{position:absolute;top:300px;left:0;width:100%;bottom:0;background-color:#fff}.uni-system-choose-location .search{display:flex;flex-direction:row;height:50px;padding:8px;line-height:34px;box-sizing:border-box;background-color:#fff}.uni-system-choose-location .search-input{flex:1;height:100%;border-radius:5px;padding:0 5px;background:#ebebeb}.uni-system-choose-location .search-btn{margin-left:5px;color:#007aff;font-size:17px;text-align:center}.uni-system-choose-location .list{position:absolute;top:50px;left:0;width:100%;bottom:0;padding-bottom:10px}.uni-system-choose-location .list-loading{display:flex;height:50px;justify-content:center;align-items:center}.uni-system-choose-location .list-item{position:relative;padding:10px 40px 10px 10px;cursor:pointer}.uni-system-choose-location .list-item>svg{display:none;position:absolute;top:50%;right:10px;width:30px;height:30px;margin-top:-15px;box-sizing:border-box;padding:5px}.uni-system-choose-location .list-item.selected>svg{display:block}.uni-system-choose-location .list-item:not(:last-child):after{position:absolute;content:"";height:1px;left:10px;bottom:0;width:100%;background-color:#d3d3d3}.uni-system-choose-location .list-item-title{font-size:14px;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}.uni-system-choose-location .list-item-detail{font-size:12px;color:gray;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}@media screen and (min-width: 800px){.uni-system-choose-location .map{top:0;height:100%}.uni-system-choose-location .map-move{bottom:10px;right:320px}.uni-system-choose-location .menu{top:calc(54px + var(--status-bar-height));left:auto;right:10px;width:300px;bottom:10px;max-height:600px;box-shadow:0 0 20px 5px rgba(0,0,0,.3)}}.uni-system-open-location{display:block;position:fixed;left:0;top:0;width:100%;height:100%;background:#f8f8f8;z-index:999}.uni-system-open-location .map{position:absolute;top:0;left:0;width:100%;bottom:80px;height:auto}.uni-system-open-location .info{position:absolute;bottom:0;left:0;width:100%;height:80px;background-color:#fff;padding:15px;box-sizing:border-box;line-height:1.5}.uni-system-open-location .info>.name{font-size:17px;color:#111;padding-right:50px}.uni-system-open-location .info>.address{font-size:14px;color:#666}.uni-system-open-location .info>.nav{position:absolute;top:50%;right:15px;width:50px;height:50px;border-radius:50%;margin-top:-25px;background-color:#007aff}.uni-system-open-location .info>.nav>svg{display:block;width:100%;height:100%;padding:10px;box-sizing:border-box}.uni-system-open-location .map-move{position:absolute;bottom:50px;right:10px;width:40px;height:40px;box-sizing:border-box;line-height:40px;background-color:#fff;border-radius:50%;pointer-events:auto;cursor:pointer;box-shadow:0 0 5px 1px rgba(0,0,0,.3)}.uni-system-open-location .map-move>svg{display:block;width:100%;height:100%;box-sizing:border-box;padding:8px}.uni-system-open-location .nav-btn-back{position:absolute;box-sizing:border-box;top:var(--status-bar-height);left:0;width:44px;height:44px;padding:6px;cursor:pointer}.uni-system-open-location .nav-btn-back>svg{display:block;width:100%;height:100%;border-radius:50%;background-color:rgba(0,0,0,.5);padding:3px;box-sizing:border-box}.uni-system-open-location .map-content{position:absolute;left:0;top:0;width:100%;bottom:0;overflow:hidden}.uni-system-open-location .map-content.fix-position{top:-74px;bottom:-44px}.uni-system-open-location .map-content>iframe{width:100%;height:100%;border:none}.uni-system-open-location .actTonav{position:absolute;right:16px;bottom:56px;width:60px;height:60px;border-radius:60px}.uni-system-open-location .nav-view{position:absolute;left:0;top:0;width:100%;height:100%;display:flex;flex-direction:column}.uni-system-open-location .nav-view-top-placeholder{width:100%;height:var(--status-bar-height);background-color:#fff}.uni-system-open-location .nav-view-frame{width:100%;flex:1}uni-movable-area{display:block;position:relative;width:10px;height:10px}uni-movable-area[hidden]{display:none}uni-movable-view{display:inline-block;width:10px;height:10px;top:0;left:0;position:absolute;cursor:grab}uni-movable-view[hidden]{display:none}uni-navigator{height:auto;width:auto;display:block;cursor:pointer}uni-navigator[hidden]{display:none}.navigator-hover{background-color:rgba(0,0,0,.1);opacity:.7}.navigator-wrap,.navigator-wrap:link,.navigator-wrap:visited,.navigator-wrap:hover,.navigator-wrap:active{text-decoration:none;color:inherit;cursor:pointer}uni-picker-view{display:block}.uni-picker-view-wrapper{display:flex;position:relative;overflow:hidden;height:100%}uni-picker-view[hidden]{display:none}uni-picker-view-column{flex:1;position:relative;height:100%;overflow:hidden}uni-picker-view-column[hidden]{display:none}.uni-picker-view-group{height:100%;overflow:hidden}.uni-picker-view-mask{transform:translateZ(0)}.uni-picker-view-indicator,.uni-picker-view-mask{position:absolute;left:0;width:100%;z-index:3;pointer-events:none}.uni-picker-view-mask{top:0;height:100%;margin:0 auto;background-image:linear-gradient(180deg,rgba(255,255,255,.95),rgba(255,255,255,.6)),linear-gradient(0deg,rgba(255,255,255,.95),rgba(255,255,255,.6));background-position:top,bottom;background-size:100% 102px;background-repeat:no-repeat;transform:translateZ(0)}.uni-picker-view-indicator{height:34px;top:50%;transform:translateY(-50%)}.uni-picker-view-content{position:absolute;top:0;left:0;width:100%;will-change:transform;padding:102px 0;cursor:pointer}.uni-picker-view-content>*{height:var(--picker-view-column-indicator-height);overflow:hidden}.uni-picker-view-indicator:before{top:0;border-top:1px solid #e5e5e5;transform-origin:0 0;transform:scaleY(.5)}.uni-picker-view-indicator:after{bottom:0;border-bottom:1px solid #e5e5e5;transform-origin:0 100%;transform:scaleY(.5)}.uni-picker-view-indicator:after,.uni-picker-view-indicator:before{content:" ";position:absolute;left:0;right:0;height:1px;color:#e5e5e5}@media (prefers-color-scheme: dark){.uni-picker-view-indicator:before{border-top-color:var(--UI-FG-3)}.uni-picker-view-indicator:after{border-bottom-color:var(--UI-FG-3)}.uni-picker-view-mask{background-image:linear-gradient(180deg,rgba(35,35,35,.95),rgba(35,35,35,.6)),linear-gradient(0deg,rgba(35,35,35,.95),rgba(35,35,35,.6))}}uni-progress{display:flex;align-items:center}uni-progress[hidden]{display:none}.uni-progress-bar{flex:1}.uni-progress-inner-bar{width:0;height:100%}.uni-progress-info{margin-top:0;margin-bottom:0;min-width:2em;margin-left:15px;font-size:16px}uni-radio{-webkit-tap-highlight-color:transparent;display:inline-block;cursor:pointer}uni-radio[hidden]{display:none}uni-radio[disabled]{cursor:not-allowed}.uni-radio-wrapper{display:inline-flex;align-items:center;vertical-align:middle}.uni-radio-input{-webkit-appearance:none;appearance:none;margin-right:5px;outline:0;border:1px solid #d1d1d1;background-color:#fff;border-radius:50%;width:22px;height:22px;position:relative}@media (hover: hover){uni-radio:not([disabled]) .uni-radio-input:hover{border-color:var(--HOVER-BD-COLOR, #007aff)!important}}.uni-radio-input svg{color:#fff;font-size:18px;position:absolute;top:50%;left:50%;transform:translate(-50%,-48%) scale(.73)}.uni-radio-input.uni-radio-input-disabled{background-color:#e1e1e1;border-color:#d1d1d1}.uni-radio-input.uni-radio-input-disabled svg{color:#adadad}uni-radio-group{display:block}uni-radio-group[hidden]{display:none}uni-scroll-view{display:block;width:100%}uni-scroll-view[hidden]{display:none}.uni-scroll-view{position:relative;-webkit-overflow-scrolling:touch;width:100%;height:100%;max-height:inherit}.uni-scroll-view-scrollbar-hidden::-webkit-scrollbar{display:none}.uni-scroll-view-scrollbar-hidden{-moz-scrollbars:none;scrollbar-width:none}.uni-scroll-view-content{width:100%;height:100%}.uni-scroll-view-refresher{position:relative;overflow:hidden;flex-shrink:0}.uni-scroll-view-refresher-container{position:absolute;width:100%;bottom:0;display:flex;flex-direction:column-reverse}.uni-scroll-view-refresh{position:absolute;top:0;left:0;right:0;bottom:0;display:flex;flex-direction:row;justify-content:center;align-items:center}.uni-scroll-view-refresh-inner{display:flex;align-items:center;justify-content:center;line-height:0;width:40px;height:40px;border-radius:50%;background-color:#fff;box-shadow:0 1px 6px rgba(0,0,0,.118),0 1px 4px rgba(0,0,0,.118)}.uni-scroll-view-refresh__spinner{transform-origin:center center;animation:uni-scroll-view-refresh-rotate 2s linear infinite}.uni-scroll-view-refresh__spinner>circle{stroke:currentColor;stroke-linecap:round;animation:uni-scroll-view-refresh-dash 2s linear infinite}@keyframes uni-scroll-view-refresh-rotate{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes uni-scroll-view-refresh-dash{0%{stroke-dasharray:1,200;stroke-dashoffset:0}50%{stroke-dasharray:89,200;stroke-dashoffset:-35px}to{stroke-dasharray:89,200;stroke-dashoffset:-124px}}uni-slider{margin:10px 18px;padding:0;display:block}uni-slider[hidden]{display:none}uni-slider .uni-slider-wrapper{display:flex;align-items:center;min-height:16px}uni-slider .uni-slider-tap-area{flex:1;padding:8px 0}uni-slider .uni-slider-handle-wrapper{position:relative;height:2px;border-radius:5px;background-color:#e9e9e9;cursor:pointer;transition:background-color .3s ease;-webkit-tap-highlight-color:transparent}uni-slider .uni-slider-track{height:100%;border-radius:6px;background-color:#007aff;transition:background-color .3s ease}uni-slider .uni-slider-handle,uni-slider .uni-slider-thumb{position:absolute;left:50%;top:50%;cursor:pointer;border-radius:50%;transition:border-color .3s ease}uni-slider .uni-slider-handle{width:28px;height:28px;margin-top:-14px;margin-left:-14px;background-color:transparent;z-index:3;cursor:grab}uni-slider .uni-slider-thumb{z-index:2;box-shadow:0 0 4px rgba(0,0,0,.2)}uni-slider .uni-slider-step{position:absolute;width:100%;height:2px;background:transparent;z-index:1}uni-slider .uni-slider-value{width:3ch;color:#888;font-size:14px;margin-left:1em}uni-slider .uni-slider-disabled .uni-slider-track{background-color:#ccc}uni-slider .uni-slider-disabled .uni-slider-thumb{background-color:#fff;border-color:#ccc}uni-swiper{display:block;height:150px}uni-swiper[hidden]{display:none}.uni-swiper-wrapper{overflow:hidden;position:relative;width:100%;height:100%;transform:translateZ(0)}.uni-swiper-slides{position:absolute;left:0;top:0;right:0;bottom:0}.uni-swiper-slide-frame{position:absolute;left:0;top:0;width:100%;height:100%;will-change:transform}.uni-swiper-dots{position:absolute;font-size:0}.uni-swiper-dots-horizontal{left:50%;bottom:10px;text-align:center;white-space:nowrap;transform:translate(-50%)}.uni-swiper-dots-horizontal .uni-swiper-dot{margin-right:8px}.uni-swiper-dots-horizontal .uni-swiper-dot:last-child{margin-right:0}.uni-swiper-dots-vertical{right:10px;top:50%;text-align:right;transform:translateY(-50%)}.uni-swiper-dots-vertical .uni-swiper-dot{display:block;margin-bottom:9px}.uni-swiper-dots-vertical .uni-swiper-dot:last-child{margin-bottom:0}.uni-swiper-dot{display:inline-block;width:8px;height:8px;cursor:pointer;transition-property:background-color;transition-timing-function:ease;background:rgba(0,0,0,.3);border-radius:50%}.uni-swiper-dot-active{background-color:#000}.uni-swiper-navigation{width:26px;height:26px;cursor:pointer;position:absolute;top:50%;margin-top:-13px;display:flex;align-items:center;transition:all .2s;border-radius:50%;opacity:1}.uni-swiper-navigation-disabled{opacity:.35;cursor:not-allowed}.uni-swiper-navigation-hide{opacity:0;cursor:auto;pointer-events:none}.uni-swiper-navigation-prev{left:10px}.uni-swiper-navigation-prev svg{margin-left:-1px;left:10px}.uni-swiper-navigation-prev.uni-swiper-navigation-vertical{top:18px;left:50%;margin-left:-13px}.uni-swiper-navigation-prev.uni-swiper-navigation-vertical svg{transform:rotate(90deg);margin-left:auto;margin-top:-2px}.uni-swiper-navigation-next{right:10px}.uni-swiper-navigation-next svg{transform:rotate(180deg)}.uni-swiper-navigation-next.uni-swiper-navigation-vertical{top:auto;bottom:5px;left:50%;margin-left:-13px}.uni-swiper-navigation-next.uni-swiper-navigation-vertical svg{margin-top:2px;transform:rotate(270deg)}uni-swiper-item{display:block;overflow:hidden;will-change:transform;position:absolute;width:100%;height:100%;cursor:grab}uni-swiper-item[hidden]{display:none}uni-switch{-webkit-tap-highlight-color:transparent;display:inline-block;cursor:pointer}uni-switch[hidden]{display:none}uni-switch[disabled]{cursor:not-allowed}uni-switch[disabled] .uni-switch-input{opacity:.7}.uni-switch-wrapper{display:inline-flex;align-items:center;vertical-align:middle}.uni-switch-input{-webkit-appearance:none;appearance:none;position:relative;width:52px;height:32px;margin-right:5px;border:1px solid #dfdfdf;outline:0;border-radius:16px;box-sizing:border-box;background-color:#dfdfdf;transition:background-color .1s,border .1s}.uni-switch-input:before{content:" ";position:absolute;top:0;left:0;width:50px;height:30px;border-radius:15px;background-color:#fdfdfd;transition:transform .3s}.uni-switch-input:after{content:" ";position:absolute;top:0;left:0;width:30px;height:30px;border-radius:15px;background-color:#fff;box-shadow:0 1px 3px rgba(0,0,0,.4);transition:transform .3s}.uni-switch-input.uni-switch-input-checked{border-color:#007aff;background-color:#007aff}.uni-switch-input.uni-switch-input-checked:before{transform:scale(0)}.uni-switch-input.uni-switch-input-checked:after{transform:translate(20px)}uni-switch .uni-checkbox-input{margin-right:5px;-webkit-appearance:none;appearance:none;outline:0;border:1px solid #d1d1d1;background-color:#fff;border-radius:3px;width:22px;height:22px;position:relative;color:#007aff}uni-switch:not([disabled]) .uni-checkbox-input:hover{border-color:#007aff}uni-switch .uni-checkbox-input svg{fill:#007aff;font-size:22px;position:absolute;top:50%;left:50%;transform:translate(-50%,-48%) scale(.73)}.uni-checkbox-input.uni-checkbox-input-disabled{background-color:#e1e1e1}.uni-checkbox-input.uni-checkbox-input-disabled:before{color:#adadad}@media (prefers-color-scheme: dark){uni-switch .uni-switch-input{border-color:#3b3b3f}uni-switch .uni-switch-input,uni-switch .uni-switch-input:before{background-color:#3b3b3f}uni-switch .uni-switch-input:after{background-color:#fff;box-shadow:0 1px 3px rgba(0,0,0,.4)}uni-switch .uni-checkbox-input{background-color:#2c2c2c;border:1px solid #656565}}uni-textarea{width:300px;height:150px;display:block;position:relative;font-size:16px;line-height:normal;white-space:pre-wrap;word-break:break-all}uni-textarea[hidden]{display:none}uni-textarea[auto-height=true]{height:-webkit-fit-content!important;height:fit-content!important}.uni-textarea-wrapper,.uni-textarea-placeholder,.uni-textarea-line,.uni-textarea-compute,.uni-textarea-textarea{outline:none;border:none;padding:0;margin:0;text-decoration:inherit}.uni-textarea-wrapper{display:block;position:relative;width:100%;height:100%;min-height:inherit;overflow-y:hidden}.uni-textarea-placeholder,.uni-textarea-line,.uni-textarea-compute,.uni-textarea-textarea{position:absolute;width:100%;height:100%;left:0;top:0;white-space:inherit;word-break:inherit}.uni-textarea-placeholder{color:gray;overflow:hidden}.uni-textarea-line,.uni-textarea-compute{visibility:hidden;height:auto}.uni-textarea-line{width:1em}.uni-textarea-compute-auto-height{overflow-wrap:break-word}.uni-textarea-textarea{resize:none;background:none;color:inherit;opacity:1;font:inherit;line-height:inherit;letter-spacing:inherit;text-align:inherit;text-indent:inherit;text-transform:inherit;text-shadow:inherit}.uni-textarea-textarea-fix-margin{width:auto;right:0;margin:0 -3px}.uni-textarea-textarea:disabled{-webkit-text-fill-color:currentcolor}uni-video{width:300px;height:225px;display:inline-block;line-height:0;overflow:hidden;position:relative}uni-video[hidden]{display:none}.uni-video-container{width:100%;height:100%;position:absolute;top:0;left:0;overflow:hidden;background-color:#000}.uni-video-slot{position:absolute;top:0;width:100%;height:100%;overflow:hidden;pointer-events:none}uni-web-view{display:inline-block;position:absolute;left:0;right:0;top:0;bottom:0} -@font-face{font-family:iconfont;src:url(static/iconfont/iconfont.ttf?t=1776936195904) format("truetype")}.iconfont{font-family:iconfont!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.icon-del:before{content:"\e616"}.icon-zhaoxiangji:before{content:"\e663"}.icon-duoxuan:before{content:"\e630"}.icon-jia:before{content:"\e659"}.icon-quxiao:before{content:"\e625"}.icon-tuichu:before{content:"\e617"}.icon-fuzhi:before{content:"\e6e6"}.icon-shangchuan:before{content:"\e797"}.icon-total_selection:before{content:"\e660"}.icon-tingzhi:before{content:"\e611"}.icon-wenjianjia:before{content:"\e64b"}.icon-caidan:before{content:"\eaf1"}.icon-wenjian:before{content:"\e729"}.icon-biezhen:before{content:"\e647"}.icon-bianji:before{content:"\e605"}.icon-fasong:before{content:"\e705"}.icon-download:before{content:"\e61a"}.icon-edit-fill:before{content:"\e61d"}.icon-favorite-fill:before{content:"\e61f"}.icon-favorite:before{content:"\e620"}.icon-upload:before{content:"\e63e"}.icon-yonghuziliao:before{content:"\e6a1"}.icon-pen-fill:before{content:"\e667"}.icon-qunliao:before{content:"\e606"}.icon-shipintonghua:before{content:"\e609"}.icon-tianjia:before{content:"\e60d"}.icon-tongxunlu:before{content:"\e612"}.icon-tianjiahaoyou:before{content:"\e613"}.icon-shanchu:before{content:"\e6d3"}.icon-choose-fill:before{content:"\e6a2"}.icon-a-wenjianjiawenjian:before{content:"\e69e"}.icon-sousuo:before{content:"\e6eb"}.icon-Robot:before{content:"\e661"}.icon-saochu:before{content:"\e6a3"}.icon-fanhui:before{content:"\e765"}.icon-brain-2-fill:before{content:"\e800"}.icon-gengduo:before{content:"\e6c5"}.status-bar{height:var(--status-bar-height);width:100%}.page-container{width:100%;height:calc(100vh - var(--status-bar-height))}.solid-line{width:100%;border-bottom:.03125rem solid #999}.icon-btn,.text-btn{padding:.3125rem;border-radius:.625rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center}.switch-box{width:42px;height:20px;background-color:#999;border-radius:10px;display:flex;align-items:center;padding:1px}.switch-box.active{justify-content:flex-end;background-color:#0af}.switch-track{width:20px;height:20px;background-color:#fff;border-radius:50%}.popup-overlay{position:fixed;width:100%;height:100%;left:0;top:0;display:flex;align-items:center;justify-content:center;background-color:rgba(193,193,193,.4);z-index:1000}.popup-card{width:90%;height:auto;background-color:#fff;border-radius:1.5625rem;padding:1.5625rem;box-sizing:border-box;display:flex;flex-direction:column;position:relative}.close-popup-card{position:absolute;top:.3125rem;right:.3125rem;color:red;padding:.3125rem;box-sizing:border-box}.popup-title{width:100%;display:flex;justify-content:center;align-items:center} +@font-face{font-family:iconfont;src:url(static/iconfont/iconfont.woff2?t=1782200893170) format("woff2"),url(static/iconfont/iconfont.woff?t=1782200893170) format("woff"),url(static/iconfont/iconfont.ttf?t=1782200893170) format("truetype")}.iconfont{font-family:iconfont!important;font-size:16px;font-style:normal;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.icon-cloud:before{content:"\e988"}.icon-qitawenjian:before{content:"\e7b6"}.icon-wenjianyasuo:before{content:"\e643"}.icon-wenjianshipin:before{content:"\e644"}.icon-wenjianyinpin:before{content:"\e645"}.icon-wenjiantupian:before{content:"\e646"}.icon-daimawenjian:before{content:"\e66a"}.icon-file-markdown-fill:before{content:"\ebb1"}.icon-SVG:before{content:"\e614"}.icon-HTML:before{content:"\e615"}.icon-CSS:before{content:"\e618"}.icon-CSV:before{content:"\e619"}.icon-JSON:before{content:"\e61b"}.icon-JS:before{content:"\e61c"}.icon-PDF:before{content:"\e61e"}.icon-PHP:before{content:"\e621"}.icon-TXT:before{content:"\e622"}.icon-XLS:before{content:"\e623"}.icon-DOC:before{content:"\e624"}.icon-PPT:before{content:"\e626"}.icon-SQL:before{content:"\e627"}.icon-bianji:before{content:"\e605"}.icon-fasong:before{content:"\e705"}.icon-download:before{content:"\e61a"}.icon-edit-fill:before{content:"\e61d"}.icon-favorite-fill:before{content:"\e61f"}.icon-favorite:before{content:"\e620"}.icon-upload:before{content:"\e63e"}.icon-yonghuziliao:before{content:"\e6a1"}.icon-pen-fill:before{content:"\e67c"}.icon-qunliao:before{content:"\e606"}.icon-shipintonghua:before{content:"\e609"}.icon-tianjia:before{content:"\e60d"}.icon-tongxunlu:before{content:"\e612"}.icon-tianjiahaoyou:before{content:"\e613"}.icon-shanchu:before{content:"\e6d3"}.icon-choose-fill:before{content:"\e6a2"}.icon-a-wenjianjiawenjian:before{content:"\e69e"}.icon-sousuo:before{content:"\e6eb"}.icon-Robot:before{content:"\e67d"}.icon-saochu:before{content:"\e6a3"}.icon-fanhui:before{content:"\e765"}.icon-brain-2-fill:before{content:"\e800"}.icon-gengduo:before{content:"\e6c5"}.icon-del:before{content:"\e616"}.icon-zhaoxiangji:before{content:"\e663"}.icon-duoxuan:before{content:"\e630"}.icon-jia:before{content:"\e659"}.icon-quxiao:before{content:"\e625"}.icon-tuichu:before{content:"\e617"}.icon-fuzhi:before{content:"\e6e6"}.icon-shangchuan:before{content:"\e797"}.icon-total_selection:before{content:"\e660"}.icon-tingzhi:before{content:"\e611"}.icon-wenjianjia:before{content:"\e64b"}.icon-caidan:before{content:"\eaf1"}.icon-wenjian:before{content:"\e729"}.icon-biezhen:before{content:"\e647"}.icon-qita:before{content:"\e600"}.status-bar{height:var(--status-bar-height);width:100%}.page-container{width:100%;height:calc(100vh - var(--status-bar-height))}.solid-line{width:100%;border-bottom:.03125rem solid #999}.icon-btn,.text-btn{padding:.3125rem;border-radius:.625rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center}.switch-box{width:42px;height:20px;background-color:#999;border-radius:10px;display:flex;align-items:center;padding:1px}.switch-box.active{justify-content:flex-end;background-color:#0af}.switch-track{width:20px;height:20px;background-color:#fff;border-radius:50%}.popup-overlay{position:fixed;width:100%;height:100%;left:0;top:0;display:flex;align-items:center;justify-content:center;background-color:rgba(193,193,193,.4);z-index:1000}.popup-card{width:90%;height:auto;background-color:#fff;border-radius:1.5625rem;padding:1.5625rem;box-sizing:border-box;display:flex;flex-direction:column;position:relative}.close-popup-card{position:absolute;top:.3125rem;right:.3125rem;color:red;padding:.3125rem;box-sizing:border-box}.popup-title{width:100%;display:flex;justify-content:center;align-items:center} diff --git a/unpackage/dist/build/app-plus/manifest.json b/unpackage/dist/build/app-plus/manifest.json index 25a2450..38263bf 100644 --- a/unpackage/dist/build/app-plus/manifest.json +++ b/unpackage/dist/build/app-plus/manifest.json @@ -7,7 +7,7 @@ "id": "__UNI__923FD9E", "name": "test1", "version": { - "name": "1.0.0", + "name": "1.1.1", "code": "1" }, "description": "", @@ -17,6 +17,7 @@ "url": "" }, "permissions": { + "Camera": {}, "UniNView": { "description": "UniNView原生渲染" } @@ -45,6 +46,46 @@ "nvueStyleCompiler": "uni-app", "compilerVersion": 3, "distribute": { + "icons": { + "android": { + "hdpi": "unpackage/res/icons/72x72.png", + "xhdpi": "unpackage/res/icons/96x96.png", + "xxhdpi": "unpackage/res/icons/144x144.png", + "xxxhdpi": "unpackage/res/icons/192x192.png" + }, + "ios": { + "appstore": "unpackage/res/icons/1024x1024.png", + "ipad": { + "app": "unpackage/res/icons/76x76.png", + "app@2x": "unpackage/res/icons/152x152.png", + "notification": "unpackage/res/icons/20x20.png", + "notification@2x": "unpackage/res/icons/40x40.png", + "proapp@2x": "unpackage/res/icons/167x167.png", + "settings": "unpackage/res/icons/29x29.png", + "settings@2x": "unpackage/res/icons/58x58.png", + "spotlight": "unpackage/res/icons/40x40.png", + "spotlight@2x": "unpackage/res/icons/80x80.png" + }, + "iphone": { + "app@2x": "unpackage/res/icons/120x120.png", + "app@3x": "unpackage/res/icons/180x180.png", + "notification@2x": "unpackage/res/icons/40x40.png", + "notification@3x": "unpackage/res/icons/60x60.png", + "settings@2x": "unpackage/res/icons/58x58.png", + "settings@3x": "unpackage/res/icons/87x87.png", + "spotlight@2x": "unpackage/res/icons/80x80.png", + "spotlight@3x": "unpackage/res/icons/120x120.png" + } + } + }, + "splashscreen": { + "androidStyle": "default", + "android": { + "hdpi": "C:/Users/ADMIN/Pictures/480-762.png", + "xhdpi": "C:/Users/ADMIN/Pictures/720-1242.png", + "xxhdpi": "C:/Users/ADMIN/Pictures/1080-1882.png" + } + }, "google": { "permissions": [ "", @@ -61,7 +102,10 @@ "", "", "", - "" + "", + "", + "", + "" ] }, "apple": { diff --git a/unpackage/dist/build/app-plus/pages/Chat/Chat.css b/unpackage/dist/build/app-plus/pages/Chat/Chat.css index 88a2a64..fb50b73 100644 --- a/unpackage/dist/build/app-plus/pages/Chat/Chat.css +++ b/unpackage/dist/build/app-plus/pages/Chat/Chat.css @@ -1 +1 @@ -.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.chat-sidebar-container[data-v-8ade48e4]{display:flex;flex-direction:column;align-items:center;width:100%;height:100%;background-color:#f8f8f8;color:#000;box-sizing:border-box}.sidebar-header[data-v-8ade48e4]{padding:1.25rem;width:100%;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:center;flex-direction:column;border-bottom:.03125rem solid #bbbbbb}.user-profile-card[data-v-8ade48e4]{padding:.3125rem .625rem;width:100%;display:flex;align-items:center;background-color:#fff;box-sizing:border-box;border-radius:.9375rem;box-shadow:0 0 .25rem #ccc}.user-profile-card .left[data-v-8ade48e4]{flex-shrink:0;display:flex;justify-content:center;align-items:center;margin-right:.1875rem}.user-profile-card .center[data-v-8ade48e4]{flex:1;height:0;display:flex;flex-direction:column;align-items:start;justify-content:center}.user-profile-card .right[data-v-8ade48e4]{flex-shrink:0;margin-left:.1875rem;display:flex;align-items:center}.user-profile-card .right .status-dot[data-v-8ade48e4]{width:.3125rem;height:.3125rem;border-radius:50%;background-color:#10b981;margin-right:.5rem;animation:statusDotPulse-8ade48e4 2s ease-in-out infinite}@keyframes statusDotPulse-8ade48e4{0%,to{box-shadow:0 0 .46875rem rgba(59,130,246,.8);transform:scale(1)}50%{box-shadow:0 0 .9375rem rgba(59,130,246,.7);transform:scale(1.1)}}.new-chat-btn[data-v-8ade48e4]{margin-top:.625rem;width:100%;padding:.9375rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center;background:linear-gradient(to right,#3b86ff,#2463df);border-radius:.9375rem;box-shadow:0 0 .25rem rgba(59,134,255,.6)}.new-chat-btn uni-text[data-v-8ade48e4]{font-size:.875rem;font-weight:700;color:#fff}.chat-history[data-v-8ade48e4]{width:100%;padding:.625rem 0;box-sizing:border-box;flex:1;height:0;overflow-y:auto;overflow-x:hidden}.chat-history[data-v-8ade48e4]::-webkit-scrollbar{width:.25rem}.chat-history[data-v-8ade48e4]::-webkit-scrollbar-thumb{background:rgba(59,134,255,.4);border-radius:.09375rem}.chat-history[data-v-8ade48e4]::-webkit-scrollbar-track{background:transparent}.history-header[data-v-8ade48e4]{width:100%;padding:.9375rem;box-sizing:border-box;border-bottom:.03125rem solid #bbbbbb;display:flex;justify-content:space-between;align-items:center}.history-header .history-title-section[data-v-8ade48e4]{display:flex;flex-direction:column}.history-header .history-management[data-v-8ade48e4]{display:flex}.history-header .history-management .history-management-btn[data-v-8ade48e4]{margin-left:.625rem;width:1.875rem;height:1.875rem;display:flex;justify-content:center;align-items:center;font-size:.8125rem;background-color:rgba(221,221,221,.5);border-radius:.3125rem}.history-header .history-management .icon-jia-style[data-v-8ade48e4]{background-color:rgba(16,185,129,.2);color:#059669}.history-header .history-management .icon-duoxuan-style[data-v-8ade48e4]{color:#666}.history-header .history-management .icon-saochu-style[data-v-8ade48e4]{color:red}.history-header .history-management .icon-quxiao-style[data-v-8ade48e4]{color:#3b86ff;box-sizing:border-box}.history-header .history-management .icon-total_selection-style[data-v-8ade48e4]{color:#666}.history-header .history-management .icon-total_selection-style.active[data-v-8ade48e4]{color:#2463df;background:rgba(59,134,255,.2)}.history-header .history-management .icon-shanchu-style[data-v-8ade48e4]{color:red}.history-search-wrap[data-v-8ade48e4]{display:flex;flex-direction:column;width:100%;padding:.625rem .9375rem .1875rem;box-sizing:border-box}.history-search-wrap .history-search-inner[data-v-8ade48e4]{display:flex;width:100%;padding:.3125rem .625rem;box-sizing:border-box;align-items:center;background-color:rgba(194,191,211,.1);border-radius:.9375rem}.history-search-wrap .history-search-inner .search-icon[data-v-8ade48e4]{color:#666!important;font-weight:700;font-size:1.125rem!important}.history-search-wrap .history-search-inner .chat-search-icon[data-v-8ade48e4]{color:#aaf!important;font-weight:700;font-size:1.125rem!important}.history-search-wrap .history-search-inner uni-input[data-v-8ade48e4]{margin-left:.3125rem;box-sizing:border-box}.history-search-wrap .history-search-inner.has-value[data-v-8ade48e4]{background-color:#fff;border:.0625rem solid #aaaaff;box-shadow:0 0 .46875rem #aaf}.chat-history-list[data-v-8ade48e4]{padding:.3125rem .9375rem}.chat-history-list .chat-history-card[data-v-8ade48e4]{display:flex;align-items:center;border:.03125rem solid #3b86ff;background-color:#fff;border-radius:.9375rem;padding:.9375rem;margin-top:.3125rem;box-sizing:border-box}.chat-history-list .is-select-chat[data-v-8ade48e4]{box-shadow:0 0 .15625rem #2463df;background-color:rgba(59,134,255,.1)}.chat-history-list .history-chat-checkbox[data-v-8ade48e4]{width:.9375rem;height:.9375rem;border-radius:.3125rem;display:flex;justify-content:center;align-items:center;border:.03125rem solid #3b86ff}.chat-history-list .history-chat-avatar[data-v-8ade48e4]{width:2.0625rem;height:2.0625rem;border-radius:.625rem;display:flex;justify-content:center;align-items:center;background:rgba(59,134,255,.4);margin-left:.625rem;box-sizing:border-box}.chat-history-list .friend-avatar[data-v-8ade48e4]{display:flex;justify-content:center;align-items:center;border-radius:.625rem;width:100%;height:100%;overflow:hidden}.chat-page[data-v-fb45d58d]{position:relative}.mask[data-v-fb45d58d]{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.5);z-index:998;animation:fadeIn-fb45d58d 1s ease}@keyframes fadeIn-fb45d58d{0%{opacity:0}to{opacity:1}}.chat-sidebar[data-v-fb45d58d]{position:fixed;top:0;left:0;width:calc(100% - 3.125rem);max-width:21.25rem;height:100%;transform:translate(-100%);transition:transform .5s ease;z-index:999}.chat-sidebar.sidebar-show[data-v-fb45d58d]{transform:translate(0)}.ncd-overlay[data-v-fb45d58d]{position:fixed;width:100%;height:100%;left:0;top:0;display:flex;align-items:center;justify-content:center;background-color:rgba(193,193,193,.4);z-index:1000;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(6px)}.ncd-card[data-v-fb45d58d]{width:90%;height:auto;background-color:#fff;border-radius:1.5625rem;padding:1.5625rem;box-sizing:border-box}.ncd-header[data-v-fb45d58d]{display:flex;justify-content:center;width:100%}.ncd-title-eng[data-v-fb45d58d]{display:flex;flex-shrink:0;background-color:#000;padding:.15625rem .25rem;border-radius:.3125rem;justify-content:center;align-items:center}.ncd-title-eng uni-text[data-v-fb45d58d]{color:#fff;font-weight:700;font-size:.9375rem}.ncd-title-zh[data-v-fb45d58d]{margin-left:.3125rem;display:flex;flex:1;height:0;font-size:1.1875rem;font-weight:700;color:#000}.ncd-header uni-icons[data-v-fb45d58d]{display:flex;flex-shrink:0}.ncd-options[data-v-fb45d58d]{display:flex;flex-direction:column;width:100%;justify-content:center;align-items:center;margin-top:.3125rem;box-sizing:border-box}.ncd-option[data-v-fb45d58d]{width:100%;background:#f8fafc;padding:1.5625rem .9375rem;display:flex;border-radius:1rem;margin-top:.625rem;box-sizing:border-box;justify-content:center;align-items:center}.ncd-normal[data-v-fb45d58d]{border:.03125rem solid #e8edf3}.ncd-opt-icon[data-v-fb45d58d]{width:2.5rem;height:2.5rem;border-radius:.9375rem;padding:.3125rem;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:center;align-items:center}.ncd-normal .ncd-opt-icon[data-v-fb45d58d]{background-color:#e2e8f0}.ncd-opt-title[data-v-fb45d58d]{display:flex;flex-direction:column;margin:0 .5rem;box-sizing:border-box;justify-content:center;flex:1;height:0}.ncd-opt-title-1[data-v-fb45d58d]{font-size:.9375rem;font-weight:700;color:#000}.ncd-opt-title-2[data-v-fb45d58d]{font-size:.8125rem;color:#666}.arrow-right-style[data-v-fb45d58d]{display:flex;flex-shrink:0;font-weight:700!important;font-size:.9375rem!important;color:#666!important}.ncd-intelligence[data-v-fb45d58d]{background:linear-gradient(to right,#f5f3ff,#ede9fe);border:.03125rem solid #c4b5fd}.ncd-intelligence .ncd-opt-icon[data-v-fb45d58d]{background-color:#8b5cf6}.close-option-card[data-v-fb45d58d]{width:100%;display:flex;justify-content:flex-end}.close-option-card .iconfont[data-v-fb45d58d]{color:red!important}.chat-option-list[data-v-fb45d58d]{display:flex;width:100%;flex-direction:column}.chat-option[data-v-fb45d58d]{display:flex;justify-content:flex-start;align-items:center;margin:.3125rem 0;box-sizing:border-box}.chat-option .iconfont[data-v-fb45d58d]{font-size:30px}.option-name[data-v-fb45d58d]{font-size:18px;font-weight:400;margin-left:10px;box-sizing:border-box}.chat-wrapper[data-v-fb45d58d]{position:relative;width:100%;height:100%;display:flex;flex-direction:column}.chat-hearder[data-v-fb45d58d]{width:100%;height:auto;padding:.625rem .3125rem;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:flex-start;align-items:center;border-bottom:.03125rem solid #ede9fe}.chat-btn-group[data-v-fb45d58d]{width:100%;height:auto;display:flex;justify-content:flex-start;align-items:center}.head-btn[data-v-fb45d58d]{padding:.3125rem;border:.03125rem solid #ede9fe;border-radius:.625rem;margin:0 .3125rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center}.chat-btn-group .head-btn:nth-child(1) .iconfont[data-v-fb45d58d]{color:#c4b5fd}.chat-btn-group .head-btn:nth-child(2) .iconfont[data-v-fb45d58d]{color:#6495ed}.head-btn .iconfont[data-v-fb45d58d]{font-size:1.5625rem}.log-out .iconfont[data-v-fb45d58d]{color:red}.main-chat[data-v-fb45d58d]{display:flex;flex:1;height:0;width:100%;flex-direction:column}.chat-messages[data-v-fb45d58d]{display:flex;flex:1;height:0;width:100%;padding:0 .625rem;box-sizing:border-box;flex-direction:column;overflow:auto}.chat-message[data-v-fb45d58d]{display:flex;align-items:flex-start;margin:.3125rem 0;box-sizing:border-box}.message-user[data-v-fb45d58d]{flex-direction:row-reverse}.chat-avatar[data-v-fb45d58d]{display:flex;justify-content:center;align-items:center;width:2.5rem;height:2.5rem;box-sizing:border-box;border-radius:.3125rem;margin-right:.3125rem}.friend-avatar[data-v-fb45d58d]{display:flex;justify-content:center;align-items:center;border-radius:.625rem;width:100%;height:100%;overflow:hidden}.chat-avatar-user[data-v-fb45d58d]{margin-right:0;margin-left:.3125rem}.chat-content[data-v-fb45d58d]{width:auto;height:auto;padding:.625rem;box-sizing:border-box;border:.03125rem solid #999;overflow-x:auto}.chat-content-user[data-v-fb45d58d]{background-color:#c4b5fd;color:#fff;border-radius:.625rem}.message-image[data-v-fb45d58d]{max-width:9.375rem;border-radius:.25rem;margin:.1875rem 0}.message-file-list[data-v-fb45d58d]{margin:.25rem 0}.file-item[data-v-fb45d58d]{margin:.1875rem 0}.message-file[data-v-fb45d58d]{display:flex;align-items:center;padding:.375rem .5rem;background:#f7f8fa;border-radius:.25rem;max-width:10.9375rem}.file-icon[data-v-fb45d58d]{font-size:1rem;margin-right:.375rem}.file-name[data-v-fb45d58d]{flex:1;font-size:.8125rem;color:#333;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.file-size[data-v-fb45d58d]{font-size:.6875rem;color:#999;margin-left:.25rem}.chat-interactive-container[data-v-fb45d58d]{display:flex;flex-shrink:0;width:100%;padding:.625rem;box-sizing:border-box;flex-direction:column}.chat-interactive-group[data-v-fb45d58d]{display:flex;width:100%;padding:.625rem;box-sizing:border-box;justify-content:flex-start;align-items:center}.chat-interactive-btn[data-v-fb45d58d]{display:flex;align-items:center;justify-content:center;border:.03125rem solid #000000;border-radius:.3125rem;padding:.3125rem .5rem;margin-right:.625rem;box-sizing:border-box}.chat-input-container[data-v-fb45d58d]{display:flex;width:100%;padding:.625rem;box-sizing:border-box;border:.03125rem solid #c4b5fd;border-radius:.9375rem;align-items:flex-end}.message-input[data-v-fb45d58d]{flex:1;max-height:4.6875rem;min-height:1.875rem;overflow-y:auto;margin:.3125rem;box-sizing:border-box}.input-btn-group[data-v-fb45d58d]{flex-shrink:0;display:flex;justify-content:center;align-items:center;padding:.5rem;box-sizing:border-box;background:#ffd4d4;border:.03125rem solid #ff0000;border-radius:.625rem;width:2.5rem;height:2.5rem}.input-btn-group .iconfont[data-v-fb45d58d]{color:red;font-size:1.25rem}.ai-card[data-v-fb45d58d]{width:auto;border:.03125rem solid #409eff;box-shadow:0 0 .625rem #c4b5fd}.thinking-content[data-v-fb45d58d]{display:flex;flex-direction:column;align-items:center;width:100%}.loading-dots[data-v-fb45d58d]{display:flex;width:100%;align-items:center;justify-content:center}.dot[data-v-fb45d58d]{width:.5rem;height:.5rem;margin:.1875rem;border-radius:50%;background:#409eff;animation:dotBlink-fb45d58d 1.2s infinite ease-in-out}@keyframes dotBlink-fb45d58d{0%,to{opacity:.3;transform:scale(.8)}50%{opacity:1;transform:scale(1)}}.dot[data-v-fb45d58d]:nth-child(2){animation-delay:.2s}.dot[data-v-fb45d58d]:nth-child(3){animation-delay:.4s}.thinking-text[data-v-fb45d58d]{margin:.625rem 0;font-size:22px;font-weight:500;color:#409eff} +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.chat-sidebar-container[data-v-766a2af1]{display:flex;flex-direction:column;align-items:center;width:100%;height:100%;background-color:#f8f8f8;color:#000;box-sizing:border-box}.sidebar-header[data-v-766a2af1]{padding:1.25rem;width:100%;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:center;flex-direction:column;border-bottom:.03125rem solid #bbbbbb}.user-profile-card[data-v-766a2af1]{padding:.3125rem .625rem;width:100%;display:flex;align-items:center;background-color:#fff;box-sizing:border-box;border-radius:.9375rem;box-shadow:0 0 .25rem #ccc}.user-profile-card .left[data-v-766a2af1]{flex-shrink:0;display:flex;justify-content:center;align-items:center;margin-right:.3125rem}.user-profile-card .left .avatar-preview[data-v-766a2af1]{display:flex;justify-content:center;align-items:center;width:3.75rem;height:3.75rem;border-radius:50%;overflow:hidden}.user-profile-card .left .avatar-preview uni-image[data-v-766a2af1]{width:100%;height:100%;object-fit:cover}.user-profile-card .left .avatar-placeholder[data-v-766a2af1]{display:flex;justify-content:center;align-items:center;box-sizing:border-box;border-radius:50%;width:3.75rem;height:3.75rem}.user-profile-card .center[data-v-766a2af1]{flex:1;height:0;display:flex;flex-direction:column;align-items:start;justify-content:center}.user-profile-card .right[data-v-766a2af1]{flex-shrink:0;margin-left:.1875rem;display:flex;align-items:center}.user-profile-card .right .status-dot[data-v-766a2af1]{width:.3125rem;height:.3125rem;border-radius:50%;background-color:#10b981;margin-right:.5rem;animation:statusDotPulse-766a2af1 2s ease-in-out infinite}@keyframes statusDotPulse-766a2af1{0%,to{box-shadow:0 0 .46875rem rgba(59,130,246,.8);transform:scale(1)}50%{box-shadow:0 0 .9375rem rgba(59,130,246,.7);transform:scale(1.1)}}.new-chat-btn[data-v-766a2af1]{margin-top:.625rem;width:100%;padding:.9375rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center;background:linear-gradient(to right,#3b86ff,#2463df);border-radius:.9375rem;box-shadow:0 0 .25rem rgba(59,134,255,.6)}.new-chat-btn uni-text[data-v-766a2af1]{font-size:.875rem;font-weight:700;color:#fff}.chat-history[data-v-766a2af1]{width:100%;padding:.625rem 0;box-sizing:border-box;flex:1;height:0;overflow-y:auto;overflow-x:hidden}.chat-history[data-v-766a2af1]::-webkit-scrollbar{width:.25rem}.chat-history[data-v-766a2af1]::-webkit-scrollbar-thumb{background:rgba(59,134,255,.4);border-radius:.09375rem}.chat-history[data-v-766a2af1]::-webkit-scrollbar-track{background:transparent}.history-header[data-v-766a2af1]{width:100%;padding:.9375rem;box-sizing:border-box;border-bottom:.03125rem solid #bbbbbb;display:flex;justify-content:space-between;align-items:center}.history-header .history-title-section[data-v-766a2af1]{display:flex;flex-direction:column}.history-header .history-management[data-v-766a2af1]{display:flex}.history-header .history-management .history-management-btn[data-v-766a2af1]{margin-left:.625rem;width:1.875rem;height:1.875rem;display:flex;justify-content:center;align-items:center;font-size:.8125rem;background-color:rgba(221,221,221,.5);border-radius:.3125rem}.history-header .history-management .icon-jia-style[data-v-766a2af1]{background-color:rgba(16,185,129,.2);color:#059669}.history-header .history-management .icon-duoxuan-style[data-v-766a2af1]{color:#666}.history-header .history-management .icon-saochu-style[data-v-766a2af1]{color:red}.history-header .history-management .icon-quxiao-style[data-v-766a2af1]{color:#3b86ff;box-sizing:border-box}.history-header .history-management .icon-total_selection-style[data-v-766a2af1]{color:#666}.history-header .history-management .icon-total_selection-style.active[data-v-766a2af1]{color:#2463df;background:rgba(59,134,255,.2)}.history-header .history-management .icon-shanchu-style[data-v-766a2af1]{color:red}.history-search-wrap[data-v-766a2af1]{display:flex;flex-direction:column;width:100%;padding:.625rem .9375rem .1875rem;box-sizing:border-box}.history-search-wrap .history-search-inner[data-v-766a2af1]{display:flex;width:100%;padding:.3125rem .625rem;box-sizing:border-box;align-items:center;background-color:rgba(194,191,211,.1);border-radius:.9375rem}.history-search-wrap .history-search-inner .search-icon[data-v-766a2af1]{color:#666!important;font-weight:700;font-size:1.125rem!important}.history-search-wrap .history-search-inner .chat-search-icon[data-v-766a2af1]{color:#aaf!important;font-weight:700;font-size:1.125rem!important}.history-search-wrap .history-search-inner uni-input[data-v-766a2af1]{margin-left:.3125rem;box-sizing:border-box}.history-search-wrap .history-search-inner.has-value[data-v-766a2af1]{background-color:#fff;border:.0625rem solid #aaaaff;box-shadow:0 0 .46875rem #aaf}.chat-history-list[data-v-766a2af1]{padding:.3125rem .9375rem}.chat-history-list .chat-history-card[data-v-766a2af1]{display:flex;align-items:center;border:.03125rem solid #3b86ff;background-color:#fff;border-radius:.9375rem;padding:.9375rem;margin-top:.3125rem;box-sizing:border-box}.chat-history-list .is-select-chat[data-v-766a2af1]{box-shadow:0 0 .15625rem #2463df;background-color:rgba(59,134,255,.1)}.chat-history-list .history-chat-checkbox[data-v-766a2af1]{width:.9375rem;height:.9375rem;border-radius:.3125rem;display:flex;justify-content:center;align-items:center;border:.03125rem solid #3b86ff}.chat-history-list .history-chat-avatar[data-v-766a2af1]{width:2.0625rem;height:2.0625rem;border-radius:.625rem;display:flex;justify-content:center;align-items:center;background:rgba(59,134,255,.4);margin-left:.625rem;box-sizing:border-box}.chat-history-list .friend-avatar[data-v-766a2af1]{display:flex;justify-content:center;align-items:center;border-radius:.625rem;width:100%;height:100%;overflow:hidden}.chat-page[data-v-92a1a532]{position:relative}.mask[data-v-92a1a532]{position:fixed;top:0;left:0;width:100%;height:100%;background-color:rgba(0,0,0,.5);z-index:998;animation:fadeIn-92a1a532 1s ease}@keyframes fadeIn-92a1a532{0%{opacity:0}to{opacity:1}}.chat-sidebar[data-v-92a1a532]{position:fixed;top:0;left:0;width:calc(100% - 3.125rem);max-width:21.25rem;height:100%;transform:translate(-100%);transition:transform .5s ease;z-index:999}.chat-sidebar.sidebar-show[data-v-92a1a532]{transform:translate(0)}.ncd-overlay[data-v-92a1a532]{position:fixed;width:100%;height:100%;left:0;top:0;display:flex;align-items:center;justify-content:center;background-color:rgba(193,193,193,.4);z-index:1000;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(6px)}.ncd-card[data-v-92a1a532]{width:90%;height:auto;background-color:#fff;border-radius:1.5625rem;padding:1.5625rem;box-sizing:border-box}.ncd-header[data-v-92a1a532]{display:flex;justify-content:center;width:100%}.ncd-title-eng[data-v-92a1a532]{display:flex;flex-shrink:0;background-color:#000;padding:.15625rem .25rem;border-radius:.3125rem;justify-content:center;align-items:center}.ncd-title-eng uni-text[data-v-92a1a532]{color:#fff;font-weight:700;font-size:.9375rem}.ncd-title-zh[data-v-92a1a532]{margin-left:.3125rem;display:flex;flex:1;height:0;font-size:1.1875rem;font-weight:700;color:#000}.ncd-header uni-icons[data-v-92a1a532]{display:flex;flex-shrink:0}.ncd-options[data-v-92a1a532]{display:flex;flex-direction:column;width:100%;justify-content:center;align-items:center;margin-top:.3125rem;box-sizing:border-box}.ncd-option[data-v-92a1a532]{width:100%;background:#f8fafc;padding:1.5625rem .9375rem;display:flex;border-radius:1rem;margin-top:.625rem;box-sizing:border-box;justify-content:center;align-items:center}.ncd-normal[data-v-92a1a532]{border:.03125rem solid #e8edf3}.ncd-opt-icon[data-v-92a1a532]{width:2.5rem;height:2.5rem;border-radius:.9375rem;padding:.3125rem;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:center;align-items:center}.ncd-normal .ncd-opt-icon[data-v-92a1a532]{background-color:#e2e8f0}.ncd-opt-title[data-v-92a1a532]{display:flex;flex-direction:column;margin:0 .5rem;box-sizing:border-box;justify-content:center;flex:1;height:0}.ncd-opt-title-1[data-v-92a1a532]{font-size:.9375rem;font-weight:700;color:#000}.ncd-opt-title-2[data-v-92a1a532]{font-size:.8125rem;color:#666}.arrow-right-style[data-v-92a1a532]{display:flex;flex-shrink:0;font-weight:700!important;font-size:.9375rem!important;color:#666!important}.ncd-intelligence[data-v-92a1a532]{background:linear-gradient(to right,#f5f3ff,#ede9fe);border:.03125rem solid #c4b5fd}.ncd-intelligence .ncd-opt-icon[data-v-92a1a532]{background-color:#8b5cf6}.close-option-card[data-v-92a1a532]{width:100%;display:flex;justify-content:flex-end}.close-option-card .iconfont[data-v-92a1a532]{color:red!important}.chat-option-list[data-v-92a1a532]{display:flex;width:100%;flex-direction:column}.chat-option[data-v-92a1a532]{display:flex;justify-content:flex-start;align-items:center;margin:.3125rem 0;box-sizing:border-box}.chat-option .iconfont[data-v-92a1a532]{font-size:30px}.option-name[data-v-92a1a532]{font-size:18px;font-weight:400;margin-left:10px;box-sizing:border-box}.chat-wrapper[data-v-92a1a532]{position:relative;width:100%;height:100%;display:flex;flex-direction:column}.chat-hearder[data-v-92a1a532]{width:100%;height:auto;padding:.625rem .3125rem;box-sizing:border-box;display:flex;flex-shrink:0;justify-content:flex-start;align-items:center;border-bottom:.03125rem solid #ede9fe}.chat-btn-group[data-v-92a1a532]{width:100%;height:auto;display:flex;justify-content:flex-start;align-items:center}.head-btn[data-v-92a1a532]{padding:.3125rem;border:.03125rem solid #ede9fe;border-radius:.625rem;margin:0 .3125rem;box-sizing:border-box;display:flex;justify-content:center;align-items:center}.chat-btn-group .head-btn:nth-child(1) .iconfont[data-v-92a1a532]{color:#c4b5fd}.chat-btn-group .head-btn:nth-child(2) .iconfont[data-v-92a1a532]{color:#6495ed}.head-btn .iconfont[data-v-92a1a532]{font-size:1.5625rem}.log-out .iconfont[data-v-92a1a532]{color:red}.main-chat[data-v-92a1a532]{display:flex;flex:1;height:0;width:100%;flex-direction:column}.chat-messages[data-v-92a1a532]{display:flex;flex:1;height:0;width:100%;padding:0 .625rem;box-sizing:border-box;flex-direction:column;overflow:auto}.chat-message[data-v-92a1a532]{display:flex;align-items:flex-start;margin:.3125rem 0;box-sizing:border-box}.message-user[data-v-92a1a532]{flex-direction:row-reverse}.chat-avatar[data-v-92a1a532]{display:flex;justify-content:center;align-items:center;width:2.5rem;height:2.5rem;box-sizing:border-box;border-radius:.3125rem;margin-right:.3125rem}.friend-avatar[data-v-92a1a532]{display:flex;justify-content:center;align-items:center;border-radius:.625rem;width:100%;height:100%;overflow:hidden}.chat-avatar-user[data-v-92a1a532]{margin-right:0;margin-left:.3125rem}.chat-content[data-v-92a1a532]{width:auto;max-width:calc(100% - 3.125rem);height:auto;padding:.625rem;box-sizing:border-box;border:.03125rem solid #999;overflow-x:auto}.chat-content-user[data-v-92a1a532]{background-color:#c4b5fd;color:#fff;border-radius:.625rem}.message-image[data-v-92a1a532]{max-width:9.375rem;border-radius:.25rem;margin:.1875rem 0}.message-file-list[data-v-92a1a532]{margin:.25rem 0}.file-item[data-v-92a1a532]{margin:.1875rem 0}.message-file[data-v-92a1a532]{display:flex;align-items:center;padding:.375rem .5rem;background:#f7f8fa;border-radius:.25rem;max-width:10.9375rem}.file-icon[data-v-92a1a532]{font-size:1rem;margin-right:.375rem}.file-name[data-v-92a1a532]{flex:1;font-size:.8125rem;color:#333;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.file-size[data-v-92a1a532]{font-size:.6875rem;color:#999;margin-left:.25rem}.chat-interactive-container[data-v-92a1a532]{display:flex;flex-shrink:0;width:100%;padding:.625rem;box-sizing:border-box;flex-direction:column}.chat-interactive-group[data-v-92a1a532]{display:flex;width:100%;padding:.625rem;box-sizing:border-box;justify-content:flex-start;align-items:center}.chat-interactive-btn[data-v-92a1a532]{display:flex;align-items:center;justify-content:center;border:.03125rem solid #000000;border-radius:.3125rem;padding:.3125rem .5rem;margin-right:.625rem;box-sizing:border-box}.chat-input-container[data-v-92a1a532]{display:flex;width:100%;padding:.625rem;box-sizing:border-box;border:.03125rem solid #c4b5fd;border-radius:.9375rem;align-items:flex-end}.message-input[data-v-92a1a532]{flex:1;max-height:4.6875rem;min-height:1.875rem;overflow-y:auto;margin:.3125rem;box-sizing:border-box}.input-btn-group[data-v-92a1a532]{flex-shrink:0;display:flex;justify-content:center;align-items:center;padding:.5rem;box-sizing:border-box;background:#ffd4d4;border:.03125rem solid #ff0000;border-radius:.625rem;width:2.5rem;height:2.5rem}.input-btn-group .iconfont[data-v-92a1a532]{color:red;font-size:1.25rem}.ai-card[data-v-92a1a532]{width:auto;border:.03125rem solid #409eff;box-shadow:0 0 .625rem #c4b5fd}.thinking-content[data-v-92a1a532]{display:flex;flex-direction:column;align-items:center;width:100%}.loading-dots[data-v-92a1a532]{display:flex;width:100%;align-items:center;justify-content:center}.dot[data-v-92a1a532]{width:.5rem;height:.5rem;margin:.1875rem;border-radius:50%;background:#409eff;animation:dotBlink-92a1a532 1.2s infinite ease-in-out}@keyframes dotBlink-92a1a532{0%,to{opacity:.3;transform:scale(.8)}50%{opacity:1;transform:scale(1)}}.dot[data-v-92a1a532]:nth-child(2){animation-delay:.2s}.dot[data-v-92a1a532]:nth-child(3){animation-delay:.4s}.thinking-text[data-v-92a1a532]{margin:.625rem 0;font-size:22px;font-weight:500;color:#409eff} diff --git a/unpackage/dist/build/app-plus/pages/CloudDatabase/CloudDatabase.css b/unpackage/dist/build/app-plus/pages/CloudDatabase/CloudDatabase.css new file mode 100644 index 0000000..2c0443e --- /dev/null +++ b/unpackage/dist/build/app-plus/pages/CloudDatabase/CloudDatabase.css @@ -0,0 +1 @@ +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.cloud-db-container[data-v-2d96f7d1]{display:flex;flex-direction:column;width:100%;height:100vh;background-color:#f5f6fa}.cloud-db-header[data-v-2d96f7d1]{flex-shrink:0;background-color:#fff;padding-bottom:0}.custom-navbar[data-v-2d96f7d1]{display:flex;align-items:center;justify-content:space-between;padding:.625rem .9375rem;box-sizing:border-box;position:relative}.navbar-left[data-v-2d96f7d1]{display:flex;align-items:center;min-width:5rem}.custom-navbar-icon[data-v-2d96f7d1]{font-size:1.375rem;color:#333}.navbar-title[data-v-2d96f7d1]{font-size:1.125rem;font-weight:600;color:#1a1a2e}.navbar-right[data-v-2d96f7d1]{width:auto;min-width:2.5rem;display:flex;align-items:center;justify-content:flex-end}.navbar-before-title[data-v-2d96f7d1]{font-size:.8125rem;color:#3b86ff;margin-left:.25rem}.navbar-right-text[data-v-2d96f7d1]{font-size:.875rem;color:#3b86ff;font-weight:500}.menu-open[data-v-2d96f7d1]{color:#3b86ff}.menu-card[data-v-2d96f7d1]{position:absolute;top:2.5rem;right:.625rem;background:#fff;border-radius:.5rem;box-shadow:0 .125rem .625rem rgba(0,0,0,.1);padding:.375rem 0;z-index:100;min-width:6.25rem}.menu-card-item[data-v-2d96f7d1]{padding:.625rem 1rem;font-size:.875rem;color:#333}.menu-card-item[data-v-2d96f7d1]:active{background:#f5f6fa}.solid-line[data-v-2d96f7d1]{height:.03125rem;background:#eee;margin:.125rem .625rem}.file-count[data-v-2d96f7d1]{font-size:.75rem;color:#999;font-weight:400}.category-tabs[data-v-2d96f7d1]{display:flex;padding:.3125rem .9375rem 0;gap:1.25rem;border-bottom:.0625rem solid #eee}.category-tab[data-v-2d96f7d1]{font-size:.9375rem;color:#999;padding-bottom:.625rem;position:relative;font-weight:500;transition:color .3s}.category-tab.active[data-v-2d96f7d1]{color:#3b86ff;font-weight:600}.category-tab.active[data-v-2d96f7d1]:after{content:"";position:absolute;bottom:0;left:50%;transform:translate(-50%);width:1.5rem;height:.1875rem;background:#3b86ff;border-radius:.09375rem}.cloud-db-content[data-v-2d96f7d1]{flex:1;min-height:0;padding:.625rem .9375rem;box-sizing:border-box}.section-block[data-v-2d96f7d1]{background:#fff;border-radius:.625rem;padding:.75rem;margin-bottom:.625rem;box-shadow:0 .0625rem .375rem rgba(0,0,0,.04)}.section-header[data-v-2d96f7d1]{display:flex;align-items:center;justify-content:space-between;margin-bottom:.5rem}.section-title[data-v-2d96f7d1]{display:flex;align-items:center;gap:.375rem;font-size:1rem;font-weight:600;color:#1a1a2e}.section-title .iconfont[data-v-2d96f7d1]{font-size:1.125rem;color:#3b86ff}.section-actions[data-v-2d96f7d1]{display:flex;align-items:center;gap:.3125rem}.action-btn[data-v-2d96f7d1]{display:flex;align-items:center;gap:.1875rem;padding:.3125rem .625rem;background:rgba(59,134,255,.08);color:#3b86ff;border-radius:.9375rem;font-size:.75rem;font-weight:500}.section-divider[data-v-2d96f7d1]{height:.0625rem;margin:.125rem 0 .625rem}.empty-tip[data-v-2d96f7d1]{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:1.875rem 0;color:#bbb;font-size:.8125rem;gap:.5rem}.empty-tip .iconfont[data-v-2d96f7d1]{font-size:2.5rem;color:#ddd}.file-grid[data-v-2d96f7d1]{display:flex;flex-wrap:wrap;gap:.5rem}.file-item[data-v-2d96f7d1]{width:calc(33.33% - .375rem);display:flex;flex-direction:column;align-items:center;padding:.625rem .3125rem;border-radius:.5rem;background:#f8f9fc;border:.0625rem solid transparent;transition:all .2s;box-sizing:border-box}.file-item[data-v-2d96f7d1]:active{border-color:#3b86ff;background:rgba(59,134,255,.04)}.file-icon[data-v-2d96f7d1]{width:2.5rem;height:2.5rem;display:flex;align-items:center;justify-content:center;border-radius:.5rem;margin-bottom:.3125rem}.file-icon.is-directory[data-v-2d96f7d1]{background:rgba(255,170,0,.12)}.file-icon.is-directory .iconfont[data-v-2d96f7d1]{font-size:1.5rem;color:orange}.file-icon.is-file[data-v-2d96f7d1]{background:rgba(59,134,255,.1)}.file-icon.is-file .iconfont[data-v-2d96f7d1]{font-size:1.375rem;color:#3b86ff}.file-name[data-v-2d96f7d1]{font-size:.75rem;color:#333;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;width:100%;margin-bottom:.1875rem}.file-meta[data-v-2d96f7d1]{display:flex;gap:.25rem;align-items:center}.file-type-tag[data-v-2d96f7d1]{font-size:.625rem;color:#999;background:#f0f0f0;padding:.0625rem .3125rem;border-radius:.25rem}.file-size[data-v-2d96f7d1]{font-size:.625rem;color:#bbb}.table-list[data-v-2d96f7d1]{display:flex;flex-direction:column;gap:.375rem}.table-item[data-v-2d96f7d1]{display:flex;align-items:center;padding:.625rem;border-radius:.4375rem;background:#f8f9fc;border:.0625rem solid transparent;transition:all .2s}.table-item[data-v-2d96f7d1]:active{border-color:#3b86ff;background:rgba(59,134,255,.03)}.table-icon[data-v-2d96f7d1]{width:2rem;height:2rem;display:flex;align-items:center;justify-content:center;background:rgba(59,134,255,.08);border-radius:.4375rem;margin-right:.625rem;flex-shrink:0}.table-info[data-v-2d96f7d1]{flex:1;min-width:0}.table-name[data-v-2d96f7d1]{font-size:.875rem;font-weight:600;color:#1a1a2e;margin-bottom:.125rem}.table-desc[data-v-2d96f7d1]{font-size:.6875rem;color:#999;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.table-meta[data-v-2d96f7d1]{display:flex;align-items:center;gap:.1875rem;flex-shrink:0}.table-rows[data-v-2d96f7d1]{font-size:.6875rem;color:#bbb}.team-manage-block[data-v-2d96f7d1]{cursor:pointer}.team-count[data-v-2d96f7d1]{font-size:.75rem;color:#999}.team-selector[data-v-2d96f7d1]{padding:0 0 .625rem}.team-scroll[data-v-2d96f7d1]{white-space:nowrap}.team-chip[data-v-2d96f7d1]{display:inline-block;padding:.375rem .875rem;margin-right:.5rem;border-radius:.9375rem;font-size:.8125rem;color:#666;background:#f0f2f5;transition:all .2s}.team-chip.active[data-v-2d96f7d1]{color:#fff;background:#3b86ff;font-weight:500}.team-info[data-v-2d96f7d1]{margin-top:.4375rem;display:flex;align-items:center;flex-wrap:wrap;gap:.375rem}.team-type-tag[data-v-2d96f7d1]{font-size:.6875rem;color:#3b86ff;background:rgba(59,134,255,.1);padding:.1875rem .5rem;border-radius:.25rem;font-weight:500}.team-desc-text[data-v-2d96f7d1]{font-size:.75rem;color:#999;line-height:1.5;flex:1;min-width:0}.select-team-tip[data-v-2d96f7d1]{padding:2.5rem 0}.popup-overlay[data-v-2d96f7d1]{position:fixed;top:0;left:0;width:100vw;height:100vh;background:rgba(0,0,0,.4);z-index:999;display:flex;align-items:center;justify-content:center}.popup-card[data-v-2d96f7d1]{width:18.75rem;background:#fff;border-radius:.9375rem;padding:1.25rem .9375rem;box-sizing:border-box;position:relative;max-height:80vh;display:flex;flex-direction:column}.close-popup-card[data-v-2d96f7d1]{position:absolute;top:.625rem;right:.625rem;width:1.5625rem;height:1.5625rem;display:flex;align-items:center;justify-content:center}.close-popup-card .iconfont[data-v-2d96f7d1]{font-size:1.25rem;color:#999}.popup-title[data-v-2d96f7d1]{font-size:1.0625rem;font-weight:600;color:#1a1a2e;margin-bottom:.9375rem;text-align:center}.new-folder-name[data-v-2d96f7d1]{font-size:.8125rem;color:#666;margin-bottom:.3125rem}.create-folder-name[data-v-2d96f7d1]{margin-bottom:.625rem}.create-folder-name uni-input[data-v-2d96f7d1]{width:100%;height:auto;padding:.625rem;box-sizing:border-box;border:.03125rem solid #e0e0e0;border-radius:.5rem;font-size:.875rem;background:#f9fafb}.create-folder-name uni-input[data-v-2d96f7d1]:focus{border-color:#3b86ff;background:#fff}.nf-path-label[data-v-2d96f7d1]{font-size:.75rem;color:#999;margin-bottom:.25rem}.nf-path-display[data-v-2d96f7d1]{font-size:.75rem;color:#3b86ff;background:rgba(59,134,255,.06);padding:.375rem .5rem;border-radius:.3125rem;margin-bottom:.625rem}.option-wrapper[data-v-2d96f7d1]{display:flex;gap:.625rem;justify-content:flex-end;margin-top:.3125rem}.opt-btn[data-v-2d96f7d1]{padding:.5rem 1.25rem;border-radius:.9375rem;font-size:.875rem;font-weight:500}.opt-cancel[data-v-2d96f7d1]{color:#999;background:#f0f2f5}.opt-confirm[data-v-2d96f7d1]{color:#fff;background:#3b86ff}.team-manage-body[data-v-2d96f7d1]{flex:1;min-height:0;max-height:15.625rem;margin-bottom:.625rem}.member-list[data-v-2d96f7d1]{display:flex;flex-direction:column;gap:.3125rem}.member-item[data-v-2d96f7d1]{display:flex;align-items:center;padding:.5rem;border-radius:.4375rem;background:#f8f9fc}.member-avatar[data-v-2d96f7d1]{width:2.1875rem;height:2.1875rem;border-radius:50%;overflow:hidden;margin-right:.5rem;flex-shrink:0}.member-avatar uni-image[data-v-2d96f7d1]{width:100%;height:100%}.default-avatar[data-v-2d96f7d1]{width:100%;height:100%;background:#ccc;display:flex;align-items:center;justify-content:center}.member-info[data-v-2d96f7d1]{flex:1;min-width:0}.member-name[data-v-2d96f7d1]{font-size:.875rem;font-weight:500;color:#333}.member-label[data-v-2d96f7d1]{font-size:.6875rem;color:#999;margin-top:.125rem}.member-actions[data-v-2d96f7d1]{flex-shrink:0}.member-role[data-v-2d96f7d1]{font-size:.6875rem;padding:.1875rem .5rem;border-radius:.625rem}.member-role.owner[data-v-2d96f7d1]{color:#e6a23c;background:rgba(230,162,60,.1)}.member-role.admin[data-v-2d96f7d1]{color:#3b86ff;background:rgba(59,134,255,.1)}.member-role.member[data-v-2d96f7d1]{color:#67c23a;background:rgba(103,194,58,.1)}.member-actions-right[data-v-2d96f7d1]{display:flex;gap:.25rem}.member-action-btn[data-v-2d96f7d1]{font-size:.625rem;padding:.25rem .4375rem;border-radius:.5rem}.set-admin[data-v-2d96f7d1]{color:#3b86ff;border:.03125rem solid #3b86ff}.demote-admin[data-v-2d96f7d1]{color:#e6a23c;border:.03125rem solid #e6a23c}.remove-member[data-v-2d96f7d1]{color:#f56c6c;border:.03125rem solid #f56c6c}.invite-section[data-v-2d96f7d1]{border-top:.03125rem solid #eee;padding-top:.625rem}.invite-input-wrapper[data-v-2d96f7d1]{display:flex;align-items:center;gap:.5rem}.invite-input[data-v-2d96f7d1]{flex:1;height:auto;padding:.5625rem .625rem;box-sizing:border-box;border:.03125rem solid #e0e0e0;border-radius:.9375rem;font-size:.8125rem;background:#f9fafb}.invite-btn[data-v-2d96f7d1]{background:#3b86ff;color:#fff;font-size:.75rem;padding:.4375rem 1rem}.search-result-list[data-v-2d96f7d1]{margin-top:.5rem;border-radius:.4375rem;overflow:hidden;background:#f8f9fc}.search-result-item[data-v-2d96f7d1]{display:flex;align-items:center;padding:.5625rem .625rem;border-bottom:.03125rem solid #eee}.search-result-item[data-v-2d96f7d1]:last-child{border-bottom:none}.search-result-item[data-v-2d96f7d1]:active{background:rgba(59,134,255,.05)}.result-avatar[data-v-2d96f7d1]{width:2rem;height:2rem;border-radius:50%;flex-shrink:0;margin-right:.5rem}.result-default-avatar[data-v-2d96f7d1]{width:2rem;height:2rem;border-radius:50%;background:linear-gradient(135deg,#3b86ff,#6db3ff);display:flex;align-items:center;justify-content:center;flex-shrink:0;margin-right:.5rem}.result-info[data-v-2d96f7d1]{flex:1;min-width:0;display:flex;flex-direction:column;gap:.125rem}.result-name[data-v-2d96f7d1]{font-size:.875rem;color:#333;font-weight:500}.result-email[data-v-2d96f7d1]{font-size:.6875rem;color:#999;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.result-add-btn[data-v-2d96f7d1]{flex-shrink:0;font-size:.75rem;color:#3b86ff;padding:.3125rem .75rem;border:.03125rem solid #3b86ff;border-radius:.625rem}.search-empty[data-v-2d96f7d1]{margin-top:.5rem;text-align:center;font-size:.75rem;color:#bbb;padding:.625rem 0}.folder-null[data-v-2d96f7d1]{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:1.875rem 0;color:#bbb;font-size:.8125rem;gap:.375rem}.folder-null .iconfont[data-v-2d96f7d1]{font-size:2rem;color:#ddd}.delete-team-section[data-v-2d96f7d1]{border-top:.03125rem solid #eee;padding-top:.625rem;margin-top:.3125rem}.delete-team-btn[data-v-2d96f7d1]{text-align:center;padding:.5625rem;font-size:.8125rem;color:#e74c3c;background:rgba(231,76,60,.06);border-radius:.4375rem;border:.03125rem solid rgba(231,76,60,.2)}.delete-team-btn[data-v-2d96f7d1]:active{background:rgba(231,76,60,.12)}.edit-team-section[data-v-2d96f7d1]{border-top:.03125rem solid #eee;padding-top:.625rem;margin-top:.3125rem}.edit-team-btn[data-v-2d96f7d1]{text-align:center;padding:.5625rem;font-size:.8125rem;color:#3b86ff;background:rgba(59,134,255,.06);border-radius:.4375rem;border:.03125rem solid rgba(59,134,255,.2)}.edit-team-btn[data-v-2d96f7d1]:active{background:rgba(59,134,255,.12)}.edit-team-form[data-v-2d96f7d1]{margin-bottom:.3125rem}.form-label[data-v-2d96f7d1]{font-size:.8125rem;color:#666;margin-bottom:.25rem;margin-top:.5625rem}.text-btn[data-v-2d96f7d1]{padding:.25rem .625rem;border-radius:.9375rem;font-size:14px;font-weight:500}.upload-path-label[data-v-2d96f7d1]{font-size:.8125rem;color:#666;margin-bottom:.3125rem}.upload-path-hint[data-v-2d96f7d1]{font-size:.6875rem;color:#999;margin-bottom:.625rem;text-align:center}.loading-area[data-v-2d96f7d1]{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:1.875rem 0;gap:.5rem}.loading-spinner[data-v-2d96f7d1]{width:1.75rem;height:1.75rem;border:.125rem solid #e8e8e8;border-top-color:#3b86ff;border-radius:50%;animation:spin-2d96f7d1 .8s linear infinite}@keyframes spin-2d96f7d1{to{transform:rotate(360deg)}}.loading-text[data-v-2d96f7d1]{font-size:.75rem;color:#999}.db-tag[data-v-2d96f7d1]{display:inline-block;font-size:.625rem;font-weight:500;padding:.0625rem .375rem;border-radius:.25rem;margin-left:.3125rem;vertical-align:middle}.db-tag.tag-personal[data-v-2d96f7d1]{color:#3b86ff;background:rgba(59,134,255,.08);border:.03125rem solid rgba(59,134,255,.2)}.db-tag.tag-team[data-v-2d96f7d1]{color:#67c23a;background:rgba(103,194,58,.08);border:.03125rem solid rgba(103,194,58,.2)}.upload-db-hint[data-v-2d96f7d1]{font-size:.6875rem;color:#999;margin-bottom:.625rem;text-align:center}.upload-file-area[data-v-2d96f7d1]{padding:1.25rem;border:.0625rem dashed #d0d0d0;border-radius:.5rem;background:#f9fafb;text-align:center;margin-bottom:.625rem}.upload-file-area[data-v-2d96f7d1]:active{border-color:#3b86ff;background:rgba(59,134,255,.03)}.selected-file[data-v-2d96f7d1]{font-size:.8125rem;color:#3b86ff;font-weight:500;word-break:break-all}.upload-hint[data-v-2d96f7d1]{font-size:.75rem;color:#bbb} diff --git a/unpackage/dist/build/app-plus/pages/CloudDbDetail/CloudDbDetail.css b/unpackage/dist/build/app-plus/pages/CloudDbDetail/CloudDbDetail.css new file mode 100644 index 0000000..06239d4 --- /dev/null +++ b/unpackage/dist/build/app-plus/pages/CloudDbDetail/CloudDbDetail.css @@ -0,0 +1 @@ +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.status-bar[data-v-144a6cf9]{height:var(--status-bar-height);background-color:#fff}.page-container[data-v-144a6cf9]{display:flex;flex-direction:column;height:100vh;background-color:#f5f6fa}.cloud-db-header[data-v-144a6cf9]{background-color:#fff;flex-shrink:0;position:relative;z-index:10}.custom-navbar[data-v-144a6cf9]{display:flex;align-items:center;justify-content:space-between;height:2.75rem;padding:0 .9375rem}.navbar-left[data-v-144a6cf9]{display:flex;align-items:center;min-width:3.75rem}.custom-navbar-icon[data-v-144a6cf9]{font-size:1.25rem;color:#333}.navbar-title[data-v-144a6cf9]{font-size:1.0625rem;font-weight:600;color:#333;flex:1;text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.navbar-right[data-v-144a6cf9]{min-width:3.75rem;display:flex;justify-content:flex-end}.menu-card[data-v-144a6cf9]{position:absolute;top:2.75rem;right:.625rem;background:#fff;border-radius:.5rem;box-shadow:0 .25rem 1rem rgba(0,0,0,.12);z-index:500;overflow:hidden;min-width:6.25rem}.menu-card-item[data-v-144a6cf9]{padding:.75rem 1.125rem;font-size:.875rem;color:#333;text-align:center}.menu-card-item[data-v-144a6cf9]:active{background-color:#f5f6fa}.solid-line[data-v-144a6cf9]{height:.03125rem;background-color:#eee;margin:0 .625rem}.db-info-bar[data-v-144a6cf9]{display:flex;align-items:center;gap:.75rem;padding:.625rem .9375rem;background:#fff;border-bottom:.03125rem solid #f0f0f0}.db-info-text[data-v-144a6cf9]{font-size:.75rem;color:#999}.cloud-db-content[data-v-144a6cf9]{flex:1;overflow-y:auto}.section-block[data-v-144a6cf9]{margin:.625rem;background:#fff;border-radius:.625rem;overflow:hidden}.section-header[data-v-144a6cf9]{display:flex;align-items:center;justify-content:space-between;padding:.75rem .9375rem;border-bottom:.03125rem solid #f5f6fa}.section-title[data-v-144a6cf9]{display:flex;align-items:center;gap:.375rem;font-size:.9375rem;font-weight:600;color:#333}.section-title .iconfont[data-v-144a6cf9]{font-size:1.125rem;color:#3b86ff}.section-actions[data-v-144a6cf9]{display:flex;align-items:center;gap:.5rem}.row-count[data-v-144a6cf9]{font-size:.75rem;color:#999}.section-divider[data-v-144a6cf9]{height:.03125rem;background-color:#f0f0f0;margin:0 .625rem}.section-body[data-v-144a6cf9]{padding:.5rem 0}.empty-tip[data-v-144a6cf9]{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:1.875rem 0;color:#ccc;font-size:.8125rem}.empty-tip .iconfont[data-v-144a6cf9]{font-size:2.5rem;margin-bottom:.5rem}.table-list[data-v-144a6cf9]{padding:0 .9375rem}.table-item[data-v-144a6cf9]{display:flex;align-items:center;padding:.75rem 0;border-bottom:.03125rem solid #f5f6fa}.table-item[data-v-144a6cf9]:last-child{border-bottom:none}.table-item[data-v-144a6cf9]:active{background-color:#fafbfc;margin:0 -.9375rem;padding-left:.9375rem;padding-right:.9375rem}.table-icon[data-v-144a6cf9]{width:2.25rem;height:2.25rem;border-radius:.5rem;background:rgba(59,134,255,.08);display:flex;align-items:center;justify-content:center;margin-right:.625rem;flex-shrink:0}.table-info[data-v-144a6cf9]{flex:1;overflow:hidden}.table-name[data-v-144a6cf9]{font-size:.9375rem;font-weight:500;color:#333;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.table-desc[data-v-144a6cf9]{font-size:.75rem;color:#999;margin-top:.125rem}.table-meta[data-v-144a6cf9]{display:flex;align-items:center;gap:.25rem;flex-shrink:0}.data-table-wrapper[data-v-144a6cf9]{padding:0}.data-table-scroll[data-v-144a6cf9]{width:100%}.data-table[data-v-144a6cf9]{min-width:100%}.data-row[data-v-144a6cf9]{display:flex;flex-direction:row;border-bottom:.03125rem solid #f0f0f0}.data-row[data-v-144a6cf9]:last-child{border-bottom:none}.data-header[data-v-144a6cf9]{background-color:#f8f9fb}.data-cell[data-v-144a6cf9]{padding:.5rem .625rem;font-size:.8125rem;color:#333;min-width:5rem;max-width:9.375rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-right:.03125rem solid #f0f0f0;flex-shrink:0}.data-cell[data-v-144a6cf9]:last-child{border-right:none}.data-header .data-cell[data-v-144a6cf9]{font-weight:600;color:#666;font-size:.75rem}.index-cell[data-v-144a6cf9]{min-width:2.5rem!important;max-width:2.5rem!important;text-align:center;color:#999;font-size:.75rem}.data-row[data-v-144a6cf9]:active{background-color:#f5f7fa}.popup-overlay[data-v-144a6cf9]{position:fixed;top:0;left:0;right:0;bottom:0;background:rgba(0,0,0,.5);display:flex;align-items:center;justify-content:center;z-index:900}.popup-card[data-v-144a6cf9]{width:20rem;background:#fff;border-radius:.75rem;padding:1.25rem 1.125rem .9375rem;position:relative}.close-popup-card[data-v-144a6cf9]{position:absolute;top:.625rem;right:.625rem;width:1.5rem;height:1.5rem;display:flex;align-items:center;justify-content:center}.close-popup-card .iconfont[data-v-144a6cf9]{font-size:1.125rem;color:#999}.popup-title[data-v-144a6cf9]{font-size:1.0625rem;font-weight:600;color:#333;text-align:center;margin-bottom:.9375rem}.new-folder-name[data-v-144a6cf9]{font-size:.8125rem;color:#666;margin-bottom:.375rem}.create-folder-name[data-v-144a6cf9]{margin-bottom:.75rem}.create-folder-name uni-input[data-v-144a6cf9]{width:100%;height:2.5rem;border:.0625rem solid #e0e0e0;border-radius:.375rem;padding:0 .625rem;font-size:.875rem;box-sizing:border-box;background:#f8f9fb}.upload-file-area[data-v-144a6cf9]{width:100%;height:3.75rem;border:.0625rem dashed #d0d0d0;border-radius:.375rem;display:flex;align-items:center;justify-content:center;margin-bottom:.75rem;background:#fafbfc}.selected-file[data-v-144a6cf9]{font-size:.8125rem;color:#3b86ff}.upload-hint[data-v-144a6cf9]{font-size:.75rem;color:#999}.option-wrapper[data-v-144a6cf9]{display:flex;gap:.625rem;margin-top:.3125rem}.opt-btn[data-v-144a6cf9]{flex:1;height:2.5rem;border-radius:.375rem;display:flex;align-items:center;justify-content:center;font-size:.9375rem}.opt-cancel[data-v-144a6cf9]{background:#f5f6fa;color:#666}.opt-confirm[data-v-144a6cf9]{background:#3b86ff;color:#fff}.permission-body[data-v-144a6cf9]{max-height:18.75rem;margin-bottom:.625rem}.permission-list[data-v-144a6cf9]{padding:0 .3125rem}.permission-item[data-v-144a6cf9]{display:flex;align-items:center;padding:.625rem .3125rem;border-bottom:.03125rem solid #f0f0f0}.perm-info[data-v-144a6cf9]{flex:1;display:flex;flex-direction:column;gap:.125rem}.perm-name[data-v-144a6cf9]{font-size:.875rem;color:#333}.perm-type[data-v-144a6cf9]{font-size:.6875rem;color:#999}.perm-level[data-v-144a6cf9]{font-size:.75rem;color:#3b86ff;background:rgba(59,134,255,.08);padding:.1875rem .5rem;border-radius:.25rem;margin:0 .5rem}.perm-actions[data-v-144a6cf9]{display:flex;gap:.375rem}.perm-action-btn[data-v-144a6cf9]{font-size:.75rem;color:#3b86ff;padding:.25rem .5rem;border:.03125rem solid #3b86ff;border-radius:.25rem}.perm-action-btn.delete[data-v-144a6cf9]{color:#f56c6c;border-color:#f56c6c}.close-permission-btn[data-v-144a6cf9]{text-align:center;font-size:.875rem;color:#999;padding:.5rem 0}.folder-null[data-v-144a6cf9]{text-align:center;padding:1.25rem 0;font-size:.8125rem;color:#999}.transfer-body[data-v-144a6cf9]{max-height:15.625rem;margin-bottom:.625rem}.transfer-list[data-v-144a6cf9]{padding:0 .3125rem}.transfer-item[data-v-144a6cf9]{display:flex;align-items:center;justify-content:space-between;padding:.75rem .5rem;border-bottom:.03125rem solid #f0f0f0;border-radius:.375rem;margin-bottom:.25rem}.transfer-item.active[data-v-144a6cf9]{background:rgba(59,134,255,.06)}.transfer-name[data-v-144a6cf9]{font-size:.875rem;color:#333}.loading-area[data-v-144a6cf9]{display:flex;flex-direction:column;align-items:center;justify-content:center;padding:1.875rem 0;gap:.5rem}.loading-spinner[data-v-144a6cf9]{width:1.75rem;height:1.75rem;border:.125rem solid #e8e8e8;border-top-color:#3b86ff;border-radius:50%;animation:spin-144a6cf9 .8s linear infinite}@keyframes spin-144a6cf9{to{transform:rotate(360deg)}}.loading-text[data-v-144a6cf9]{font-size:.75rem;color:#999} diff --git a/unpackage/dist/build/app-plus/pages/ContactPages/ContactPages.css b/unpackage/dist/build/app-plus/pages/ContactPages/ContactPages.css index ee251b8..79a1ec5 100644 --- a/unpackage/dist/build/app-plus/pages/ContactPages/ContactPages.css +++ b/unpackage/dist/build/app-plus/pages/ContactPages/ContactPages.css @@ -1 +1 @@ -.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.tabbar-page[data-v-35441fc3]{display:flex;flex-direction:column}.content-swiper[data-v-35441fc3]{width:100%;height:calc(100% - 3.125rem)}.tabpage-content[data-v-35441fc3]{display:flex;flex-direction:column;width:100%;height:100%}.tabpage-containner[data-v-35441fc3]{width:100%;height:100%;display:flex;align-items:center;flex-direction:column}.tabpage-header[data-v-35441fc3]{width:100%;display:flex;align-items:center;flex-shrink:0}.tabpage-header .iconfont[data-v-35441fc3]{font-size:1.5625rem;margin-right:.3125rem}.tabpage-title[data-v-35441fc3]{font-size:1.25rem}.tabpage-body[data-v-35441fc3]{width:100%;display:flex;flex:1;min-height:0;align-items:center;flex-direction:column;padding:.625rem;box-sizing:border-box}.group-info[data-v-35441fc3]{width:100%;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:center;flex-shrink:0}.group-name[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}.group-name .input[data-v-35441fc3]{width:100%;height:auto;padding:.625rem;box-sizing:border-box;border:.03125rem solid #007aff;border-radius:.9375rem}.group-member-wrapper[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:.625rem;box-sizing:border-box;background-color:rgba(16,185,129,.05);border:.03125rem solid rgba(16,185,129,.2);border-radius:.9375rem;margin:.3125rem 0}.group-member-wrapper .member-title[data-v-35441fc3]{color:#059669;font-weight:700}.group-ismember-list[data-v-35441fc3]{display:flex;flex-wrap:wrap;margin-top:.3125rem;box-sizing:border-box;max-height:6.25rem;overflow-y:auto}.group-ismember-info[data-v-35441fc3]{padding:.3125rem .5rem;box-sizing:border-box;border:.03125rem solid rgba(16,185,129,.8);background-color:#fff;border-radius:.9375rem;margin:.15625rem .3125rem}.group-ismember-name[data-v-35441fc3]{font-size:.6875rem;color:#059669}.create-group-btn[data-v-35441fc3]{width:100%;background:#007aff;border-radius:.9375rem;padding:.625rem;box-sizing:border-box;font-weight:700;color:#fff;display:flex;justify-content:center;align-items:center;margin-bottom:.3125rem}.group-member[data-v-35441fc3]{display:flex;flex-direction:column;flex:1;min-height:0;padding:.3125rem;margin-top:.3125rem;box-sizing:border-box}.friend-list[data-v-35441fc3]{display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.friend-card[data-v-35441fc3]{display:flex;justify-content:flex-start;align-items:center;width:100%;padding:.625rem;margin:.3125rem 0;box-sizing:border-box;border:.03125rem solid #aaaaff;border-radius:.9375rem}.friend-card-left[data-v-35441fc3]{flex-shrink:0;margin-right:.3125rem}.friend-avatar[data-v-35441fc3]{display:flex;justify-content:center;align-items:center;width:3.125rem;height:3.125rem;border-radius:50%;overflow:hidden}.friend-card-middle[data-v-35441fc3]{flex:1;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.friend-name[data-v-35441fc3]{font-weight:500;font-size:1rem}.friend-card-right[data-v-35441fc3]{width:auto;flex-shrink:0;display:flex;justify-content:center;align-items:center}.friend-checkbox[data-v-35441fc3]{width:.9375rem;height:.9375rem;border-radius:.3125rem;display:flex;justify-content:center;align-items:center;border:.03125rem solid #3b86ff}.search-warpper[data-v-35441fc3]{width:100%;display:flex;align-items:center}.search-warpper .search-file-input[data-v-35441fc3]{flex:1;background-color:#f9fafb;border:.0625rem solid rgba(139,195,232,.2);padding:.625rem;margin-right:.625rem;height:auto;box-sizing:border-box;border-radius:.9375rem}.search-file-input.active[data-v-35441fc3]{background-color:#fff;box-shadow:0 0 .46875rem #aaf;border-color:#007aff}.search-warpper .iconfont[data-v-35441fc3]{flex-shrink:0;font-size:1.1875rem;font-weight:700;color:#fff;background-color:#007aff;padding:.5625rem;box-sizing:border-box;border-radius:.625rem}.search-result[data-v-35441fc3]{width:100%}.add-btn[data-v-35441fc3]{background:#3b86ff;color:#fff;font-size:14px;font-weight:500}.nickname-wrapper[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;margin:.625rem 0;box-sizing:border-box}.input-nickname[data-v-35441fc3]{width:100%;height:auto;padding:.625rem;border:.03125rem solid #007aff;border-radius:.9375rem;margin:.625rem 0;box-sizing:border-box}.confirm-btn[data-v-35441fc3]{background:#3b86ff;color:#fff;font-size:16px;font-weight:500;padding:10px}.create-meeting-wrapper[data-v-35441fc3],.join-meeting-wrapper[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:.625rem .9375rem;box-sizing:border-box}.input-meeting[data-v-35441fc3]{width:100%;height:auto;padding:.625rem;border:.03125rem solid #007aff;border-radius:.9375rem;margin:.3125rem 0;box-sizing:border-box}.meeting-btn[data-v-35441fc3]{width:100%;background:#007aff;margin:.3125rem 0;color:#fff}.meeting-field[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.meeting-toggles[data-v-35441fc3]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}.meeting-toggles-item[data-v-35441fc3]{width:100%;display:flex;justify-content:space-between}.friend-option[data-v-35441fc3]{display:flex;justify-content:center;align-items:center}.agree-btn[data-v-35441fc3],.refuse-btn[data-v-35441fc3]{font-size:14px;font-weight:500;border:1px solid #666;margin-left:.3125rem;box-sizing:border-box}.contact-list[data-v-35441fc3]{display:flex;height:100%;padding:.3125rem;margin-top:.3125rem;box-sizing:border-box}.bottom-tabbar[data-v-35441fc3]{width:100%;height:4.375rem;display:flex;justify-content:space-between;align-items:center;padding:.625rem;box-sizing:border-box;background:rgba(200,200,200,.1)}.tab-item[data-v-35441fc3]{display:flex;flex-direction:column;justify-content:center;align-items:center}.tab-label[data-v-35441fc3]{font-size:.875rem} +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.tabbar-page[data-v-d6fd7c06]{display:flex;flex-direction:column}.content-swiper[data-v-d6fd7c06]{width:100%;height:calc(100% - 3.125rem)}.tabpage-content[data-v-d6fd7c06]{display:flex;flex-direction:column;width:100%;height:100%}.tabpage-containner[data-v-d6fd7c06]{width:100%;height:100%;display:flex;align-items:center;flex-direction:column}.tabpage-header[data-v-d6fd7c06]{width:100%;display:flex;align-items:center;flex-shrink:0}.tabpage-header .iconfont[data-v-d6fd7c06]{font-size:1.5625rem;margin-right:.3125rem}.tabpage-title[data-v-d6fd7c06]{font-size:1.25rem}.tabpage-body[data-v-d6fd7c06]{width:100%;display:flex;flex:1;min-height:0;align-items:center;flex-direction:column;padding:.625rem;box-sizing:border-box}.group-info[data-v-d6fd7c06]{width:100%;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:center;flex-shrink:0}.group-name[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}.group-name .input[data-v-d6fd7c06]{width:100%;height:auto;padding:.625rem;box-sizing:border-box;border:.03125rem solid #007aff;border-radius:.9375rem}.group-member-wrapper[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:.625rem;box-sizing:border-box;background-color:rgba(16,185,129,.05);border:.03125rem solid rgba(16,185,129,.2);border-radius:.9375rem;margin:.3125rem 0}.group-member-wrapper .member-title[data-v-d6fd7c06]{color:#059669;font-weight:700}.group-ismember-list[data-v-d6fd7c06]{display:flex;flex-wrap:wrap;margin-top:.3125rem;box-sizing:border-box;max-height:6.25rem;overflow-y:auto}.group-ismember-info[data-v-d6fd7c06]{padding:.3125rem .5rem;box-sizing:border-box;border:.03125rem solid rgba(16,185,129,.8);background-color:#fff;border-radius:.9375rem;margin:.15625rem .3125rem}.group-ismember-name[data-v-d6fd7c06]{font-size:.6875rem;color:#059669}.create-group-btn[data-v-d6fd7c06]{width:100%;background:#007aff;border-radius:.9375rem;padding:.625rem;box-sizing:border-box;font-weight:700;color:#fff;display:flex;justify-content:center;align-items:center;margin-bottom:.3125rem}.group-member[data-v-d6fd7c06]{display:flex;flex-direction:column;flex:1;min-height:0;padding:.3125rem;margin-top:.3125rem;box-sizing:border-box}.friend-list[data-v-d6fd7c06]{display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.friend-card[data-v-d6fd7c06]{display:flex;justify-content:flex-start;align-items:center;width:100%;padding:.625rem;margin:.3125rem 0;box-sizing:border-box;border:.03125rem solid #aaaaff;border-radius:.9375rem}.friend-card-left[data-v-d6fd7c06]{flex-shrink:0;margin-right:.3125rem}.friend-avatar[data-v-d6fd7c06]{display:flex;justify-content:center;align-items:center;width:3.125rem;height:3.125rem;border-radius:50%;overflow:hidden}.friend-card-middle[data-v-d6fd7c06]{flex:1;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.friend-name[data-v-d6fd7c06]{font-weight:500;font-size:1rem}.friend-card-right[data-v-d6fd7c06]{width:auto;flex-shrink:0;display:flex;justify-content:center;align-items:center}.friend-checkbox[data-v-d6fd7c06]{width:.9375rem;height:.9375rem;border-radius:.3125rem;display:flex;justify-content:center;align-items:center;border:.03125rem solid #3b86ff}.search-warpper[data-v-d6fd7c06]{width:100%;display:flex;align-items:center}.search-warpper .search-file-input[data-v-d6fd7c06]{flex:1;background-color:#f9fafb;border:.0625rem solid rgba(139,195,232,.2);padding:.625rem;margin-right:.625rem;height:auto;box-sizing:border-box;border-radius:.9375rem}.search-file-input.active[data-v-d6fd7c06]{background-color:#fff;box-shadow:0 0 .46875rem #aaf;border-color:#007aff}.search-warpper .iconfont[data-v-d6fd7c06]{flex-shrink:0;font-size:1.1875rem;font-weight:700;color:#fff;background-color:#007aff;padding:.5625rem;box-sizing:border-box;border-radius:.625rem}.search-result[data-v-d6fd7c06]{width:100%}.add-btn[data-v-d6fd7c06]{background:#3b86ff;color:#fff;font-size:14px;font-weight:500}.nickname-wrapper[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;margin:.625rem 0;box-sizing:border-box}.input-nickname[data-v-d6fd7c06]{width:100%;height:auto;padding:.625rem;border:.03125rem solid #007aff;border-radius:.9375rem;margin:.625rem 0;box-sizing:border-box}.confirm-btn[data-v-d6fd7c06]{background:#3b86ff;color:#fff;font-size:16px;font-weight:500;padding:10px}.create-meeting-wrapper[data-v-d6fd7c06],.join-meeting-wrapper[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:.625rem .9375rem;box-sizing:border-box}.input-meeting[data-v-d6fd7c06]{width:100%;height:auto;padding:.625rem;border:.03125rem solid #007aff;border-radius:.9375rem;margin:.3125rem 0;box-sizing:border-box}.meeting-btn[data-v-d6fd7c06]{width:100%;background:#007aff;margin:.3125rem 0;color:#fff}.meeting-field[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:flex-start}.meeting-toggles[data-v-d6fd7c06]{width:100%;display:flex;flex-direction:column;justify-content:center;align-items:center}.meeting-toggles-item[data-v-d6fd7c06]{width:100%;display:flex;justify-content:space-between}.friend-option[data-v-d6fd7c06]{display:flex;justify-content:center;align-items:center}.agree-btn[data-v-d6fd7c06]{font-size:14px;font-weight:500;border:1px solid #3b86ff;color:#3b86ff;box-sizing:border-box}.friend-status[data-v-d6fd7c06]{font-size:14px;font-weight:500;padding:.25rem .625rem;border-radius:.9375rem}.friend-status.agreed[data-v-d6fd7c06]{color:#059669;background-color:rgba(16,185,129,.1)}.contact-list[data-v-d6fd7c06]{display:flex;height:100%;padding:.3125rem;margin-top:.3125rem;box-sizing:border-box}.bottom-tabbar[data-v-d6fd7c06]{width:100%;height:4.375rem;display:flex;justify-content:space-between;align-items:center;padding:.625rem;box-sizing:border-box;background:rgba(200,200,200,.1)}.tab-item[data-v-d6fd7c06]{display:flex;flex-direction:column;justify-content:center;align-items:center}.tab-label[data-v-d6fd7c06]{font-size:.875rem} diff --git a/unpackage/dist/build/app-plus/pages/UserProfileModal/UserProfileModal.css b/unpackage/dist/build/app-plus/pages/UserProfileModal/UserProfileModal.css index 65df7d2..139ae75 100644 --- a/unpackage/dist/build/app-plus/pages/UserProfileModal/UserProfileModal.css +++ b/unpackage/dist/build/app-plus/pages/UserProfileModal/UserProfileModal.css @@ -1 +1 @@ -.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.user-profile[data-v-d1eea957]{display:flex;flex-direction:column;align-items:center;background-color:rgba(193,193,193,.1)}.modal-header[data-v-d1eea957]{position:relative;width:100%;height:auto;padding:.625rem;box-sizing:border-box;display:flex;justify-content:space-between;align-items:center}.modal-header .modal-left[data-v-d1eea957]{display:flex;align-items:center;justify-content:center}.modal-header .modal-title[data-v-d1eea957]{display:flex;align-items:center;justify-content:center;position:absolute;width:100%;height:auto;left:50%;transform:translate(-50%)}.modal-header .modal-title .title-text[data-v-d1eea957]{font-size:16px;font-weight:500}.modal-header .modal-right[data-v-d1eea957]{display:flex;align-items:center;justify-content:center;size:1.25rem}.modal-header .modal-right .save-btn[data-v-d1eea957]{background-color:#3b82f6;color:#fff;padding:.25rem .625rem;box-sizing:border-box;border-radius:.3125rem}.modal-body[data-v-d1eea957]{width:100%;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:1.5625rem;box-sizing:border-box}.modal-body .avatar-upload-section[data-v-d1eea957]{display:flex;justify-content:center;align-items:center;flex-direction:column;margin-bottom:.3125rem;box-sizing:border-box}.modal-body .avatar-upload-section .avatar-upload-container[data-v-d1eea957]{width:6.25rem;height:6.25rem;border-radius:50%;padding:.15625rem;margin-top:.625rem;background:#f3f4f6;display:flex;justify-content:center;align-items:center;border:.15625rem solid #dddddd;box-sizing:border-box}.modal-body .avatar-upload-section .avatar-upload-container .avatar-preview[data-v-d1eea957]{display:flex;justify-content:center;align-items:center;width:100%;height:100%;border-radius:50%;overflow:hidden}.modal-body .avatar-upload-section .avatar-upload-container .avatar-preview uni-image[data-v-d1eea957]{width:100%;height:100%;object-fit:cover}.modal-body .avatar-upload-section .avatar-upload-container .avatar-placeholder[data-v-d1eea957]{display:flex;justify-content:center;align-items:center;padding:.3125rem;box-sizing:border-box;border-radius:50%;background:#9ca3af}.modal-body .form-card[data-v-d1eea957]{width:100%;padding:.625rem;background:#fff;box-sizing:border-box;border-radius:.625rem;margin:.625rem 0}.modal-body .form-field[data-v-d1eea957]{display:flex;justify-content:center;align-items:flex-start;flex-direction:column;margin:.625rem 0;width:100%}.modal-body .form-field .form-text[data-v-d1eea957]{font-size:15px;font-weight:300}.modal-body .form-field .form-field-input[data-v-d1eea957]{width:100%;height:2.5rem}.modal-body .form-field .edit-input-focus[data-v-d1eea957]{background:rgba(170,255,255,.1)}.modal-body .prompt-content[data-v-d1eea957]{width:100%;font-size:10px;color:#9ca3af} +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.user-profile[data-v-8fad524d]{display:flex;flex-direction:column;align-items:center;background-color:rgba(193,193,193,.1)}.modal-header[data-v-8fad524d]{position:relative;width:100%;height:auto;padding:.625rem;box-sizing:border-box;display:flex;justify-content:space-between;align-items:center}.modal-header .modal-left[data-v-8fad524d]{display:flex;align-items:center;justify-content:center;z-index:2}.modal-header .modal-title[data-v-8fad524d]{display:flex;align-items:center;justify-content:center;position:absolute;width:100%;height:auto;left:50%;transform:translate(-50%)}.modal-header .modal-title .title-text[data-v-8fad524d]{font-size:16px;font-weight:500}.modal-header .modal-right[data-v-8fad524d]{display:flex;align-items:center;justify-content:center;size:1.25rem;z-index:2}.modal-header .modal-right .save-btn[data-v-8fad524d]{background-color:#3b82f6;color:#fff;padding:.25rem .625rem;box-sizing:border-box;border-radius:.3125rem}.modal-body[data-v-8fad524d]{width:100%;height:auto;display:flex;flex-direction:column;justify-content:center;align-items:center;padding:1.5625rem;box-sizing:border-box}.modal-body .avatar-upload-section[data-v-8fad524d]{display:flex;justify-content:center;align-items:center;flex-direction:column;margin-bottom:.3125rem;box-sizing:border-box}.modal-body .avatar-upload-section .avatar-upload-container[data-v-8fad524d]{width:6.25rem;height:6.25rem;border-radius:50%;padding:.15625rem;margin-top:.625rem;background:#f3f4f6;display:flex;justify-content:center;align-items:center;border:.15625rem solid #dddddd;box-sizing:border-box}.modal-body .avatar-upload-section .avatar-upload-container .avatar-preview[data-v-8fad524d]{display:flex;justify-content:center;align-items:center;width:100%;height:100%;border-radius:50%;overflow:hidden}.modal-body .avatar-upload-section .avatar-upload-container .avatar-preview uni-image[data-v-8fad524d]{width:100%;height:100%;object-fit:cover}.modal-body .avatar-upload-section .avatar-upload-container .avatar-placeholder[data-v-8fad524d]{display:flex;justify-content:center;align-items:center;padding:.3125rem;box-sizing:border-box;border-radius:50%;background:#9ca3af}.modal-body .form-card[data-v-8fad524d]{width:100%;padding:.625rem;background:#fff;box-sizing:border-box;border-radius:.625rem;margin:.625rem 0}.modal-body .form-field[data-v-8fad524d]{display:flex;justify-content:center;align-items:flex-start;flex-direction:column;margin:.625rem 0;width:100%}.modal-body .form-field .form-text[data-v-8fad524d]{font-size:15px;font-weight:300}.modal-body .form-field .form-field-input[data-v-8fad524d]{width:100%;height:2.5rem}.modal-body .form-field .edit-input-focus[data-v-8fad524d]{background:rgba(170,255,255,.1)}.modal-body .prompt-content[data-v-8fad524d]{width:100%;font-size:10px;color:#9ca3af} diff --git a/unpackage/dist/build/app-plus/pages/WorkSpace/TemplateSpace/TemplateSpace.css b/unpackage/dist/build/app-plus/pages/WorkSpace/TemplateSpace/TemplateSpace.css index cadb516..dfd706b 100644 --- a/unpackage/dist/build/app-plus/pages/WorkSpace/TemplateSpace/TemplateSpace.css +++ b/unpackage/dist/build/app-plus/pages/WorkSpace/TemplateSpace/TemplateSpace.css @@ -1 +1 @@ -.workspace-container[data-v-2acd55d4]{display:flex;flex-direction:column;background:rgba(140,140,140,.1)}.workspace-text[data-v-2acd55d4]{color:#0073ff;font-weight:700}.workspace-header[data-v-2acd55d4]{width:100%;display:flex;flex-shrink:0;flex-direction:column;align-items:center;padding:.5rem 0;box-sizing:border-box;border-bottom:.03125rem solid #ddd}.custom-navbar[data-v-2acd55d4]{width:100%;display:flex;align-items:center;justify-content:space-between;padding:.625rem .3125rem;box-sizing:border-box;position:relative}.navbar-left[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center}.navbar-before-title[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center;text-align:center}.navbar-title[data-v-2acd55d4]{display:flex;flex:1;justify-content:center;align-items:center;position:absolute;left:50%;transform:translate(-50%)}.navbar-right[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center;margin-right:.625rem;box-sizing:border-box}.navbar-right .menu-open[data-v-2acd55d4]{color:#3ab0ff!important;font-size:1.25rem!important}.custom-navbar-icon[data-v-2acd55d4]{color:#0073ff!important;font-size:1.25rem!important}.search-file-warpper[data-v-2acd55d4]{display:flex;width:90%;align-items:center}.search-file[data-v-2acd55d4]{display:flex;flex:1;align-items:center;background:#fff;padding:.5rem;box-sizing:border-box;border-radius:.9375rem}.icon-sousuo[data-v-2acd55d4]{font-weight:700}.search-file-input[data-v-2acd55d4]{margin-left:.625rem}.cancel-search[data-v-2acd55d4]{display:flex;flex-shrink:0;padding:0 0 0 .625rem;box-sizing:border-box;color:#0073ff}.workspace-content[data-v-2acd55d4]{width:100%;display:block;flex:1;overflow:auto;box-sizing:border-box;position:relative}.menu-card[data-v-2acd55d4]{position:absolute;top:100%;right:.625rem;width:9.375rem;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#fff;border-radius:.9375rem;z-index:1}.menu-card-item[data-v-2acd55d4]{width:100%;padding:.625rem;box-sizing:border-box}.folder-null[data-v-2acd55d4]{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;position:absolute;left:50%;top:30%;transform:translate(-50%);font-size:1rem}.folder-null .iconfont[data-v-2acd55d4]{font-size:5.625rem}.folder-grid[data-v-2acd55d4]{width:100%;display:grid;grid-template-columns:repeat(3,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.folder-item[data-v-2acd55d4]{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative}.folder-item.select-folder[data-v-2acd55d4]{border-radius:.9375rem;background:rgba(9,9,9,.1)}.folder-item-style[data-v-2acd55d4]{font-size:5rem!important;font-weight:.3125rem!important;color:#3ab0ff!important}.folder-checkbox[data-v-2acd55d4]{width:1.5625rem;height:1.5625rem;border:.1875rem solid #fff;border-radius:50%;box-shadow:0 .0625rem .09375rem #333;background:rgba(255,255,255,.2);box-sizing:border-box;position:absolute;left:50%;top:30%;transform:translate(-50%);display:flex;justify-content:center;align-items:center}.folder-checkbox.select-folder[data-v-2acd55d4]{background-color:#0073ff}.workspace-footer[data-v-2acd55d4]{width:100%;display:flex;flex-shrink:0;justify-content:space-between;padding:.9375rem;box-sizing:border-box;color:#999;background:#eee}.workspace-footer.folder-actions[data-v-2acd55d4]{color:#0073ff}.workspace-footer .iconfont[data-v-2acd55d4]{font-size:1.25rem!important}.template-grid[data-v-2acd55d4]{width:100%;display:grid;grid-template-columns:repeat(2,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.template-card[data-v-2acd55d4]{display:flex;flex-direction:column;box-sizing:border-box;border-radius:.625rem;border:.03125rem solid #ddd;box-shadow:0 .0625rem .375rem rgba(0,0,0,.05);overflow:hidden;background-color:#fff}.template-name[data-v-2acd55d4]{width:100%;background:linear-gradient(to right,rgba(0,122,255,.8),rgba(170,170,255,.8));color:#fff;font-weight:700;font-size:18px;padding:.3125rem .625rem;box-sizing:border-box}.template-content[data-v-2acd55d4]{display:flex;flex-wrap:wrap;min-height:6.25rem;padding:.5625rem;margin:.1875rem .1875rem 0;box-sizing:border-box;border:1px solid #eee;border-radius:.625rem;box-shadow:.0625rem .15625rem .25rem rgba(170,170,255,.3);overflow:hidden}.template-content-text[data-v-2acd55d4]{width:100%;color:#666;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all;line-height:1.4}.template-info-wrapper[data-v-2acd55d4]{padding:0 .5rem}.template-item[data-v-2acd55d4]{display:flex;flex-direction:column;color:#007aff;font-size:12px}.template-item .background-style[data-v-2acd55d4]{display:flex;box-sizing:border-box;border-radius:.3125rem;align-self:flex-start;margin-top:.1875rem}.template-option[data-v-2acd55d4]{display:flex;justify-content:space-between;align-items:center;margin:.3125rem}.template-option .iconfont[data-v-2acd55d4]{color:#007aff}.iconfont.icon-favorite-fill[data-v-2acd55d4]{color:#fa0} +.create-folder-name[data-v-2acd55d4]{display:flex;width:100%;padding:.3125rem .625rem;box-sizing:border-box;align-items:center;background-color:rgba(194,191,211,.1);border-radius:.3125rem}.create-folder-name uni-input[data-v-2acd55d4]{box-sizing:border-box;width:100%}.create-folder-name.has-value[data-v-2acd55d4]{background-color:#fff;border:.0625rem solid #aaaaff;box-shadow:0 0 .46875rem #aaf}.new-folder-name[data-v-2acd55d4]{font-size:.875rem;color:#666;margin-bottom:.375rem}.nf-path-label[data-v-2acd55d4]{font-size:.8125rem;color:#999;margin-top:.75rem;margin-bottom:.25rem}.nf-path-display[data-v-2acd55d4]{font-size:.875rem;color:#333;padding:.375rem .625rem;background:#f5f5f5;border-radius:.3125rem;word-break:break-all}.nf-path-preview[data-v-2acd55d4]{font-size:.875rem;color:#0073ff;padding:.375rem .625rem;background:rgba(0,115,255,.05);border:.0625rem dashed rgba(0,115,255,.3);border-radius:.3125rem;word-break:break-all}.option-wrapper[data-v-2acd55d4]{display:flex;justify-content:space-between;gap:.625rem;margin-top:1.25rem}.opt-btn[data-v-2acd55d4]{flex:1;display:flex;justify-content:center;align-items:center;padding:.75rem 0;border-radius:.375rem;font-size:.9375rem}.opt-cancel[data-v-2acd55d4]{background:#f5f5f5;color:#666}.opt-confirm[data-v-2acd55d4]{background:linear-gradient(135deg,#0073ff,#3ab0ff);color:#fff}.workspace-container[data-v-2acd55d4]{display:flex;flex-direction:column;background:rgba(140,140,140,.1)}.workspace-text[data-v-2acd55d4]{color:#0073ff;font-weight:700}.workspace-header[data-v-2acd55d4]{width:100%;display:flex;flex-shrink:0;flex-direction:column;align-items:center;padding:.5rem 0;box-sizing:border-box;border-bottom:.03125rem solid #ddd}.custom-navbar[data-v-2acd55d4]{width:100%;display:flex;align-items:center;justify-content:space-between;padding:.625rem .3125rem;box-sizing:border-box;position:relative}.navbar-left[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center}.navbar-before-title[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center;text-align:center}.navbar-title[data-v-2acd55d4]{display:flex;flex:1;justify-content:center;align-items:center;position:absolute;left:50%;transform:translate(-50%)}.navbar-right[data-v-2acd55d4]{display:flex;justify-content:center;align-items:center;margin-right:.625rem;box-sizing:border-box}.navbar-right .menu-open[data-v-2acd55d4]{color:#3ab0ff!important;font-size:1.25rem!important}.custom-navbar-icon[data-v-2acd55d4]{color:#0073ff!important;font-size:1.25rem!important}.search-file-warpper[data-v-2acd55d4]{display:flex;width:90%;align-items:center}.search-file[data-v-2acd55d4]{display:flex;flex:1;align-items:center;background:#fff;padding:.5rem;box-sizing:border-box;border-radius:.9375rem}.icon-sousuo[data-v-2acd55d4]{font-weight:700}.search-file-input[data-v-2acd55d4]{margin-left:.625rem}.cancel-search[data-v-2acd55d4]{display:flex;flex-shrink:0;padding:0 0 0 .625rem;box-sizing:border-box;color:#0073ff}.workspace-content[data-v-2acd55d4]{width:100%;display:block;flex:1;overflow:auto;box-sizing:border-box;position:relative}.menu-card[data-v-2acd55d4]{position:absolute;top:100%;right:.625rem;width:9.375rem;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#fff;border-radius:.9375rem;z-index:1}.menu-card-item[data-v-2acd55d4]{width:100%;padding:.625rem;box-sizing:border-box}.folder-null[data-v-2acd55d4]{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;position:absolute;left:50%;top:30%;transform:translate(-50%);font-size:1rem}.folder-null .iconfont[data-v-2acd55d4]{font-size:5.625rem}.folder-grid[data-v-2acd55d4]{width:100%;display:grid;grid-template-columns:repeat(3,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.folder-item[data-v-2acd55d4]{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;min-width:0}.folder-item.select-folder[data-v-2acd55d4]{border-radius:.9375rem;background:rgba(9,9,9,.1)}.folder-item .folder-name[data-v-2acd55d4]{max-width:4.6875rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:inline-block;text-align:center;line-height:1.25rem;min-width:0}.folder-item-style[data-v-2acd55d4]{font-size:5rem!important;font-weight:.3125rem!important;color:#3ab0ff!important}.folder-checkbox[data-v-2acd55d4]{width:1.5625rem;height:1.5625rem;border:.1875rem solid #fff;border-radius:50%;box-shadow:0 .0625rem .09375rem #333;background:rgba(255,255,255,.2);box-sizing:border-box;position:absolute;left:50%;top:30%;transform:translate(-50%);display:flex;justify-content:center;align-items:center}.folder-checkbox.select-folder[data-v-2acd55d4]{background-color:#0073ff}.workspace-footer[data-v-2acd55d4]{width:100%;display:flex;flex-shrink:0;justify-content:space-between;padding:.9375rem;box-sizing:border-box;color:#999;background:#eee}.workspace-footer.folder-actions[data-v-2acd55d4]{color:#0073ff}.workspace-footer .iconfont[data-v-2acd55d4]{font-size:1.25rem!important}.template-grid[data-v-2acd55d4]{width:100%;display:grid;grid-template-columns:repeat(2,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.template-card[data-v-2acd55d4]{display:flex;flex-direction:column;box-sizing:border-box;border-radius:.625rem;border:.03125rem solid #ddd;box-shadow:0 .0625rem .375rem rgba(0,0,0,.05);overflow:hidden;background-color:#fff}.template-name[data-v-2acd55d4]{width:100%;background:linear-gradient(to right,rgba(0,122,255,.8),rgba(170,170,255,.8));color:#fff;font-weight:700;font-size:18px;padding:.3125rem .625rem;box-sizing:border-box}.template-content[data-v-2acd55d4]{display:flex;flex-wrap:wrap;min-height:6.25rem;padding:.5625rem;margin:.1875rem .1875rem 0;box-sizing:border-box;border:1px solid #eee;border-radius:.625rem;box-shadow:.0625rem .15625rem .25rem rgba(170,170,255,.3);overflow:hidden}.template-content-text[data-v-2acd55d4]{width:100%;color:#666;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:4;overflow:hidden;text-overflow:ellipsis;white-space:normal;word-break:break-all;line-height:1.4}.template-info-wrapper[data-v-2acd55d4]{padding:0 .5rem}.template-item[data-v-2acd55d4]{display:flex;flex-direction:column;color:#007aff;font-size:12px}.template-item .background-style[data-v-2acd55d4]{display:flex;box-sizing:border-box;border-radius:.3125rem;align-self:flex-start;margin-top:.1875rem}.template-option[data-v-2acd55d4]{display:flex;justify-content:space-between;align-items:center;margin:.3125rem}.template-option .iconfont[data-v-2acd55d4]{color:#007aff}.iconfont.icon-favorite-fill[data-v-2acd55d4]{color:#fa0} diff --git a/unpackage/dist/build/app-plus/pages/WorkSpace/WorkSpace.css b/unpackage/dist/build/app-plus/pages/WorkSpace/WorkSpace.css index 862fcc6..525c5cc 100644 --- a/unpackage/dist/build/app-plus/pages/WorkSpace/WorkSpace.css +++ b/unpackage/dist/build/app-plus/pages/WorkSpace/WorkSpace.css @@ -1 +1 @@ -.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.workspace-container[data-v-ea107472]{display:flex;flex-direction:column;background:rgba(140,140,140,.1)}.workspace-text[data-v-ea107472]{color:#0073ff;font-weight:700}.workspace-header[data-v-ea107472]{width:100%;display:flex;flex-shrink:0;flex-direction:column;align-items:center;padding:.5rem 0;box-sizing:border-box;border-bottom:.03125rem solid #ddd}.custom-navbar[data-v-ea107472]{width:100%;display:flex;align-items:center;justify-content:space-between;padding:.625rem .3125rem;box-sizing:border-box;position:relative}.navbar-left[data-v-ea107472]{display:flex;justify-content:center;align-items:center}.navbar-before-title[data-v-ea107472]{display:flex;justify-content:center;align-items:center;text-align:center}.navbar-title[data-v-ea107472]{display:flex;flex:1;justify-content:center;align-items:center;position:absolute;left:50%;transform:translate(-50%)}.navbar-right[data-v-ea107472]{display:flex;justify-content:center;align-items:center;margin-right:.625rem;box-sizing:border-box}.navbar-right .menu-open[data-v-ea107472]{color:#3ab0ff!important;font-size:1.25rem!important}.custom-navbar-icon[data-v-ea107472]{color:#0073ff!important;font-size:1.25rem!important}.search-file-warpper[data-v-ea107472]{display:flex;width:90%;align-items:center}.search-file[data-v-ea107472]{display:flex;flex:1;align-items:center;background:#fff;padding:.5rem;box-sizing:border-box;border-radius:.9375rem}.icon-sousuo[data-v-ea107472]{font-weight:700}.search-file-input[data-v-ea107472]{margin-left:.625rem}.cancel-search[data-v-ea107472]{display:flex;flex-shrink:0;padding:0 0 0 .625rem;box-sizing:border-box;color:#0073ff}.workspace-content[data-v-ea107472]{width:100%;display:block;flex:1;overflow:auto;box-sizing:border-box;position:relative}.menu-card[data-v-ea107472]{position:absolute;top:100%;right:.625rem;width:9.375rem;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#fff;border-radius:.9375rem;z-index:1}.menu-card-item[data-v-ea107472]{width:100%;padding:.625rem;box-sizing:border-box}.folder-null[data-v-ea107472]{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;position:absolute;left:50%;top:30%;transform:translate(-50%);font-size:1rem}.folder-null .iconfont[data-v-ea107472]{font-size:5.625rem}.folder-grid[data-v-ea107472]{width:100%;display:grid;grid-template-columns:repeat(3,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.folder-item[data-v-ea107472]{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative}.folder-item.select-folder[data-v-ea107472]{border-radius:.9375rem;background:rgba(9,9,9,.1)}.folder-item-style[data-v-ea107472]{font-size:5rem!important;font-weight:.3125rem!important;color:#3ab0ff!important}.folder-checkbox[data-v-ea107472]{width:1.5625rem;height:1.5625rem;border:.1875rem solid #fff;border-radius:50%;box-shadow:0 .0625rem .09375rem #333;background:rgba(255,255,255,.2);box-sizing:border-box;position:absolute;left:50%;top:30%;transform:translate(-50%);display:flex;justify-content:center;align-items:center}.folder-checkbox.select-folder[data-v-ea107472]{background-color:#0073ff}.workspace-footer[data-v-ea107472]{width:100%;display:flex;flex-shrink:0;justify-content:space-between;padding:.9375rem;box-sizing:border-box;color:#999;background:#eee}.workspace-footer.folder-actions[data-v-ea107472]{color:#0073ff}.workspace-footer .iconfont[data-v-ea107472]{font-size:1.25rem!important} +.uniui-cart-filled[data-v-b25a9929]:before{content:"\e6d0"}.uniui-gift-filled[data-v-b25a9929]:before{content:"\e6c4"}.uniui-color[data-v-b25a9929]:before{content:"\e6cf"}.uniui-wallet[data-v-b25a9929]:before{content:"\e6b1"}.uniui-settings-filled[data-v-b25a9929]:before{content:"\e6ce"}.uniui-auth-filled[data-v-b25a9929]:before{content:"\e6cc"}.uniui-shop-filled[data-v-b25a9929]:before{content:"\e6cd"}.uniui-staff-filled[data-v-b25a9929]:before{content:"\e6cb"}.uniui-vip-filled[data-v-b25a9929]:before{content:"\e6c6"}.uniui-plus-filled[data-v-b25a9929]:before{content:"\e6c7"}.uniui-folder-add-filled[data-v-b25a9929]:before{content:"\e6c8"}.uniui-color-filled[data-v-b25a9929]:before{content:"\e6c9"}.uniui-tune-filled[data-v-b25a9929]:before{content:"\e6ca"}.uniui-calendar-filled[data-v-b25a9929]:before{content:"\e6c0"}.uniui-notification-filled[data-v-b25a9929]:before{content:"\e6c1"}.uniui-wallet-filled[data-v-b25a9929]:before{content:"\e6c2"}.uniui-medal-filled[data-v-b25a9929]:before{content:"\e6c3"}.uniui-fire-filled[data-v-b25a9929]:before{content:"\e6c5"}.uniui-refreshempty[data-v-b25a9929]:before{content:"\e6bf"}.uniui-location-filled[data-v-b25a9929]:before{content:"\e6af"}.uniui-person-filled[data-v-b25a9929]:before{content:"\e69d"}.uniui-personadd-filled[data-v-b25a9929]:before{content:"\e698"}.uniui-arrowthinleft[data-v-b25a9929]:before{content:"\e6d2"}.uniui-arrowthinup[data-v-b25a9929]:before{content:"\e6d3"}.uniui-arrowthindown[data-v-b25a9929]:before{content:"\e6d4"}.uniui-back[data-v-b25a9929]:before{content:"\e6b9"}.uniui-forward[data-v-b25a9929]:before{content:"\e6ba"}.uniui-arrow-right[data-v-b25a9929]:before{content:"\e6bb"}.uniui-arrow-left[data-v-b25a9929]:before{content:"\e6bc"}.uniui-arrow-up[data-v-b25a9929]:before{content:"\e6bd"}.uniui-arrow-down[data-v-b25a9929]:before{content:"\e6be"}.uniui-arrowthinright[data-v-b25a9929]:before{content:"\e6d1"}.uniui-down[data-v-b25a9929]:before{content:"\e6b8"}.uniui-bottom[data-v-b25a9929]:before{content:"\e6b8"}.uniui-arrowright[data-v-b25a9929]:before{content:"\e6d5"}.uniui-right[data-v-b25a9929]:before{content:"\e6b5"}.uniui-up[data-v-b25a9929]:before{content:"\e6b6"}.uniui-top[data-v-b25a9929]:before{content:"\e6b6"}.uniui-left[data-v-b25a9929]:before{content:"\e6b7"}.uniui-arrowup[data-v-b25a9929]:before{content:"\e6d6"}.uniui-eye[data-v-b25a9929]:before{content:"\e651"}.uniui-eye-filled[data-v-b25a9929]:before{content:"\e66a"}.uniui-eye-slash[data-v-b25a9929]:before{content:"\e6b3"}.uniui-eye-slash-filled[data-v-b25a9929]:before{content:"\e6b4"}.uniui-info-filled[data-v-b25a9929]:before{content:"\e649"}.uniui-reload[data-v-b25a9929]:before{content:"\e6b2"}.uniui-micoff-filled[data-v-b25a9929]:before{content:"\e6b0"}.uniui-map-pin-ellipse[data-v-b25a9929]:before{content:"\e6ac"}.uniui-map-pin[data-v-b25a9929]:before{content:"\e6ad"}.uniui-location[data-v-b25a9929]:before{content:"\e6ae"}.uniui-starhalf[data-v-b25a9929]:before{content:"\e683"}.uniui-star[data-v-b25a9929]:before{content:"\e688"}.uniui-star-filled[data-v-b25a9929]:before{content:"\e68f"}.uniui-calendar[data-v-b25a9929]:before{content:"\e6a0"}.uniui-fire[data-v-b25a9929]:before{content:"\e6a1"}.uniui-medal[data-v-b25a9929]:before{content:"\e6a2"}.uniui-font[data-v-b25a9929]:before{content:"\e6a3"}.uniui-gift[data-v-b25a9929]:before{content:"\e6a4"}.uniui-link[data-v-b25a9929]:before{content:"\e6a5"}.uniui-notification[data-v-b25a9929]:before{content:"\e6a6"}.uniui-staff[data-v-b25a9929]:before{content:"\e6a7"}.uniui-vip[data-v-b25a9929]:before{content:"\e6a8"}.uniui-folder-add[data-v-b25a9929]:before{content:"\e6a9"}.uniui-tune[data-v-b25a9929]:before{content:"\e6aa"}.uniui-auth[data-v-b25a9929]:before{content:"\e6ab"}.uniui-person[data-v-b25a9929]:before{content:"\e699"}.uniui-email-filled[data-v-b25a9929]:before{content:"\e69a"}.uniui-phone-filled[data-v-b25a9929]:before{content:"\e69b"}.uniui-phone[data-v-b25a9929]:before{content:"\e69c"}.uniui-email[data-v-b25a9929]:before{content:"\e69e"}.uniui-personadd[data-v-b25a9929]:before{content:"\e69f"}.uniui-chatboxes-filled[data-v-b25a9929]:before{content:"\e692"}.uniui-contact[data-v-b25a9929]:before{content:"\e693"}.uniui-chatbubble-filled[data-v-b25a9929]:before{content:"\e694"}.uniui-contact-filled[data-v-b25a9929]:before{content:"\e695"}.uniui-chatboxes[data-v-b25a9929]:before{content:"\e696"}.uniui-chatbubble[data-v-b25a9929]:before{content:"\e697"}.uniui-upload-filled[data-v-b25a9929]:before{content:"\e68e"}.uniui-upload[data-v-b25a9929]:before{content:"\e690"}.uniui-weixin[data-v-b25a9929]:before{content:"\e691"}.uniui-compose[data-v-b25a9929]:before{content:"\e67f"}.uniui-qq[data-v-b25a9929]:before{content:"\e680"}.uniui-download-filled[data-v-b25a9929]:before{content:"\e681"}.uniui-pyq[data-v-b25a9929]:before{content:"\e682"}.uniui-sound[data-v-b25a9929]:before{content:"\e684"}.uniui-trash-filled[data-v-b25a9929]:before{content:"\e685"}.uniui-sound-filled[data-v-b25a9929]:before{content:"\e686"}.uniui-trash[data-v-b25a9929]:before{content:"\e687"}.uniui-videocam-filled[data-v-b25a9929]:before{content:"\e689"}.uniui-spinner-cycle[data-v-b25a9929]:before{content:"\e68a"}.uniui-weibo[data-v-b25a9929]:before{content:"\e68b"}.uniui-videocam[data-v-b25a9929]:before{content:"\e68c"}.uniui-download[data-v-b25a9929]:before{content:"\e68d"}.uniui-help[data-v-b25a9929]:before{content:"\e679"}.uniui-navigate-filled[data-v-b25a9929]:before{content:"\e67a"}.uniui-plusempty[data-v-b25a9929]:before{content:"\e67b"}.uniui-smallcircle[data-v-b25a9929]:before{content:"\e67c"}.uniui-minus-filled[data-v-b25a9929]:before{content:"\e67d"}.uniui-micoff[data-v-b25a9929]:before{content:"\e67e"}.uniui-closeempty[data-v-b25a9929]:before{content:"\e66c"}.uniui-clear[data-v-b25a9929]:before{content:"\e66d"}.uniui-navigate[data-v-b25a9929]:before{content:"\e66e"}.uniui-minus[data-v-b25a9929]:before{content:"\e66f"}.uniui-image[data-v-b25a9929]:before{content:"\e670"}.uniui-mic[data-v-b25a9929]:before{content:"\e671"}.uniui-paperplane[data-v-b25a9929]:before{content:"\e672"}.uniui-close[data-v-b25a9929]:before{content:"\e673"}.uniui-help-filled[data-v-b25a9929]:before{content:"\e674"}.uniui-paperplane-filled[data-v-b25a9929]:before{content:"\e675"}.uniui-plus[data-v-b25a9929]:before{content:"\e676"}.uniui-mic-filled[data-v-b25a9929]:before{content:"\e677"}.uniui-image-filled[data-v-b25a9929]:before{content:"\e678"}.uniui-locked-filled[data-v-b25a9929]:before{content:"\e668"}.uniui-info[data-v-b25a9929]:before{content:"\e669"}.uniui-locked[data-v-b25a9929]:before{content:"\e66b"}.uniui-camera-filled[data-v-b25a9929]:before{content:"\e658"}.uniui-chat-filled[data-v-b25a9929]:before{content:"\e659"}.uniui-camera[data-v-b25a9929]:before{content:"\e65a"}.uniui-circle[data-v-b25a9929]:before{content:"\e65b"}.uniui-checkmarkempty[data-v-b25a9929]:before{content:"\e65c"}.uniui-chat[data-v-b25a9929]:before{content:"\e65d"}.uniui-circle-filled[data-v-b25a9929]:before{content:"\e65e"}.uniui-flag[data-v-b25a9929]:before{content:"\e65f"}.uniui-flag-filled[data-v-b25a9929]:before{content:"\e660"}.uniui-gear-filled[data-v-b25a9929]:before{content:"\e661"}.uniui-home[data-v-b25a9929]:before{content:"\e662"}.uniui-home-filled[data-v-b25a9929]:before{content:"\e663"}.uniui-gear[data-v-b25a9929]:before{content:"\e664"}.uniui-smallcircle-filled[data-v-b25a9929]:before{content:"\e665"}.uniui-map-filled[data-v-b25a9929]:before{content:"\e666"}.uniui-map[data-v-b25a9929]:before{content:"\e667"}.uniui-refresh-filled[data-v-b25a9929]:before{content:"\e656"}.uniui-refresh[data-v-b25a9929]:before{content:"\e657"}.uniui-cloud-upload[data-v-b25a9929]:before{content:"\e645"}.uniui-cloud-download-filled[data-v-b25a9929]:before{content:"\e646"}.uniui-cloud-download[data-v-b25a9929]:before{content:"\e647"}.uniui-cloud-upload-filled[data-v-b25a9929]:before{content:"\e648"}.uniui-redo[data-v-b25a9929]:before{content:"\e64a"}.uniui-images-filled[data-v-b25a9929]:before{content:"\e64b"}.uniui-undo-filled[data-v-b25a9929]:before{content:"\e64c"}.uniui-more[data-v-b25a9929]:before{content:"\e64d"}.uniui-more-filled[data-v-b25a9929]:before{content:"\e64e"}.uniui-undo[data-v-b25a9929]:before{content:"\e64f"}.uniui-images[data-v-b25a9929]:before{content:"\e650"}.uniui-paperclip[data-v-b25a9929]:before{content:"\e652"}.uniui-settings[data-v-b25a9929]:before{content:"\e653"}.uniui-search[data-v-b25a9929]:before{content:"\e654"}.uniui-redo-filled[data-v-b25a9929]:before{content:"\e655"}.uniui-list[data-v-b25a9929]:before{content:"\e644"}.uniui-mail-open-filled[data-v-b25a9929]:before{content:"\e63a"}.uniui-hand-down-filled[data-v-b25a9929]:before{content:"\e63c"}.uniui-hand-down[data-v-b25a9929]:before{content:"\e63d"}.uniui-hand-up-filled[data-v-b25a9929]:before{content:"\e63e"}.uniui-hand-up[data-v-b25a9929]:before{content:"\e63f"}.uniui-heart-filled[data-v-b25a9929]:before{content:"\e641"}.uniui-mail-open[data-v-b25a9929]:before{content:"\e643"}.uniui-heart[data-v-b25a9929]:before{content:"\e639"}.uniui-loop[data-v-b25a9929]:before{content:"\e633"}.uniui-pulldown[data-v-b25a9929]:before{content:"\e632"}.uniui-scan[data-v-b25a9929]:before{content:"\e62a"}.uniui-bars[data-v-b25a9929]:before{content:"\e627"}.uniui-checkbox[data-v-b25a9929]:before{content:"\e62b"}.uniui-checkbox-filled[data-v-b25a9929]:before{content:"\e62c"}.uniui-shop[data-v-b25a9929]:before{content:"\e62f"}.uniui-headphones[data-v-b25a9929]:before{content:"\e630"}.uniui-cart[data-v-b25a9929]:before{content:"\e631"}@font-face{font-family:uniicons;src:url(../../assets/uniicons.32e978a5.ttf)}.uni-icons[data-v-b25a9929]{font-family:uniicons;text-decoration:none;text-align:center}.create-folder-name[data-v-02673744]{display:flex;width:100%;padding:.3125rem .625rem;box-sizing:border-box;align-items:center;background-color:rgba(194,191,211,.1);border-radius:.3125rem}.create-folder-name uni-input[data-v-02673744]{box-sizing:border-box;width:100%}.create-folder-name.has-value[data-v-02673744]{background-color:#fff;border:.0625rem solid #aaaaff;box-shadow:0 0 .46875rem #aaf}.new-folder-name[data-v-02673744]{font-size:.875rem;color:#666;margin-bottom:.375rem}.nf-path-label[data-v-02673744]{font-size:.8125rem;color:#999;margin-top:.75rem;margin-bottom:.25rem}.nf-path-display[data-v-02673744]{font-size:.875rem;color:#333;padding:.375rem .625rem;background:#f5f5f5;border-radius:.3125rem;word-break:break-all}.nf-path-preview[data-v-02673744]{font-size:.875rem;color:#0073ff;padding:.375rem .625rem;background:rgba(0,115,255,.05);border:.0625rem dashed rgba(0,115,255,.3);border-radius:.3125rem;word-break:break-all}.option-wrapper[data-v-02673744]{display:flex;justify-content:space-between;gap:.625rem;margin-top:1.25rem}.opt-btn[data-v-02673744]{flex:1;display:flex;justify-content:center;align-items:center;padding:.75rem 0;border-radius:.375rem;font-size:.9375rem}.opt-cancel[data-v-02673744]{background:#f5f5f5;color:#666}.opt-confirm[data-v-02673744]{background:linear-gradient(135deg,#0073ff,#3ab0ff);color:#fff}.workspace-container[data-v-02673744]{display:flex;flex-direction:column;background:rgba(140,140,140,.1)}.workspace-text[data-v-02673744]{color:#0073ff;font-weight:700}.workspace-header[data-v-02673744]{width:100%;display:flex;flex-shrink:0;flex-direction:column;align-items:center;padding:.5rem 0;box-sizing:border-box;border-bottom:.03125rem solid #ddd}.custom-navbar[data-v-02673744]{width:100%;display:flex;align-items:center;justify-content:space-between;padding:.625rem .3125rem;box-sizing:border-box;position:relative}.navbar-left[data-v-02673744]{display:flex;justify-content:center;align-items:center}.navbar-before-title[data-v-02673744]{display:flex;justify-content:center;align-items:center;text-align:center}.navbar-title[data-v-02673744]{display:flex;flex:1;justify-content:center;align-items:center;position:absolute;left:50%;transform:translate(-50%)}.navbar-right[data-v-02673744]{display:flex;justify-content:center;align-items:center;margin-right:.625rem;box-sizing:border-box}.navbar-right .menu-open[data-v-02673744]{color:#3ab0ff!important;font-size:1.25rem!important}.custom-navbar-icon[data-v-02673744]{color:#0073ff!important;font-size:1.25rem!important}.search-file-warpper[data-v-02673744]{display:flex;width:90%;align-items:center}.search-file[data-v-02673744]{display:flex;flex:1;align-items:center;background:#fff;padding:.5rem;box-sizing:border-box;border-radius:.9375rem}.icon-sousuo[data-v-02673744]{font-weight:700}.search-file-input[data-v-02673744]{margin-left:.625rem}.cancel-search[data-v-02673744]{display:flex;flex-shrink:0;padding:0 0 0 .625rem;box-sizing:border-box;color:#0073ff}.workspace-content[data-v-02673744]{width:100%;display:block;flex:1;overflow:auto;box-sizing:border-box;position:relative}.menu-card[data-v-02673744]{position:absolute;top:100%;right:.625rem;width:9.375rem;display:flex;flex-direction:column;justify-content:center;align-items:center;background:#fff;border-radius:.9375rem;z-index:1}.menu-card-item[data-v-02673744]{width:100%;padding:.625rem;box-sizing:border-box}.folder-null[data-v-02673744]{width:100%;display:flex;justify-content:center;align-items:center;flex-direction:column;position:absolute;left:50%;top:30%;transform:translate(-50%);font-size:1rem}.folder-null .iconfont[data-v-02673744]{font-size:5.625rem}.folder-grid[data-v-02673744]{width:100%;display:grid;grid-template-columns:repeat(3,1fr);padding:.625rem;box-sizing:border-box;gap:.625rem;align-items:start}.folder-item[data-v-02673744]{display:flex;flex-direction:column;justify-content:center;align-items:center;position:relative;min-width:0}.folder-item.select-folder[data-v-02673744]{border-radius:.9375rem;background:rgba(9,9,9,.1)}.folder-item .folder-name[data-v-02673744]{max-width:4.6875rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:inline-block;text-align:center;line-height:1.25rem;min-width:0}.folder-item-style[data-v-02673744]{font-size:5rem!important;font-weight:.3125rem!important;color:#3ab0ff!important}.folder-checkbox[data-v-02673744]{width:1.5625rem;height:1.5625rem;border:.1875rem solid #fff;border-radius:50%;box-shadow:0 .0625rem .09375rem #333;background:rgba(255,255,255,.2);box-sizing:border-box;position:absolute;left:50%;top:30%;transform:translate(-50%);display:flex;justify-content:center;align-items:center}.folder-checkbox.select-folder[data-v-02673744]{background-color:#0073ff}.workspace-footer[data-v-02673744]{width:100%;display:flex;flex-shrink:0;justify-content:space-between;padding:.9375rem;box-sizing:border-box;color:#999;background:#eee}.workspace-footer.folder-actions[data-v-02673744]{color:#0073ff}.workspace-footer .iconfont[data-v-02673744]{font-size:1.25rem!important} diff --git a/unpackage/dist/build/app-plus/static/iconfont/demo_index.html b/unpackage/dist/build/app-plus/static/iconfont/demo_index.html index 1d50130..3bfb318 100644 --- a/unpackage/dist/build/app-plus/static/iconfont/demo_index.html +++ b/unpackage/dist/build/app-plus/static/iconfont/demo_index.html @@ -47,11 +47,277 @@
  • Symbol
  • +
    查看项目 +
      +
    • + +
      云端,云,云服务
      +
      &#xe988;
      +
    • + +
    • + +
      其他文件
      +
      &#xe7b6;
      +
    • + +
    • + +
      文件-压缩
      +
      &#xe643;
      +
    • + +
    • + +
      文件-视频
      +
      &#xe644;
      +
    • + +
    • + +
      文件-音频
      +
      &#xe645;
      +
    • + +
    • + +
      文件-图片
      +
      &#xe646;
      +
    • + +
    • + +
      代码文件
      +
      &#xe66a;
      +
    • + +
    • + +
      markdown文件
      +
      &#xebb1;
      +
    • + +
    • + +
      SVG
      +
      &#xe614;
      +
    • + +
    • + +
      HTML
      +
      &#xe615;
      +
    • + +
    • + +
      CSS
      +
      &#xe618;
      +
    • + +
    • + +
      CSV
      +
      &#xe619;
      +
    • + +
    • + +
      JSON
      +
      &#xe61b;
      +
    • + +
    • + +
      JS
      +
      &#xe61c;
      +
    • + +
    • + +
      PDF
      +
      &#xe61e;
      +
    • + +
    • + +
      PHP
      +
      &#xe621;
      +
    • + +
    • + +
      TXT
      +
      &#xe622;
      +
    • + +
    • + +
      XLS
      +
      &#xe623;
      +
    • + +
    • + +
      DOC
      +
      &#xe624;
      +
    • + +
    • + +
      PPT
      +
      &#xe626;
      +
    • + +
    • + +
      SQL
      +
      &#xe627;
      +
    • + +
    • + +
      编辑
      +
      &#xe605;
      +
    • + +
    • + +
      发送
      +
      &#xe705;
      +
    • + +
    • + +
      下载
      +
      &#xe61a;
      +
    • + +
    • + +
      编辑
      +
      &#xe61d;
      +
    • + +
    • + +
      收藏
      +
      &#xe61f;
      +
    • + +
    • + +
      收藏
      +
      &#xe620;
      +
    • + +
    • + +
      上传
      +
      &#xe63e;
      +
    • + +
    • + +
      用户资料
      +
      &#xe6a1;
      +
    • + +
    • + +
      +
      &#xe67c;
      +
    • + +
    • + +
      群聊
      +
      &#xe606;
      +
    • + +
    • + +
      视频通话
      +
      &#xe609;
      +
    • + +
    • + +
      添加
      +
      &#xe60d;
      +
    • + +
    • + +
      通讯录
      +
      &#xe612;
      +
    • + +
    • + +
      添加好友
      +
      &#xe613;
      +
    • + +
    • + +
      删除
      +
      &#xe6d3;
      +
    • + +
    • + +
      选择箭头-fill
      +
      &#xe6a2;
      +
    • + +
    • + +
      文件夹,文件
      +
      &#xe69e;
      +
    • + +
    • + +
      搜索
      +
      &#xe6eb;
      +
    • + +
    • + +
      Robot
      +
      &#xe67d;
      +
    • + +
    • + +
      扫除
      +
      &#xe6a3;
      +
    • + +
    • + +
      返回
      +
      &#xe765;
      +
    • + +
    • + +
      brain-2-fill
      +
      &#xe800;
      +
    • + +
    • + +
      更多
      +
      &#xe6c5;
      +
    • +
    • 垃圾桶
      @@ -137,141 +403,9 @@
    • - -
      编辑
      -
      &#xe605;
      -
    • - -
    • - -
      发送
      -
      &#xe705;
      -
    • - -
    • - -
      下载
      -
      &#xe61a;
      -
    • - -
    • - -
      编辑
      -
      &#xe61d;
      -
    • - -
    • - -
      收藏
      -
      &#xe61f;
      -
    • - -
    • - -
      收藏
      -
      &#xe620;
      -
    • - -
    • - -
      上传
      -
      &#xe63e;
      -
    • - -
    • - -
      用户资料
      -
      &#xe6a1;
      -
    • - -
    • - -
      -
      &#xe667;
      -
    • - -
    • - -
      群聊
      -
      &#xe606;
      -
    • - -
    • - -
      视频通话
      -
      &#xe609;
      -
    • - -
    • - -
      添加
      -
      &#xe60d;
      -
    • - -
    • - -
      通讯录
      -
      &#xe612;
      -
    • - -
    • - -
      添加好友
      -
      &#xe613;
      -
    • - -
    • - -
      删除
      -
      &#xe6d3;
      -
    • - -
    • - -
      选择箭头-fill
      -
      &#xe6a2;
      -
    • - -
    • - -
      文件夹,文件
      -
      &#xe69e;
      -
    • - -
    • - -
      搜索
      -
      &#xe6eb;
      -
    • - -
    • - -
      Robot
      -
      &#xe661;
      -
    • - -
    • - -
      扫除
      -
      &#xe6a3;
      -
    • - -
    • - -
      返回
      -
      &#xe765;
      -
    • - -
    • - -
      brain-2-fill
      -
      &#xe800;
      -
    • - -
    • - -
      更多
      -
      &#xe6c5;
      + +
      其它
      +
      &#xe600;
    @@ -292,7 +426,9 @@
    @font-face {
       font-family: 'iconfont';
    -  src: url('iconfont.ttf?t=1776936195904') format('truetype');
    +  src: url('iconfont.woff2?t=1782200893170') format('woff2'),
    +       url('iconfont.woff?t=1782200893170') format('woff'),
    +       url('iconfont.ttf?t=1782200893170') format('truetype');
     }
     

    第二步:定义使用 iconfont 的样式

    @@ -319,128 +455,191 @@
    • - +
      - 垃圾桶 + 云端,云,云服务
      -
      .icon-del +
      .icon-cloud
    • - +
      - 照相机 + 其他文件
      -
      .icon-zhaoxiangji +
      .icon-qitawenjian
    • - +
      - 多选 + 文件-压缩
      -
      .icon-duoxuan +
      .icon-wenjianyasuo
    • - +
      - 加 + 文件-视频
      -
      .icon-jia +
      .icon-wenjianshipin
    • - +
      - 取消 + 文件-音频
      -
      .icon-quxiao +
      .icon-wenjianyinpin
    • - +
      - 退出 + 文件-图片
      -
      .icon-tuichu +
      .icon-wenjiantupian
    • - +
      - 复制 + 代码文件
      -
      .icon-fuzhi +
      .icon-daimawenjian
    • - +
      - 上传 + markdown文件
      -
      .icon-shangchuan +
      .icon-file-markdown-fill
    • - +
      - 全选 + SVG
      -
      .icon-total_selection +
      .icon-SVG
    • - +
      - 停止 + HTML
      -
      .icon-tingzhi +
      .icon-HTML
    • - +
      - 文件夹 + CSS
      -
      .icon-wenjianjia +
      .icon-CSS
    • - +
      - 菜单 + CSV
      -
      .icon-caidan +
      .icon-CSV
    • - +
      - 文件 + JSON
      -
      .icon-wenjian +
      .icon-JSON
    • - +
      - 别针 + JS
      -
      .icon-biezhen +
      .icon-JS +
      +
    • + +
    • + +
      + PDF +
      +
      .icon-PDF +
      +
    • + +
    • + +
      + PHP +
      +
      .icon-PHP +
      +
    • + +
    • + +
      + TXT +
      +
      .icon-TXT +
      +
    • + +
    • + +
      + XLS +
      +
      .icon-XLS +
      +
    • + +
    • + +
      + DOC +
      +
      .icon-DOC +
      +
    • + +
    • + +
      + PPT +
      +
      .icon-PPT +
      +
    • + +
    • + +
      + SQL +
      +
      .icon-SQL
    • @@ -651,6 +850,141 @@
    +
  • + +
    + 垃圾桶 +
    +
    .icon-del +
    +
  • + +
  • + +
    + 照相机 +
    +
    .icon-zhaoxiangji +
    +
  • + +
  • + +
    + 多选 +
    +
    .icon-duoxuan +
    +
  • + +
  • + +
    + 加 +
    +
    .icon-jia +
    +
  • + +
  • + +
    + 取消 +
    +
    .icon-quxiao +
    +
  • + +
  • + +
    + 退出 +
    +
    .icon-tuichu +
    +
  • + +
  • + +
    + 复制 +
    +
    .icon-fuzhi +
    +
  • + +
  • + +
    + 上传 +
    +
    .icon-shangchuan +
    +
  • + +
  • + +
    + 全选 +
    +
    .icon-total_selection +
    +
  • + +
  • + +
    + 停止 +
    +
    .icon-tingzhi +
    +
  • + +
  • + +
    + 文件夹 +
    +
    .icon-wenjianjia +
    +
  • + +
  • + +
    + 菜单 +
    +
    .icon-caidan +
    +
  • + +
  • + +
    + 文件 +
    +
    .icon-wenjian +
    +
  • + +
  • + +
    + 别针 +
    +
    .icon-biezhen +
    +
  • + +
  • + +
    + 其它 +
    +
    .icon-qita +
    +
  • +

    font-class 引用

    @@ -680,114 +1014,170 @@
  • -
    垃圾桶
    -
    #icon-del
    +
    云端,云,云服务
    +
    #icon-cloud
  • -
    照相机
    -
    #icon-zhaoxiangji
    +
    其他文件
    +
    #icon-qitawenjian
  • -
    多选
    -
    #icon-duoxuan
    +
    文件-压缩
    +
    #icon-wenjianyasuo
  • -
    -
    #icon-jia
    +
    文件-视频
    +
    #icon-wenjianshipin
  • -
    取消
    -
    #icon-quxiao
    +
    文件-音频
    +
    #icon-wenjianyinpin
  • -
    退出
    -
    #icon-tuichu
    +
    文件-图片
    +
    #icon-wenjiantupian
  • -
    复制
    -
    #icon-fuzhi
    +
    代码文件
    +
    #icon-daimawenjian
  • -
    上传
    -
    #icon-shangchuan
    +
    markdown文件
    +
    #icon-file-markdown-fill
  • -
    全选
    -
    #icon-total_selection
    +
    SVG
    +
    #icon-SVG
  • -
    停止
    -
    #icon-tingzhi
    +
    HTML
    +
    #icon-HTML
  • -
    文件夹
    -
    #icon-wenjianjia
    +
    CSS
    +
    #icon-CSS
  • -
    菜单
    -
    #icon-caidan
    +
    CSV
    +
    #icon-CSV
  • -
    文件
    -
    #icon-wenjian
    +
    JSON
    +
    #icon-JSON
  • -
    别针
    -
    #icon-biezhen
    +
    JS
    +
    #icon-JS
    +
  • + +
  • + +
    PDF
    +
    #icon-PDF
    +
  • + +
  • + +
    PHP
    +
    #icon-PHP
    +
  • + +
  • + +
    TXT
    +
    #icon-TXT
    +
  • + +
  • + +
    XLS
    +
    #icon-XLS
    +
  • + +
  • + +
    DOC
    +
    #icon-DOC
    +
  • + +
  • + +
    PPT
    +
    #icon-PPT
    +
  • + +
  • + +
    SQL
    +
    #icon-SQL
  • @@ -974,6 +1364,126 @@
    #icon-gengduo
  • +
  • + +
    垃圾桶
    +
    #icon-del
    +
  • + +
  • + +
    照相机
    +
    #icon-zhaoxiangji
    +
  • + +
  • + +
    多选
    +
    #icon-duoxuan
    +
  • + +
  • + +
    +
    #icon-jia
    +
  • + +
  • + +
    取消
    +
    #icon-quxiao
    +
  • + +
  • + +
    退出
    +
    #icon-tuichu
    +
  • + +
  • + +
    复制
    +
    #icon-fuzhi
    +
  • + +
  • + +
    上传
    +
    #icon-shangchuan
    +
  • + +
  • + +
    全选
    +
    #icon-total_selection
    +
  • + +
  • + +
    停止
    +
    #icon-tingzhi
    +
  • + +
  • + +
    文件夹
    +
    #icon-wenjianjia
    +
  • + +
  • + +
    菜单
    +
    #icon-caidan
    +
  • + +
  • + +
    文件
    +
    #icon-wenjian
    +
  • + +
  • + +
    别针
    +
    #icon-biezhen
    +
  • + +
  • + +
    其它
    +
    #icon-qita
    +
  • +

    Symbol 引用

    diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.css b/unpackage/dist/build/app-plus/static/iconfont/iconfont.css index 0e76239..bee14e5 100644 --- a/unpackage/dist/build/app-plus/static/iconfont/iconfont.css +++ b/unpackage/dist/build/app-plus/static/iconfont/iconfont.css @@ -1,6 +1,8 @@ @font-face { - font-family: "iconfont"; /* Project id */ - src: url('iconfont.ttf?t=1776936195904') format('truetype'); + font-family: "iconfont"; /* Project id 4890805 */ + src: url('iconfont.woff2?t=1782200893170') format('woff2'), + url('iconfont.woff?t=1782200893170') format('woff'), + url('iconfont.ttf?t=1782200893170') format('truetype'); } .iconfont { @@ -11,6 +13,182 @@ -moz-osx-font-smoothing: grayscale; } +.icon-cloud:before { + content: "\e988"; +} + +.icon-qitawenjian:before { + content: "\e7b6"; +} + +.icon-wenjianyasuo:before { + content: "\e643"; +} + +.icon-wenjianshipin:before { + content: "\e644"; +} + +.icon-wenjianyinpin:before { + content: "\e645"; +} + +.icon-wenjiantupian:before { + content: "\e646"; +} + +.icon-daimawenjian:before { + content: "\e66a"; +} + +.icon-file-markdown-fill:before { + content: "\ebb1"; +} + +.icon-SVG:before { + content: "\e614"; +} + +.icon-HTML:before { + content: "\e615"; +} + +.icon-CSS:before { + content: "\e618"; +} + +.icon-CSV:before { + content: "\e619"; +} + +.icon-JSON:before { + content: "\e61b"; +} + +.icon-JS:before { + content: "\e61c"; +} + +.icon-PDF:before { + content: "\e61e"; +} + +.icon-PHP:before { + content: "\e621"; +} + +.icon-TXT:before { + content: "\e622"; +} + +.icon-XLS:before { + content: "\e623"; +} + +.icon-DOC:before { + content: "\e624"; +} + +.icon-PPT:before { + content: "\e626"; +} + +.icon-SQL:before { + content: "\e627"; +} + +.icon-bianji:before { + content: "\e605"; +} + +.icon-fasong:before { + content: "\e705"; +} + +.icon-download:before { + content: "\e61a"; +} + +.icon-edit-fill:before { + content: "\e61d"; +} + +.icon-favorite-fill:before { + content: "\e61f"; +} + +.icon-favorite:before { + content: "\e620"; +} + +.icon-upload:before { + content: "\e63e"; +} + +.icon-yonghuziliao:before { + content: "\e6a1"; +} + +.icon-pen-fill:before { + content: "\e67c"; +} + +.icon-qunliao:before { + content: "\e606"; +} + +.icon-shipintonghua:before { + content: "\e609"; +} + +.icon-tianjia:before { + content: "\e60d"; +} + +.icon-tongxunlu:before { + content: "\e612"; +} + +.icon-tianjiahaoyou:before { + content: "\e613"; +} + +.icon-shanchu:before { + content: "\e6d3"; +} + +.icon-choose-fill:before { + content: "\e6a2"; +} + +.icon-a-wenjianjiawenjian:before { + content: "\e69e"; +} + +.icon-sousuo:before { + content: "\e6eb"; +} + +.icon-Robot:before { + content: "\e67d"; +} + +.icon-saochu:before { + content: "\e6a3"; +} + +.icon-fanhui:before { + content: "\e765"; +} + +.icon-brain-2-fill:before { + content: "\e800"; +} + +.icon-gengduo:before { + content: "\e6c5"; +} + .icon-del:before { content: "\e616"; } @@ -67,95 +245,7 @@ content: "\e647"; } -.icon-bianji:before { - content: "\e605"; -} - -.icon-fasong:before { - content: "\e705"; -} - -.icon-download:before { - content: "\e61a"; -} - -.icon-edit-fill:before { - content: "\e61d"; -} - -.icon-favorite-fill:before { - content: "\e61f"; -} - -.icon-favorite:before { - content: "\e620"; -} - -.icon-upload:before { - content: "\e63e"; -} - -.icon-yonghuziliao:before { - content: "\e6a1"; -} - -.icon-pen-fill:before { - content: "\e667"; -} - -.icon-qunliao:before { - content: "\e606"; -} - -.icon-shipintonghua:before { - content: "\e609"; -} - -.icon-tianjia:before { - content: "\e60d"; -} - -.icon-tongxunlu:before { - content: "\e612"; -} - -.icon-tianjiahaoyou:before { - content: "\e613"; -} - -.icon-shanchu:before { - content: "\e6d3"; -} - -.icon-choose-fill:before { - content: "\e6a2"; -} - -.icon-a-wenjianjiawenjian:before { - content: "\e69e"; -} - -.icon-sousuo:before { - content: "\e6eb"; -} - -.icon-Robot:before { - content: "\e661"; -} - -.icon-saochu:before { - content: "\e6a3"; -} - -.icon-fanhui:before { - content: "\e765"; -} - -.icon-brain-2-fill:before { - content: "\e800"; -} - -.icon-gengduo:before { - content: "\e6c5"; +.icon-qita:before { + content: "\e600"; } diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.js b/unpackage/dist/build/app-plus/static/iconfont/iconfont.js index ec9c3a7..d9e46f5 100644 --- a/unpackage/dist/build/app-plus/static/iconfont/iconfont.js +++ b/unpackage/dist/build/app-plus/static/iconfont/iconfont.js @@ -1 +1 @@ -window._iconfont_svg_string_='',(a=>{var l=(c=(c=document.getElementsByTagName("script"))[c.length-1]).getAttribute("data-injectcss"),c=c.getAttribute("data-disable-injectsvg");if(!c){var i,h,t,o,s,e=function(l,c){c.parentNode.insertBefore(l,c)};if(l&&!a.__iconfont__svg__cssinject__){a.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(l){console&&console.log(l)}}i=function(){var l,c=document.createElement("div");c.innerHTML=a._iconfont_svg_string_,(c=c.getElementsByTagName("svg")[0])&&(c.setAttribute("aria-hidden","true"),c.style.position="absolute",c.style.width=0,c.style.height=0,c.style.overflow="hidden",c=c,(l=document.body).firstChild?e(c,l.firstChild):l.appendChild(c))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(i,0):(h=function(){document.removeEventListener("DOMContentLoaded",h,!1),i()},document.addEventListener("DOMContentLoaded",h,!1)):document.attachEvent&&(t=i,o=a.document,s=!1,n(),o.onreadystatechange=function(){"complete"==o.readyState&&(o.onreadystatechange=null,d())})}function d(){s||(s=!0,t())}function n(){try{o.documentElement.doScroll("left")}catch(l){return void setTimeout(n,50)}d()}})(window); \ No newline at end of file +window._iconfont_svg_string_4890805='',(c=>{var a=(h=(h=document.getElementsByTagName("script"))[h.length-1]).getAttribute("data-injectcss"),h=h.getAttribute("data-disable-injectsvg");if(!h){var l,v,t,i,z,o=function(a,h){h.parentNode.insertBefore(a,h)};if(a&&!c.__iconfont__svg__cssinject__){c.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(a){console&&console.log(a)}}l=function(){var a,h=document.createElement("div");h.innerHTML=c._iconfont_svg_string_4890805,(h=h.getElementsByTagName("svg")[0])&&(h.setAttribute("aria-hidden","true"),h.style.position="absolute",h.style.width=0,h.style.height=0,h.style.overflow="hidden",h=h,(a=document.body).firstChild?o(h,a.firstChild):a.appendChild(h))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(l,0):(v=function(){document.removeEventListener("DOMContentLoaded",v,!1),l()},document.addEventListener("DOMContentLoaded",v,!1)):document.attachEvent&&(t=l,i=c.document,z=!1,m(),i.onreadystatechange=function(){"complete"==i.readyState&&(i.onreadystatechange=null,p())})}function p(){z||(z=!0,t())}function m(){try{i.documentElement.doScroll("left")}catch(a){return void setTimeout(m,50)}p()}})(window); \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.json b/unpackage/dist/build/app-plus/static/iconfont/iconfont.json index 05311a0..36b9730 100644 --- a/unpackage/dist/build/app-plus/static/iconfont/iconfont.json +++ b/unpackage/dist/build/app-plus/static/iconfont/iconfont.json @@ -1,10 +1,318 @@ { - "id": "", - "name": "", + "id": "4890805", + "name": "information", "font_family": "iconfont", "css_prefix_text": "icon-", "description": "", "glyphs": [ + { + "icon_id": "18170211", + "name": "云端,云,云服务", + "font_class": "cloud", + "unicode": "e988", + "unicode_decimal": 59784 + }, + { + "icon_id": "35959059", + "name": "其他文件", + "font_class": "qitawenjian", + "unicode": "e7b6", + "unicode_decimal": 59318 + }, + { + "icon_id": "1004650", + "name": "文件-压缩", + "font_class": "wenjianyasuo", + "unicode": "e643", + "unicode_decimal": 58947 + }, + { + "icon_id": "1004652", + "name": "文件-视频", + "font_class": "wenjianshipin", + "unicode": "e644", + "unicode_decimal": 58948 + }, + { + "icon_id": "1004653", + "name": "文件-音频", + "font_class": "wenjianyinpin", + "unicode": "e645", + "unicode_decimal": 58949 + }, + { + "icon_id": "1004654", + "name": "文件-图片", + "font_class": "wenjiantupian", + "unicode": "e646", + "unicode_decimal": 58950 + }, + { + "icon_id": "26618450", + "name": "代码文件", + "font_class": "daimawenjian", + "unicode": "e66a", + "unicode_decimal": 58986 + }, + { + "icon_id": "19702974", + "name": "markdown文件", + "font_class": "file-markdown-fill", + "unicode": "ebb1", + "unicode_decimal": 60337 + }, + { + "icon_id": "12904094", + "name": "SVG", + "font_class": "SVG", + "unicode": "e614", + "unicode_decimal": 58900 + }, + { + "icon_id": "12904096", + "name": "HTML", + "font_class": "HTML", + "unicode": "e615", + "unicode_decimal": 58901 + }, + { + "icon_id": "12904097", + "name": "CSS", + "font_class": "CSS", + "unicode": "e618", + "unicode_decimal": 58904 + }, + { + "icon_id": "12904100", + "name": "CSV", + "font_class": "CSV", + "unicode": "e619", + "unicode_decimal": 58905 + }, + { + "icon_id": "12904101", + "name": "JSON", + "font_class": "JSON", + "unicode": "e61b", + "unicode_decimal": 58907 + }, + { + "icon_id": "12904102", + "name": "JS", + "font_class": "JS", + "unicode": "e61c", + "unicode_decimal": 58908 + }, + { + "icon_id": "12904106", + "name": "PDF", + "font_class": "PDF", + "unicode": "e61e", + "unicode_decimal": 58910 + }, + { + "icon_id": "12904107", + "name": "PHP", + "font_class": "PHP", + "unicode": "e621", + "unicode_decimal": 58913 + }, + { + "icon_id": "12904108", + "name": "TXT", + "font_class": "TXT", + "unicode": "e622", + "unicode_decimal": 58914 + }, + { + "icon_id": "12904109", + "name": "XLS", + "font_class": "XLS", + "unicode": "e623", + "unicode_decimal": 58915 + }, + { + "icon_id": "12904116", + "name": "DOC", + "font_class": "DOC", + "unicode": "e624", + "unicode_decimal": 58916 + }, + { + "icon_id": "12904119", + "name": "PPT", + "font_class": "PPT", + "unicode": "e626", + "unicode_decimal": 58918 + }, + { + "icon_id": "12904126", + "name": "SQL", + "font_class": "SQL", + "unicode": "e627", + "unicode_decimal": 58919 + }, + { + "icon_id": "7515699", + "name": "编辑", + "font_class": "bianji", + "unicode": "e605", + "unicode_decimal": 58885 + }, + { + "icon_id": "8440993", + "name": "发送", + "font_class": "fasong", + "unicode": "e705", + "unicode_decimal": 59141 + }, + { + "icon_id": "9512543", + "name": "下载", + "font_class": "download", + "unicode": "e61a", + "unicode_decimal": 58906 + }, + { + "icon_id": "9512544", + "name": "编辑", + "font_class": "edit-fill", + "unicode": "e61d", + "unicode_decimal": 58909 + }, + { + "icon_id": "9512556", + "name": "收藏", + "font_class": "favorite-fill", + "unicode": "e61f", + "unicode_decimal": 58911 + }, + { + "icon_id": "9512559", + "name": "收藏", + "font_class": "favorite", + "unicode": "e620", + "unicode_decimal": 58912 + }, + { + "icon_id": "9512675", + "name": "上传", + "font_class": "upload", + "unicode": "e63e", + "unicode_decimal": 58942 + }, + { + "icon_id": "11633996", + "name": "用户资料", + "font_class": "yonghuziliao", + "unicode": "e6a1", + "unicode_decimal": 59041 + }, + { + "icon_id": "17775968", + "name": "笔", + "font_class": "pen-fill", + "unicode": "e67c", + "unicode_decimal": 59004 + }, + { + "icon_id": "18537099", + "name": "群聊", + "font_class": "qunliao", + "unicode": "e606", + "unicode_decimal": 58886 + }, + { + "icon_id": "18537375", + "name": "视频通话", + "font_class": "shipintonghua", + "unicode": "e609", + "unicode_decimal": 58889 + }, + { + "icon_id": "18654056", + "name": "添加", + "font_class": "tianjia", + "unicode": "e60d", + "unicode_decimal": 58893 + }, + { + "icon_id": "18655694", + "name": "通讯录", + "font_class": "tongxunlu", + "unicode": "e612", + "unicode_decimal": 58898 + }, + { + "icon_id": "18656610", + "name": "添加好友", + "font_class": "tianjiahaoyou", + "unicode": "e613", + "unicode_decimal": 58899 + }, + { + "icon_id": "24660909", + "name": "删除", + "font_class": "shanchu", + "unicode": "e6d3", + "unicode_decimal": 59091 + }, + { + "icon_id": "25015243", + "name": "选择箭头-fill", + "font_class": "choose-fill", + "unicode": "e6a2", + "unicode_decimal": 59042 + }, + { + "icon_id": "27229314", + "name": "文件夹,文件", + "font_class": "a-wenjianjiawenjian", + "unicode": "e69e", + "unicode_decimal": 59038 + }, + { + "icon_id": "27995029", + "name": "搜索", + "font_class": "sousuo", + "unicode": "e6eb", + "unicode_decimal": 59115 + }, + { + "icon_id": "28661052", + "name": "Robot", + "font_class": "Robot", + "unicode": "e67d", + "unicode_decimal": 59005 + }, + { + "icon_id": "32429618", + "name": "扫除", + "font_class": "saochu", + "unicode": "e6a3", + "unicode_decimal": 59043 + }, + { + "icon_id": "38950621", + "name": "返回", + "font_class": "fanhui", + "unicode": "e765", + "unicode_decimal": 59237 + }, + { + "icon_id": "42230703", + "name": "brain-2-fill", + "font_class": "brain-2-fill", + "unicode": "e800", + "unicode_decimal": 59392 + }, + { + "icon_id": "43005043", + "name": "更多", + "font_class": "gengduo", + "unicode": "e6c5", + "unicode_decimal": 59077 + }, { "icon_id": "109713", "name": "垃圾桶", @@ -104,165 +412,11 @@ "unicode_decimal": 58951 }, { - "icon_id": "7515699", - "name": "编辑", - "font_class": "bianji", - "unicode": "e605", - "unicode_decimal": 58885 - }, - { - "icon_id": "8440993", - "name": "发送", - "font_class": "fasong", - "unicode": "e705", - "unicode_decimal": 59141 - }, - { - "icon_id": "9512543", - "name": "下载", - "font_class": "download", - "unicode": "e61a", - "unicode_decimal": 58906 - }, - { - "icon_id": "9512544", - "name": "编辑", - "font_class": "edit-fill", - "unicode": "e61d", - "unicode_decimal": 58909 - }, - { - "icon_id": "9512556", - "name": "收藏", - "font_class": "favorite-fill", - "unicode": "e61f", - "unicode_decimal": 58911 - }, - { - "icon_id": "9512559", - "name": "收藏", - "font_class": "favorite", - "unicode": "e620", - "unicode_decimal": 58912 - }, - { - "icon_id": "9512675", - "name": "上传", - "font_class": "upload", - "unicode": "e63e", - "unicode_decimal": 58942 - }, - { - "icon_id": "11633996", - "name": "用户资料", - "font_class": "yonghuziliao", - "unicode": "e6a1", - "unicode_decimal": 59041 - }, - { - "icon_id": "17775968", - "name": "笔", - "font_class": "pen-fill", - "unicode": "e667", - "unicode_decimal": 58983 - }, - { - "icon_id": "18537099", - "name": "群聊", - "font_class": "qunliao", - "unicode": "e606", - "unicode_decimal": 58886 - }, - { - "icon_id": "18537375", - "name": "视频通话", - "font_class": "shipintonghua", - "unicode": "e609", - "unicode_decimal": 58889 - }, - { - "icon_id": "18654056", - "name": "添加", - "font_class": "tianjia", - "unicode": "e60d", - "unicode_decimal": 58893 - }, - { - "icon_id": "18655694", - "name": "通讯录", - "font_class": "tongxunlu", - "unicode": "e612", - "unicode_decimal": 58898 - }, - { - "icon_id": "18656610", - "name": "添加好友", - "font_class": "tianjiahaoyou", - "unicode": "e613", - "unicode_decimal": 58899 - }, - { - "icon_id": "24660909", - "name": "删除", - "font_class": "shanchu", - "unicode": "e6d3", - "unicode_decimal": 59091 - }, - { - "icon_id": "25015243", - "name": "选择箭头-fill", - "font_class": "choose-fill", - "unicode": "e6a2", - "unicode_decimal": 59042 - }, - { - "icon_id": "27229314", - "name": "文件夹,文件", - "font_class": "a-wenjianjiawenjian", - "unicode": "e69e", - "unicode_decimal": 59038 - }, - { - "icon_id": "27995029", - "name": "搜索", - "font_class": "sousuo", - "unicode": "e6eb", - "unicode_decimal": 59115 - }, - { - "icon_id": "28661052", - "name": "Robot", - "font_class": "Robot", - "unicode": "e661", - "unicode_decimal": 58977 - }, - { - "icon_id": "32429618", - "name": "扫除", - "font_class": "saochu", - "unicode": "e6a3", - "unicode_decimal": 59043 - }, - { - "icon_id": "38950621", - "name": "返回", - "font_class": "fanhui", - "unicode": "e765", - "unicode_decimal": 59237 - }, - { - "icon_id": "42230703", - "name": "brain-2-fill", - "font_class": "brain-2-fill", - "unicode": "e800", - "unicode_decimal": 59392 - }, - { - "icon_id": "43005043", - "name": "更多", - "font_class": "gengduo", - "unicode": "e6c5", - "unicode_decimal": 59077 + "icon_id": "1250", + "name": "其它", + "font_class": "qita", + "unicode": "e600", + "unicode_decimal": 58880 } ] } diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.ttf b/unpackage/dist/build/app-plus/static/iconfont/iconfont.ttf index 0f6a066..d1f39be 100644 Binary files a/unpackage/dist/build/app-plus/static/iconfont/iconfont.ttf and b/unpackage/dist/build/app-plus/static/iconfont/iconfont.ttf differ diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff b/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff new file mode 100644 index 0000000..073dda9 Binary files /dev/null and b/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff differ diff --git a/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff2 b/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff2 new file mode 100644 index 0000000..a7a3a3b Binary files /dev/null and b/unpackage/dist/build/app-plus/static/iconfont/iconfont.woff2 differ diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/changelog.md b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/changelog.md deleted file mode 100644 index f1fdae0..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/changelog.md +++ /dev/null @@ -1,26 +0,0 @@ -## 0.1.3(2025-09-16) -- chore: 更新文档 -## 0.1.2(2025-06-07) -- chore: 更新文档 -## 0.1.1(2025-06-02) -- feat: 兼容鸿蒙next -## 0.1.0(2025-04-04) -- chore: 更新文档 -## 0.0.9(2025-03-11) -- fix: 修复安卓报错的问题 -## 0.0.8(2025-03-11) -- fix: 修复报错的问题 -## 0.0.7(2025-03-10) -- feat: 增加重命名选项 -## 0.0.6(2025-02-28) -- feat: 修复uniapp ios路径问题 -## 0.0.5(2024-10-31) -- feat: 修复uniapp ios无法使用 -## 0.0.4(2024-10-26) -- feat: 规范类型 -## 0.0.3(2024-07-10) -- fext: 兼容ios -## 0.0.2(2024-05-21) -- fix: 修复uniapp找不到文件的错误 -## 0.0.1(2024-04-15) -- init diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/l-choose-file/l-choose-file.vue b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/l-choose-file/l-choose-file.vue deleted file mode 100644 index f60f5cb..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/l-choose-file/l-choose-file.vue +++ /dev/null @@ -1,38 +0,0 @@ - - - - - \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.uvue b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.uvue deleted file mode 100644 index 4eac8c6..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.uvue +++ /dev/null @@ -1,103 +0,0 @@ - - - - - \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.vue b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.vue deleted file mode 100644 index 7b3067d..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/components/lime-choose-file/lime-choose-file.vue +++ /dev/null @@ -1,36 +0,0 @@ - - - - - \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/encrypt b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/encrypt deleted file mode 100644 index 8e9d757..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/encrypt +++ /dev/null @@ -1,2 +0,0 @@ -,P=[&۸6 -IT ]r*IF܃C咺+E|q`(I_+DZsfVqgqݰIC*NRWO5@\7ta `e7HF:Dr|# \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/package.json b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/package.json deleted file mode 100644 index 6288892..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/package.json +++ /dev/null @@ -1,105 +0,0 @@ -{ - "id": "lime-choose-file", - "displayName": "lime-choose-file 文件选择", - "version": "0.1.3", - "description": "lime-choose-file 文件选择参考uni.chooseFile API实现的UTS API,用法保持一致,从本地选择文件。兼容uniapp/uniappX", - "keywords": [ - "chooseFile", - "文件选择", - "uts" -], - "repository": "", - "engines": { - "HBuilderX": "^4.11", - "uni-app": "^4.61", - "uni-app-x": "^4.61" - }, - "dcloudext": { - "type": "uts", - "sale": { - "regular": { - "price": "29.00" - }, - "sourcecode": { - "price": "268.00" - } - }, - "contact": { - "qq": "" - }, - "declaration": { - "ads": "无", - "data": "无", - "permissions": "无" - }, - "npmurl": "", - "darkmode": "x", - "i18n": "x", - "widescreen": "x" - }, - "uni_modules": { - "dependencies": [], - "encrypt": [], - "platforms": { - "cloud": { - "tcb": "√", - "aliyun": "√", - "alipay": "√" - }, - "client": { - "uni-app": { - "vue": { - "vue2": "√", - "vue3": "√" - }, - "web": { - "safari": "√", - "chrome": "√" - }, - "app": { - "vue": "√", - "nvue": "√", - "android": { - "extVersion": "", - "minVersion": "21" - }, - "ios": "√", - "harmony": "√" - }, - "mp": { - "weixin": "√", - "alipay": "-", - "toutiao": "-", - "baidu": "-", - "kuaishou": "-", - "jd": "-", - "harmony": "-", - "qq": "-", - "lark": "-" - }, - "quickapp": { - "huawei": "-", - "union": "-" - } - }, - "uni-app-x": { - "web": { - "safari": "√", - "chrome": "√" - }, - "app": { - "android": { - "extVersion": "", - "minVersion": "21" - }, - "ios": "√", - "harmony": "√" - }, - "mp": { - "weixin": "√" - } - } - } - } - } -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme copy.md b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme copy.md deleted file mode 100644 index 45dcce2..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme copy.md +++ /dev/null @@ -1,61 +0,0 @@ -# lime-choosefile 文件选择 -文件选择UTS API系参考小程序chooseFile API实现的,用法保持一致,目前仅支持uniappX(web,ios,安卓,鸿蒙) - - -## 文档 - 🚀 [choose-file【站点1】](https://limex.qcoon.cn/native/choose-file.html) - 🌍 [choose-file【站点2】](https://limeui.netlify.app/native/choose-file.html) - 🔥 [choose-file【站点3】](https://limeui.familyzone.top/native/choose-file.html) - - - -## 安装 -插件市场导入,APP需要在页面上引入,然后自定义基座,完成自定义基座后,选择自定义基座运行 - -## 使用 -### UNIAPPX -```js -import { chooseFile, type ChooseFileOption } from '@/uni_modules/lime-choose-file' - -const images = ref([]) -const onClick = () => { - chooseFile({ - filename: 'xxxx', // 可选 用于给文件重命名(安卓、IOS) - type: 'image', - success(res){ - images.value = res.tempFiles.map((item):string => item.path) - console.log('res', res.tempFiles) - }, - fail(err){ - console.log('err', err) - } - } as ChooseFileOption) -} -``` - -### UNIAPP -```js -import { chooseFile } from '@/uni_modules/lime-choose-file' - -const images = ref([]) -const onClick = () => { - chooseFile({ - filename: 'xxxx', // 可选 用于给文件重命名(安卓、IOS) - type: 'image', - success(res){ - images.value = res.tempFiles.map((item):string => item.path) - console.log('res', res.tempFiles) - }, - fail(err){ - console.log('err', err) - } - }) -} -``` - -## 常见问题 -- 1、IOS路径是中文时无法上传到服务器,这时候需要设置`filename`给文件重命名 - - -## API -因为直接参照小程序`chooseFile`API,所以可以直接按[chooseFile](https://uniapp.dcloud.net.cn/api/media/file.html#choosefile)文档来 \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme.md b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme.md deleted file mode 100644 index fde224f..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/readme.md +++ /dev/null @@ -1,126 +0,0 @@ -# lime-choose-file 文件选择组件 -一个基于UTS实现的文件选择插件,参考小程序chooseFile API实现,用法保持一致。支持安卓、iOS、鸿蒙和H5平台。提供了选择图片、视频和其他文件类型的功能。组件提供了简单易用的API,使开发者能够方便地在应用中集成文件选择功能。 - -## 文档链接 -📚 组件详细文档请访问以下站点: -- [文件选择组件文档 - 站点1](https://limex.qcoon.cn/native/choose-file.html) -- [文件选择组件文档 - 站点2](https://limeui.netlify.app/native/choose-file.html) -- [文件选择组件文档 - 站点3](https://limeui.familyzone.top/native/choose-file.html) - -## 安装方法 -1. 在uni-app插件市场中搜索并导入`lime-choose-file` -2. 导入后在页面引入相关方法 -3. 需要自定义基座才能使用 -4. 试用符合需求后才购买,插件无法退款 - -## 代码演示 - -### UNIAPPX 使用方式 -```ts -import { chooseFile, type ChooseFileOption } from '@/uni_modules/lime-choose-file' - -const images = ref([]) -const onClick = () => { - chooseFile({ - filename: 'xxxx', // 可选 用于给文件重命名(安卓、iOS) - type: 'image', - success(res){ - images.value = res.tempFiles.map((item):string => item.path) - console.log('选择结果:', res.tempFiles) - }, - fail(err){ - console.log('选择失败:', err) - } - } as ChooseFileOption) -} -``` - -### UNIAPP 使用方式 -```ts -import { chooseFile } from '@/uni_modules/lime-choose-file' - -const images = ref([]) -const onClick = () => { - chooseFile({ - filename: 'xxxx', // 可选 用于给文件重命名(安卓、iOS) - type: 'image', - success(res){ - images.value = res.tempFiles.map((item):string => item.path) - console.log('选择结果:', res.tempFiles) - }, - fail(err){ - console.log('选择失败:', err) - } - }) -} -``` - -## API文档 - -### chooseFile 方法 - -| 参数 | 说明 | 类型 | 必填 | -| --- | --- | --- | --- | -| options | 文件选择选项 | _ChooseFileOption_ | 是 | - -### ChooseFileOption 选项 - -| 参数 | 类型 | 必填 | 说明 | -| --- | --- | --- | --- | -| filename | _string_ | 否 | 指定文件名,用于给文件重命名(安卓、iOS) | -| count | _number_ | 否 | 最多可以选择的文件数量,默认为100 | -| type | _string_ | 否 | 所选文件类型,默认为'all' | -| extension | _string[]_ | 否 | 根据文件拓展名过滤,每一项都不能是空字符串。默认不过滤。仅H5支持 | -| success | _(result: ChooseFileSuccessCallbackResult) => void_ | 否 | 接口调用成功的回调函数 | -| fail | _(res: GeneralCallbackResult) => void_ | 否 | 接口调用失败的回调函数 | -| complete | _(res: GeneralCallbackResult) => void_ | 否 | 接口调用结束的回调函数 | - -### ChooseFileSuccessCallbackResult 返回参数 - -| 参数 | 类型 | 说明 | -| --- | --- | --- | -| tempFiles | _ChooseFile[]_ | 返回选择的文件的本地临时文件对象数组 | -| errMsg | _string_ | 错误信息 | - -### ChooseFile 对象结构 - -| 参数 | 类型 | 说明 | -| --- | --- | --- | -| name | _string_ | 选择的文件名称 | -| path | _string_ | 本地临时文件路径 (本地路径) | -| size | _number_ | 本地临时文件大小,单位 B | -| time | _number_ | 选择的文件的会话发送时间,Unix时间戳 | -| type | _'video' \| 'image' \| 'file' \| 'all'_ | 选择的文件类型 | - -### 文件类型说明 - -| 类型值 | 说明 | -| --- | --- | -| video | 视频文件 | -| image | 图片文件 | -| file | 除图片和视频外的其他文件 | -| all | 所有类型文件 | - -## 功能特点 - -- 支持多种文件类型的选择,包括图片、视频和其他文件 -- 支持文件重命名功能 -- 兼容安卓、iOS、鸿蒙和H5平台 -- 提供简单易用的API接口 -- 支持指定最大选择数量 -- 支持文件扩展名过滤(H5平台) - -## 常见问题 - -- iOS路径是中文时无法上传到服务器,这时候需要设置`filename`给文件重命名 -- APP端需要自定义基座才能使用 -- 文件选择后会返回临时文件路径,需要及时使用或保存 -- H5端可以通过extension参数过滤文件类型 - -## 支持与赞赏 - -如果你觉得本插件解决了你的问题,可以考虑支持作者: - -| 支付宝赞助 | 微信赞助 | -|------------|------------| -| ![](https://testingcf.jsdelivr.net/gh/liangei/image@1.9/alipay.png) | ![](https://testingcf.jsdelivr.net/gh/liangei/image@1.9/wpay.png) | diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.uts b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.uts deleted file mode 100644 index f003b1d..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.uts +++ /dev/null @@ -1,206 +0,0 @@ -// @ts-nocheck -import Intent from 'android.content.Intent'; -import ClipData from 'android.content.ClipData'; -import Uri from 'android.net.Uri'; -import InputStream from 'java.io.InputStream'; -import OpenableColumns from 'android.provider.OpenableColumns'; -import Cursor from 'android.database.Cursor'; -import File from 'java.io.File'; -import FileInputStream from 'java.io.FileInputStream'; -import FileOutputStream from 'java.io.FileOutputStream'; -import BufferedOutputStream from 'java.io.BufferedOutputStream'; -import ByteArrayInputStream from 'java.io.ByteArrayInputStream'; - -import { ChooseFileOption, ChooseFile, ChooseFileSuccessCallbackResult } from '../interface' -import { GeneralCallbackResultImpl } from '../unierror' - -const REQUEST_CODE_CHOOSE_FILE : Int = 42 -let resultFunction : ((requestCode : Int, resultCode : Int, data ?: Intent) => void) | null = null - - -class ChooseFileImpl implements ChooseFile { - name : string = '' - path : string = '' - // private _path : string = '' - size : number = 0 - time : number = 0 - type : string = 'file' - // private uri : Uri - private options: ChooseFileOption - constructor(uri : Uri, options : ChooseFileOption) { - // this.uri = uri - this.options = options - this.time = Date.now() - this.type = this.getFileTypeFromUri(uri); - // this._path = uri.getPath() ?? '' - this.getFileInfoFromUri(uri) - if (this.isCache(options)) { - this.copyFileToCache(uri) - } - - } - private isCache(options : ChooseFileOption) : boolean { - const extension = this.getFileExtension(this.name) - const extensions = options.extension - const type = options.type ?? 'all' - const hasExtension = extensions != null && extension != '' && extensions.includes(extension) - const isVideoOrImage = ['video', 'image'].includes(type) - const isFileAndNotVideoOrImage = type == 'file' && !['video', 'image'].includes(this.type); - if ((type == 'all' || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) { - return true - } else { - return false - } - } - private getFileExtension(fileName : string) : string { - const lastDotIndex = fileName.lastIndexOf("."); - if (lastDotIndex == -1) { - return ""; - } - return fileName.substring(lastDotIndex + 1); - } - private copyFileToCache(uri : Uri) { - const cacheDir = UTSAndroid.getAppCachePath(); - const context = UTSAndroid.getAppContext(); - if(cacheDir != null) { - const path = new File(cacheDir); - if (!path.exists()) { - path.mkdir(); - } - } - let fileName = this.name - if(this.options.filename != null) { - fileName = this.options.filename!; - if(this.options.count != null && this.options.count! > 1) { - fileName = `${fileName}_${Date.now()}`; - } - const extension = this.getFileExtension(this.name) - - fileName = `${fileName}.${extension}` - } - const destFile = new File(cacheDir, fileName); - - try { - const inputStream = context!.getContentResolver().openInputStream(uri) - const outputStream = new FileOutputStream(destFile) - if (inputStream != null) { - let buffer = ByteArray(1024); - let c = inputStream.read(buffer) - while (c > 0) { - outputStream.write(buffer, 0, c); - c = inputStream.read(buffer) - } - } - this.path = cacheDir + fileName//this.name - } catch (e) { - - } - } - private getFileTypeFromUri(uri : Uri) : string { - const context = UTSAndroid.getAppContext(); - let fileType = 'file' - let mimeType = context!.getContentResolver().getType(uri); - if (mimeType != null) { - if (mimeType.startsWith("video")) { - fileType = "video"; - } else if (mimeType.startsWith("image")) { - fileType = "image"; - } - } - return fileType; - } - private getFileInfoFromUri(uri : Uri) { - const context = UTSAndroid.getAppContext(); - let cursor = context!.getContentResolver().query(uri, null, null, null, null); - if (cursor != null && cursor.moveToFirst()) { - this.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME)) - const fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE)); - this.size = Number.from(fileSize) - cursor.close(); - } else if ("file".equals(uri.getScheme())) { - this.name = uri.getLastPathSegment() ?? ''; - const file = new File(uri.getPath() ?? ''); - const fileSize = file.length(); - this.size = Number.from(fileSize) - } - } -} - - -export function chooseFile(options : ChooseFileOption) { - if (resultFunction != null) { - UTSAndroid.offAppActivityResult(resultFunction!) - } - const type = options.type ?? 'all' - const intent = new Intent(Intent.ACTION_GET_CONTENT); - if (type.equals("all") || type.equals("file")) { - intent.setType("*/*"); - } else if (type.equals("video")) { - intent.setType("video/*"); - } else if (type.equals("image")) { - intent.setType("image/*"); - } - intent.addCategory(Intent.CATEGORY_OPENABLE); - intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, options.count == 1 ? false : true); // 允许多选 - - resultFunction = (requestCode : Int, resultCode : Int, data ?: Intent) => { - if (requestCode == REQUEST_CODE_CHOOSE_FILE) { - UTSAndroid.offAppActivityResult(resultFunction!); - if (resultCode == -1 && data != null) { - const clipData = data.getClipData(); - const tempFiles : ChooseFile[] = [] - - if (clipData != null) { - // 多选 - // const itemCount = clipData.getItemCount(); - // if (options.count != null && options.count! > itemCount) { - // const err = new GeneralCallbackResultImpl(9010002, `选中文件数量超过${options.count}`) - // options.fail?.(err) - // options.complete?.(err) - // return - // } - for (let i = 0; i < clipData.getItemCount(); i++) { - const uri = clipData.getItemAt(i.toInt()).getUri(); - const chooseFile = new ChooseFileImpl(uri, options); - if(chooseFile.path !=''){ - tempFiles.push(chooseFile) - } - } - } else { - // 单选 - const uri = data.getData(); - if (uri != null) { - const chooseFile = new ChooseFileImpl(uri, options) - if(chooseFile.path !='' ){ - tempFiles.push(chooseFile) - } - - } - } - const count = options.count ?? Integer.MAX_VALUE // Number.MAX_VALUE - if(tempFiles.length > 0 && count >= tempFiles.length){ - options.success?.({ - tempFiles, - errMsg: 'chooseFile:ok' - } as ChooseFileSuccessCallbackResult) - } else { - const err = new GeneralCallbackResultImpl(9010002, `没有可用的文件或文件超过设置数量`) - options.fail?.(err) - options.complete?.(err) - } - } else { - const err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`) - options.fail?.(err) - options.complete?.(err) - } - } else { - const err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`) - options.fail?.(err) - options.complete?.(err) - } - } - - UTSAndroid.onAppActivityResult(resultFunction!) - UTSAndroid.getUniActivity()!.startActivityForResult(Intent.createChooser(intent, "选择文件"), REQUEST_CODE_CHOOSE_FILE) - // UTSAndroid.getUniActivity()!.overridePendingTransition((10).toInt(), (0).toInt()); -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/src/index.kt b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/src/index.kt new file mode 100644 index 0000000..15800f5 --- /dev/null +++ b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-android/src/index.kt @@ -0,0 +1,262 @@ +@file:Suppress("UNCHECKED_CAST", "USELESS_CAST", "INAPPLICABLE_JVM_NAME", "UNUSED_ANONYMOUS_PARAMETER", "SENSELESS_COMPARISON", "NAME_SHADOWING", "UNNECESSARY_NOT_NULL_ASSERTION") +package uts.sdk.modules.limeChooseFile +import android.content.Intent +import android.net.Uri +import android.provider.OpenableColumns +import io.dcloud.uniapp.* +import io.dcloud.uniapp.extapi.* +import io.dcloud.uts.* +import io.dcloud.uts.Map +import io.dcloud.uts.Set +import io.dcloud.uts.UTSAndroid +import java.io.File +import java.io.FileOutputStream +import kotlin.properties.Delegates +import kotlinx.coroutines.CoroutineScope +import kotlinx.coroutines.Deferred +import kotlinx.coroutines.Dispatchers +import kotlinx.coroutines.async +typealias ChooseFileErrorCode = Number +interface GeneralCallbackResult : IUniError { + override var errCode: ChooseFileErrorCode +} +interface ChooseFile { + var name: String + var path: String + var size: Number + var time: Number + var type: String +} +open class ChooseFileSuccessCallbackResult ( + @JsonNotNull + open var tempFiles: UTSArray, + @JsonNotNull + open var errMsg: String, +) : UTSObject() +typealias ChooseFileSuccessCallback = (result: ChooseFileSuccessCallbackResult) -> Unit +typealias ChooseFileFailCallback = (res: GeneralCallbackResult) -> Unit +typealias ChooseFileCompleteCallback = (res: GeneralCallbackResult) -> Unit +open class ChooseFileOption ( + open var filename: String? = null, + open var count: Number? = null, + open var type: String? = null, + open var extension: UTSArray? = null, + open var success: ChooseFileSuccessCallback? = null, + open var fail: ChooseFileFailCallback? = null, + open var complete: ChooseFileCompleteCallback? = null, +) : UTSObject() +val UniErrorSubject = "chooseFile\"" +val UniErrors: Map = Map(_uA( + _uA( + 9010001, + "chooseFile:ok" + ), + _uA( + 9010002, + "ChooseFile:failed" + ) +)) +open class GeneralCallbackResultImpl : UniError, GeneralCallbackResult { + constructor(errCode: ChooseFileErrorCode, errMsg: String? = null) : super() { + this.errSubject = UniErrorSubject + this.errCode = errCode + this.errMsg = errMsg ?: UniErrors[errCode] ?: "" + } +} +val REQUEST_CODE_CHOOSE_FILE: Int = 42 +var resultFunction: ((requestCode: Int, resultCode: Int, data: Intent?) -> Unit)? = null +open class ChooseFileImpl : ChooseFile { + override var name: String = "" + override var path: String = "" + override var size: Number = 0 + override var time: Number = 0 + override var type: String = "file" + private var options: ChooseFileOption + constructor(uri: Uri, options: ChooseFileOption){ + this.options = options + this.time = Date.now() + this.type = this.getFileTypeFromUri(uri) + this.getFileInfoFromUri(uri) + if (this.isCache(options)) { + this.copyFileToCache(uri) + } + } + private fun isCache(options: ChooseFileOption): Boolean { + val extension = this.getFileExtension(this.name) + val extensions = options.extension + val type = options.type ?: "all" + val hasExtension = extensions != null && extension != "" && extensions.includes(extension) + val isVideoOrImage = _uA( + "video", + "image" + ).includes(type) + val isFileAndNotVideoOrImage = type == "file" && !_uA( + "video", + "image" + ).includes(this.type) + if ((type == "all" || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) { + return true + } else { + return false + } + } + private fun getFileExtension(fileName: String): String { + val lastDotIndex = fileName.lastIndexOf(".") + if (lastDotIndex == -1) { + return "" + } + return fileName.substring(lastDotIndex + 1) + } + private fun copyFileToCache(uri: Uri) { + val cacheDir = UTSAndroid.getAppCachePath() + val context = UTSAndroid.getAppContext() + if (cacheDir != null) { + val path = File(cacheDir) + if (!path.exists()) { + path.mkdir() + } + } + var fileName = this.name + if (this.options.filename != null) { + fileName = this.options.filename!! + if (this.options.count != null && this.options.count!! > 1) { + fileName = "" + fileName + "_" + Date.now() + } + val extension = this.getFileExtension(this.name) + fileName = "" + fileName + "." + extension + } + val destFile = File(cacheDir, fileName) + try { + val inputStream = context!!.getContentResolver().openInputStream(uri) + val outputStream = FileOutputStream(destFile) + if (inputStream != null) { + var buffer = ByteArray(1024) + var c = inputStream.read(buffer) + while(c > 0){ + outputStream.write(buffer, 0, c) + c = inputStream.read(buffer) + } + } + this.path = cacheDir + fileName + } + catch (e: Throwable) {} + } + private fun getFileTypeFromUri(uri: Uri): String { + val context = UTSAndroid.getAppContext() + var fileType = "file" + var mimeType = context!!.getContentResolver().getType(uri) + if (mimeType != null) { + if (mimeType.startsWith("video")) { + fileType = "video" + } else if (mimeType.startsWith("image")) { + fileType = "image" + } + } + return fileType + } + private fun getFileInfoFromUri(uri: Uri) { + val context = UTSAndroid.getAppContext() + var cursor = context!!.getContentResolver().query(uri, null, null, null, null) + if (cursor != null && cursor.moveToFirst()) { + this.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME)) + val fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE)) + this.size = UTSNumber.from(fileSize) + cursor.close() + } else if ("file".equals(uri.getScheme())) { + this.name = uri.getLastPathSegment() ?: "" + val file = File(uri.getPath() ?: "") + val fileSize = file.length() + this.size = UTSNumber.from(fileSize) + } + } +} +fun chooseFile(options: ChooseFileOption) { + if (resultFunction != null) { + UTSAndroid.offAppActivityResult(resultFunction!!) + } + val type = options.type ?: "all" + val intent = Intent(Intent.ACTION_GET_CONTENT) + if (type.equals("all") || type.equals("file")) { + intent.setType("*/*") + } else if (type.equals("video")) { + intent.setType("video/*") + } else if (type.equals("image")) { + intent.setType("image/*") + } + intent.addCategory(Intent.CATEGORY_OPENABLE) + intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, if (options.count == 1) { + false + } else { + true + } + ) + resultFunction = fun(requestCode: Int, resultCode: Int, data: Intent?){ + if (requestCode == REQUEST_CODE_CHOOSE_FILE) { + UTSAndroid.offAppActivityResult(resultFunction!!) + if (resultCode == -1 && data != null) { + val clipData = data.getClipData() + val tempFiles: UTSArray = _uA() + if (clipData != null) { + run { + var i: Number = 0 + while(i < clipData.getItemCount()){ + val uri = clipData.getItemAt(i.toInt()).getUri() + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + i++ + } + } + } else { + val uri = data.getData() + if (uri != null) { + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + } + } + val count = options.count ?: Integer.MAX_VALUE + if (tempFiles.length > 0 && count >= tempFiles.length) { + options.success?.invoke(ChooseFileSuccessCallbackResult(tempFiles = tempFiles, errMsg = "chooseFile:ok")) + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件或文件超过设置数量") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } + UTSAndroid.onAppActivityResult(resultFunction!!) + UTSAndroid.getUniActivity()!!.startActivityForResult(Intent.createChooser(intent, "选择文件"), REQUEST_CODE_CHOOSE_FILE) +} +open class ChooseFileOptionJSONObject : UTSJSONObject() { + open var filename: String? = null + open var count: Number? = null + open var type: String? = null + open var extension: UTSArray? = null + open var success: UTSCallback? = null + open var fail: UTSCallback? = null + open var complete: UTSCallback? = null +} +fun chooseFileByJs(options: ChooseFileOptionJSONObject) { + return chooseFile(ChooseFileOption(filename = options.filename, count = options.count, type = options.type, extension = options.extension, success = fun(result: ChooseFileSuccessCallbackResult): Unit { + options.success?.invoke(result) + } + , fail = fun(res: GeneralCallbackResult): Unit { + options.fail?.invoke(res) + } + , complete = fun(res: GeneralCallbackResult): Unit { + options.complete?.invoke(res) + } + )) +} diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/config.json b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/config.json deleted file mode 100644 index 721b81e..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/config.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "deploymentTarget": "9" -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/index.uts b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/index.uts deleted file mode 100644 index 413fa87..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/app-ios/index.uts +++ /dev/null @@ -1,138 +0,0 @@ -// @ts-nocheck -import { ChooseFileOption, ChooseFile, ChooseFileSuccessCallbackResult } from '../interface' -import { UIDocumentPickerDelegate, UIDocumentPickerMode } from "UIKit" -import { URL, FileManager } from 'Foundation'; -import { GeneralCallbackResultImpl } from '../unierror' -import { DispatchQueue } from 'Dispatch'; - -const documentTypes : Map = new Map([ - ["all", ["public.item"]], - ["file", [ - "public.text", - "public.zip-archive", - "public.data", - "com.adobe.pdf", - "com.microsoft.word.doc", - "com.microsoft.word.docx", - "com.microsoft.excel.xls", - "com.microsoft.excel.xlsx" - ] - ], - ["video", ["public.movie"]], - ["image", ["public.image"]], -]) - -class ChooseFileImpl { - name : string = '' - path : string = '' - size : number = 0 - time : number = 0 - type : string = 'file' - constructor(uri : URL, options : ChooseFileOption) { - try { - const originalFileName = uri.lastPathComponent; - const attributes = UTSiOS.try(FileManager.default.attributesOfItem(atPath = uri.path)) - const fileSize = attributes[FileAttributeKey.size] as number - const pathExtension = `${uri.pathExtension}` - - const imageFormats = ['jpeg', 'jpg', 'png', 'gif', 'bmp', 'tiff', 'svg'] - const videoFormats = ['mov', 'm4v', 'mp4', 'avi'] - - - let fileName = originalFileName - if(options.filename != null) { - fileName = options.filename! - if(options.count != null && options.count! > 1) { - fileName = `${fileName}_${Date.now()}`; - } - fileName = `${fileName}.${pathExtension}` - } - - // #ifdef UNI-APP-X - const dataPath = UTSiOS.getDataPath() - // #endif - // #ifndef UNI-APP-X - const dataPath = UTSiOS.getDataPath().replace(/data$/, "doc"); - // #endif - const file = new URL(fileURLWithPath = dataPath).appendingPathComponent(fileName)//.absoluteString - const fileData = FileManager.default.contents(atPath = uri.path); - UTSiOS.try(fileData?.write(to = file)) - - if (imageFormats.includes(pathExtension)) { - this.type = 'image' - } else if (videoFormats.includes(pathExtension)) { - this.type = 'video' - } else { - this.type = 'file' - } - - this.name = `${originalFileName}` - this.size = fileSize - this.path = `${file.absoluteString}` - } catch (e) { - - } - } -} - -class FilePickerManager implements UIDocumentPickerDelegate { - options : ChooseFileOption = {} - constructor() { } - chooseFile(options : ChooseFileOption) { - DispatchQueue.main.async(execute = () : void => { - this.options = options - const type = options.type ?? 'all' - const count = options.count ?? 1 - const types = (documentTypes.get(type) ?? documentTypes.get('all')) as string[] - let documentPicker = UIDocumentPickerViewController( - documentTypes = types, - in = UIDocumentPickerMode.import - ) - documentPicker.delegate = this - // 多选要大于 ios11 - if (UTSiOS.available("iOS 11.0, *")) { - documentPicker.allowsMultipleSelection = count > 1 - } - UTSiOS.getCurrentViewController().present(documentPicker, animated = true) - }) - } - documentPicker(controller : UIDocumentPickerViewController, @argumentLabel("didPickDocumentsAt") urls : URL[]) { - DispatchQueue.main.async(execute = () : void => { - const tempFiles : ChooseFile[] = [] - for (let i = 0; i < urls.length; i++) { - const url = urls[i] - const chooseFile = new ChooseFileImpl(url, this.options); - // IOS -> js 无法传class? - const file : ChooseFile = { - name: chooseFile.name, - path: chooseFile.path, - size: chooseFile.size, - time: chooseFile.time, - type: chooseFile.type, - } - if (chooseFile.path != '') { - tempFiles.push(file) - } - } - - const count = this.options.count ?? Number.from(Double.greatestFiniteMagnitude) //Number.from(Double.MAX_VALUE) - if (tempFiles.length > 0 && count >= tempFiles.length) { - const res : ChooseFileSuccessCallbackResult = { - tempFiles, - errMsg: 'chooseFile:ok' - } - this.options.success?.(res) - } else { - const err = new GeneralCallbackResultImpl(9010002, `没有可用的文件或文件超过设置数量`) - this.options.fail?.(err) - this.options.complete?.(err) - } - }) - } -} - -const fileManager = new FilePickerManager() - -export function chooseFile(options : ChooseFileOption) { - fileManager.chooseFile(options) -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/index.uts b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/index.uts deleted file mode 100644 index 29c01ab..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/index.uts +++ /dev/null @@ -1,35 +0,0 @@ -// @ts-nocheck -export * from './interface'; -import { type ChooseFileOption } from './interface'; - -export function chooseFile(options: ChooseFileOption){ - // #ifdef WEB || APP-HARMONY - uni.chooseFile({ - count: options.count ?? 100, - type: options.type, - extension: options.extension, - success(res) { - options.success?.({ - // tempFilePaths - errMsg : 'ok', - tempFiles: res.tempFiles - }) - }, - fail(err) { - options.fail?.({ - errCode: err.errCode, - errSubject: 'lime-choose-file' - }) - }, - complete(res) { - // options.complete?.(res) - } - }) - // #endif - // #ifdef MP-WEIXIN - uni.chooseMessageFile(options) - // #endif - // #ifndef WEB || MP-WEIXIN || APP-HARMONY - console.error('chooseFile 不支持该平台') - // #endif -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/interface.uts b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/interface.uts deleted file mode 100644 index 2f433ac..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/interface.uts +++ /dev/null @@ -1,108 +0,0 @@ -// @ts-nocheck -/** - * 错误码 - * 根据uni错误码规范要求,建议错误码以90开头,以下是错误码示例: - * - 9010001 错误信息1 - * - 9010002 错误信息2 - */ -export type ChooseFileErrorCode = 9010001 | 9010002 | 1101001 | 1101002 | 1101003 | 1101004 | 1101005 | 1101006 | 1101007 | 1101008 | 1101009 | 1101010; -/** - * myApi 的错误回调参数 - */ -export interface GeneralCallbackResult extends IUniError { - errCode : ChooseFileErrorCode -}; - - -/** 返回选择的文件的本地临时文件对象数组 */ -// #ifdef APP-ANDROID -export interface ChooseFile { - /** 选择的文件名称 */ - name : string - /** 本地临时文件路径 (本地路径) */ - path : string - /** 本地临时文件大小,单位 B */ - size : number - /** 选择的文件的会话发送时间,Unix时间戳,工具暂不支持此属性 */ - time : number - /** 选择的文件类型 - * - * 可选值: - * - 'video': 选择了视频文件; - * - 'image': 选择了图片文件; - * - 'file': 选择了除图片和视频的文件; */ - type : 'video' | 'image' | 'file' | 'all' -} -// #endif -// #ifndef APP-ANDROID -export type ChooseFile = { - /** 选择的文件名称 */ - name : string - /** 本地临时文件路径 (本地路径) */ - path : string - /** 本地临时文件大小,单位 B */ - size : number - /** 选择的文件的会话发送时间,Unix时间戳,工具暂不支持此属性 */ - time : number - /** 选择的文件类型 - * - * 可选值: - * - 'video': 选择了视频文件; - * - 'image': 选择了图片文件; - * - 'file': 选择了除图片和视频的文件; */ - type : 'video' | 'image' | 'file' | 'all' -} -// #endif - -export type ChooseFileSuccessCallbackResult = { - /** 返回选择的文件的本地临时文件对象数组 */ - tempFiles : ChooseFile[], - errMsg : string -} - - -/** 接口调用成功的回调函数 */ -export type ChooseFileSuccessCallback = ( - result : ChooseFileSuccessCallbackResult -) => void - -/** 接口调用失败的回调函数 */ -export type ChooseFileFailCallback = (res : GeneralCallbackResult) => void - -/** 接口调用结束的回调函数(调用成功、失败都会执行) */ -export type ChooseFileCompleteCallback = ( - res : GeneralCallbackResult -) => void - -export type ChooseFileOption = { - /** - * 指定文件名,如果是多选就在后面增加上时间 - */ - filename?: string - /** - * 最多可以选择的文件数量。 - * @defaultValue 100 - */ - count ?: number | null, - /** - * 所选文件类型 - * @defaultValue all - */ - type ?: string | null, - /** - * 根据文件拓展名过滤,每一项都不能是空字符串。默认不过滤。仅H5支持 - */ - extension ?: (string[]) | null, - /** - * 成功则返回图片的本地文件路径列表 tempFilePaths - */ - success ?: ChooseFileSuccessCallback | null, - /** - * 接口调用失败的回调函数 - */ - fail ?: ChooseFileFailCallback | null, - /** - * 接口调用结束的回调函数(调用成功、失败都会执行) - */ - complete ?: ChooseFileCompleteCallback | null -} \ No newline at end of file diff --git a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/unierror.uts b/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/unierror.uts deleted file mode 100644 index d6c2b73..0000000 --- a/unpackage/dist/build/app-plus/uni_modules/lime-choose-file/utssdk/unierror.uts +++ /dev/null @@ -1,40 +0,0 @@ -// @ts-nocheck -/* 此规范为 uni 规范,可以按照自己的需要选择是否实现 */ -import { ChooseFileErrorCode, GeneralCallbackResult } from "./interface.uts" -/** - * 错误主题 - * 注意:错误主题一般为插件名称,每个组件不同,需要使用时请更改。 - * [可选实现] - */ -export const UniErrorSubject = 'chooseFile"'; - - -/** - * 错误信息 - * @UniError - * [可选实现] - */ -export const UniErrors : Map = new Map([ - /** - * 错误码及对应的错误信息 - */ - [9010001, 'chooseFile:ok'], - [9010002, 'ChooseFile:failed'], -]); - - -/** - * 错误对象实现 - */ -export class GeneralCallbackResultImpl extends UniError implements GeneralCallbackResult { - - /** - * 错误对象构造函数 - */ - constructor(errCode : ChooseFileErrorCode, errMsg: string|null = null) { - super(); - this.errSubject = UniErrorSubject; - this.errCode = errCode; - this.errMsg = errMsg ?? UniErrors[errCode] ?? ""; - } -} \ No newline at end of file diff --git a/unpackage/dist/build/hx/app-plus/app-android/uts/uni_modules/lime-choose-file/manifest.json b/unpackage/dist/build/hx/app-plus/app-android/uts/uni_modules/lime-choose-file/manifest.json new file mode 100644 index 0000000..e42fee8 --- /dev/null +++ b/unpackage/dist/build/hx/app-plus/app-android/uts/uni_modules/lime-choose-file/manifest.json @@ -0,0 +1,32 @@ +{ + "version": "1", + "env": { + "compilerVersion": "5.07" + }, + "files": { + "utssdk/app-android/index.uts": { + "md5": "41a4e16dddeba7d4a58db6399cd86ee8" + }, + "utssdk/index.uts": { + "md5": "e6a6ba045e443b3a4973f9217894fa1c" + }, + "utssdk/interface.uts": { + "md5": "1b0ac84897039cfd08776b87e0c6582a" + }, + "utssdk/unierror.uts": { + "md5": "82736e70a9d5007436651a5d33897b4e" + }, + "package.json": { + "md5": "4d1ca74cea144db04520444b4216f76b" + }, + "readme copy.md": { + "md5": "6a3473bb03cb1f311be627c885b49dbe" + }, + "utssdk/app-android/AndroidManifest.xml": { + "md5": "e7b416d035a0a308cd13eba12b2db438" + }, + "utssdk/app-android/config.json": { + "md5": "49e34dad9b85d9ddf183e599555456fa" + } + } +} \ No newline at end of file diff --git a/unpackage/dist/dev/.sourcemap/app/uni_modules/lime-choose-file/utssdk/app-android/index.kt.map b/unpackage/dist/dev/.sourcemap/app/uni_modules/lime-choose-file/utssdk/app-android/index.kt.map new file mode 100644 index 0000000..27c2988 --- /dev/null +++ b/unpackage/dist/dev/.sourcemap/app/uni_modules/lime-choose-file/utssdk/app-android/index.kt.map @@ -0,0 +1 @@ +{"version":3,"sources":["uni_modules/lime-choose-file/utssdk/app-android/index.uts","uni_modules/lime-choose-file/utssdk/interface.uts","uni_modules/lime-choose-file/utssdk/unierror.uts"],"sourcesContent":["// @ts-nocheck\r\nimport Intent from 'android.content.Intent';\r\nimport ClipData from 'android.content.ClipData';\r\nimport Uri from 'android.net.Uri';\r\nimport InputStream from 'java.io.InputStream';\r\nimport OpenableColumns from 'android.provider.OpenableColumns';\r\nimport Cursor from 'android.database.Cursor';\r\nimport File from 'java.io.File';\r\nimport FileInputStream from 'java.io.FileInputStream';\r\nimport FileOutputStream from 'java.io.FileOutputStream';\r\nimport BufferedOutputStream from 'java.io.BufferedOutputStream';\r\nimport ByteArrayInputStream from 'java.io.ByteArrayInputStream';\r\n\r\nimport { ChooseFileOption, ChooseFile, ChooseFileSuccessCallbackResult } from '../interface'\r\nimport { GeneralCallbackResultImpl } from '../unierror'\r\n\r\nconst REQUEST_CODE_CHOOSE_FILE : Int = 42\r\nlet resultFunction : ((requestCode : Int, resultCode : Int, data ?: Intent) => void) | null = null\r\n\r\n\r\nclass ChooseFileImpl implements ChooseFile {\r\n\tname : string = ''\r\n\tpath : string = ''\r\n\t// private _path : string = ''\r\n\tsize : number = 0\r\n\ttime : number = 0\r\n\ttype : string = 'file'\r\n\t// private uri : Uri \r\n\tprivate options: ChooseFileOption\r\n\tconstructor(uri : Uri, options : ChooseFileOption) {\r\n\t\t// this.uri = uri\r\n\t\tthis.options = options\r\n\t\tthis.time = Date.now()\r\n\t\tthis.type = this.getFileTypeFromUri(uri);\r\n\t\t// this._path = uri.getPath() ?? ''\r\n\t\tthis.getFileInfoFromUri(uri)\r\n\t\tif (this.isCache(options)) {\r\n\t\t\tthis.copyFileToCache(uri)\r\n\t\t}\r\n\r\n\t}\r\n\tprivate isCache(options : ChooseFileOption) : boolean {\r\n\t\tconst extension = this.getFileExtension(this.name)\r\n\t\tconst extensions = options.extension\r\n\t\tconst type = options.type ?? 'all'\r\n\t\tconst hasExtension = extensions != null && extension != '' && extensions.includes(extension)\r\n\t\tconst isVideoOrImage = ['video', 'image'].includes(type)\r\n\t\tconst isFileAndNotVideoOrImage = type == 'file' && !['video', 'image'].includes(this.type);\r\n\t\tif ((type == 'all' || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) {\r\n\t\t\treturn true\r\n\t\t} else {\r\n\t\t\treturn false\r\n\t\t}\r\n\t}\r\n\tprivate getFileExtension(fileName : string) : string {\r\n\t\tconst lastDotIndex = fileName.lastIndexOf(\".\");\r\n\t\tif (lastDotIndex == -1) {\r\n\t\t\treturn \"\";\r\n\t\t}\r\n\t\treturn fileName.substring(lastDotIndex + 1);\r\n\t}\r\n\tprivate copyFileToCache(uri : Uri) {\r\n\t\tconst cacheDir = UTSAndroid.getAppCachePath();\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tif(cacheDir != null) {\r\n\t\t\tconst path = new File(cacheDir); \r\n\t\t\tif (!path.exists()) { \r\n\t\t\t\tpath.mkdir(); \r\n\t\t\t}\r\n\t\t}\r\n\t\tlet fileName = this.name\r\n\t\tif(this.options.filename != null) {\r\n\t\t\tfileName = this.options.filename!;\r\n\t\t\tif(this.options.count != null && this.options.count! > 1) {\r\n\t\t\t\tfileName = `${fileName}_${Date.now()}`;\r\n\t\t\t}\r\n\t\t\tconst extension = this.getFileExtension(this.name)\r\n\t\t\t\r\n\t\t\tfileName = `${fileName}.${extension}`\r\n\t\t}\r\n\t\tconst destFile = new File(cacheDir, fileName);\r\n\t\t\r\n\t\ttry {\r\n\t\t\tconst inputStream = context!.getContentResolver().openInputStream(uri)\r\n\t\t\tconst outputStream = new FileOutputStream(destFile)\r\n\t\t\tif (inputStream != null) {\r\n\t\t\t\tlet buffer = ByteArray(1024);\r\n\t\t\t\tlet c = inputStream.read(buffer)\r\n\t\t\t\twhile (c > 0) {\r\n\t\t\t\t\toutputStream.write(buffer, 0, c);\r\n\t\t\t\t\tc = inputStream.read(buffer)\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tthis.path = cacheDir + fileName//this.name\r\n\t\t} catch (e) {\r\n\t\t\t\r\n\t\t}\r\n\t}\r\n\tprivate getFileTypeFromUri(uri : Uri) : string {\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tlet fileType = 'file'\r\n\t\tlet mimeType = context!.getContentResolver().getType(uri);\r\n\t\tif (mimeType != null) {\r\n\t\t\tif (mimeType.startsWith(\"video\")) {\r\n\t\t\t\tfileType = \"video\";\r\n\t\t\t} else if (mimeType.startsWith(\"image\")) {\r\n\t\t\t\tfileType = \"image\";\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn fileType;\r\n\t}\r\n\tprivate getFileInfoFromUri(uri : Uri) {\r\n\t\tconst context = UTSAndroid.getAppContext();\r\n\t\tlet cursor = context!.getContentResolver().query(uri, null, null, null, null);\r\n\t\tif (cursor != null && cursor.moveToFirst()) {\r\n\t\t\tthis.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME))\r\n\t\t\tconst fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE));\r\n\t\t\tthis.size = Number.from(fileSize)\r\n\t\t\tcursor.close();\r\n\t\t} else if (\"file\".equals(uri.getScheme())) {\r\n\t\t\tthis.name = uri.getLastPathSegment() ?? '';\r\n\t\t\tconst file = new File(uri.getPath() ?? '');\r\n\t\t\tconst fileSize = file.length();\r\n\t\t\tthis.size = Number.from(fileSize)\r\n\t\t}\r\n\t}\r\n}\r\n\r\n\r\nexport function chooseFile(options : ChooseFileOption) {\r\n\tif (resultFunction != null) {\r\n\t\tUTSAndroid.offAppActivityResult(resultFunction!)\r\n\t}\r\n\tconst type = options.type ?? 'all'\r\n\tconst intent = new Intent(Intent.ACTION_GET_CONTENT);\r\n\tif (type.equals(\"all\") || type.equals(\"file\")) {\r\n\t\tintent.setType(\"*/*\");\r\n\t} else if (type.equals(\"video\")) {\r\n\t\tintent.setType(\"video/*\");\r\n\t} else if (type.equals(\"image\")) {\r\n\t\tintent.setType(\"image/*\");\r\n\t}\r\n\tintent.addCategory(Intent.CATEGORY_OPENABLE);\r\n\tintent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, options.count == 1 ? false : true); // 允许多选\r\n\r\n\tresultFunction = (requestCode : Int, resultCode : Int, data ?: Intent) => {\r\n\t\tif (requestCode == REQUEST_CODE_CHOOSE_FILE) {\r\n\t\t\tUTSAndroid.offAppActivityResult(resultFunction!);\r\n\t\t\tif (resultCode == -1 && data != null) {\r\n\t\t\t\tconst clipData = data.getClipData();\r\n\t\t\t\tconst tempFiles : ChooseFile[] = []\r\n\t\t\t\t\r\n\t\t\t\tif (clipData != null) {\r\n\t\t\t\t\t// 多选\r\n\t\t\t\t\t// const itemCount = clipData.getItemCount();\r\n\t\t\t\t\t// if (options.count != null && options.count! > itemCount) {\r\n\t\t\t\t\t// \tconst err = new GeneralCallbackResultImpl(9010002, `选中文件数量超过${options.count}`)\r\n\t\t\t\t\t// \toptions.fail?.(err)\r\n\t\t\t\t\t// \toptions.complete?.(err)\r\n\t\t\t\t\t// \treturn\r\n\t\t\t\t\t// }\r\n\t\t\t\t\tfor (let i = 0; i < clipData.getItemCount(); i++) {\r\n\t\t\t\t\t\tconst uri = clipData.getItemAt(i.toInt()).getUri();\r\n\t\t\t\t\t\tconst chooseFile = new ChooseFileImpl(uri, options);\r\n\t\t\t\t\t\tif(chooseFile.path !=''){\r\n\t\t\t\t\t\t\ttempFiles.push(chooseFile)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\t// 单选\r\n\t\t\t\t\tconst uri = data.getData();\r\n\t\t\t\t\tif (uri != null) {\r\n\t\t\t\t\t\tconst chooseFile = new ChooseFileImpl(uri, options)\r\n\t\t\t\t\t\tif(chooseFile.path !='' ){\r\n\t\t\t\t\t\t\ttempFiles.push(chooseFile)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\tconst count = options.count ?? Integer.MAX_VALUE // Number.MAX_VALUE\r\n\t\t\t\tif(tempFiles.length > 0 && count >= tempFiles.length){\r\n\t\t\t\t\toptions.success?.({\r\n\t\t\t\t\t\ttempFiles,\r\n\t\t\t\t\t\terrMsg: 'chooseFile:ok'\r\n\t\t\t\t\t} as ChooseFileSuccessCallbackResult)\r\n\t\t\t\t} else {\r\n\t\t\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件或文件超过设置数量`)\r\n\t\t\t\t\toptions.fail?.(err)\r\n\t\t\t\t\toptions.complete?.(err)\r\n\t\t\t\t}\r\n\t\t\t} else {\r\n\t\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`)\r\n\t\t\t\toptions.fail?.(err)\r\n\t\t\t\toptions.complete?.(err)\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tconst err = new GeneralCallbackResultImpl(9010002, `没有可用的文件`)\r\n\t\t\toptions.fail?.(err)\r\n\t\t\toptions.complete?.(err)\r\n\t\t}\r\n\t}\r\n\r\n\tUTSAndroid.onAppActivityResult(resultFunction!)\r\n\tUTSAndroid.getUniActivity()!.startActivityForResult(Intent.createChooser(intent, \"选择文件\"), REQUEST_CODE_CHOOSE_FILE)\r\n\t// UTSAndroid.getUniActivity()!.overridePendingTransition((10).toInt(), (0).toInt());\r\n}","// @ts-nocheck\r\n/**\r\n * 错误码\r\n * 根据uni错误码规范要求,建议错误码以90开头,以下是错误码示例:\r\n * - 9010001 错误信息1\r\n * - 9010002 错误信息2\r\n */\r\nexport type ChooseFileErrorCode = 9010001 | 9010002 | 1101001 | 1101002 | 1101003 | 1101004 | 1101005 | 1101006 | 1101007 | 1101008 | 1101009 | 1101010;\r\n/**\r\n * myApi 的错误回调参数\r\n */\r\nexport interface GeneralCallbackResult extends IUniError {\r\n\terrCode : ChooseFileErrorCode\r\n};\r\n\r\n\r\n/** 返回选择的文件的本地临时文件对象数组 */\r\n\r\nexport interface ChooseFile {\r\n\t/** 选择的文件名称 */\r\n\tname : string\r\n\t/** 本地临时文件路径 (本地路径) */\r\n\tpath : string\r\n\t/** 本地临时文件大小,单位 B */\r\n\tsize : number\r\n\t/** 选择的文件的会话发送时间,Unix时间戳,工具暂不支持此属性 */\r\n\ttime : number\r\n\t/** 选择的文件类型\r\n\t *\r\n\t * 可选值:\r\n\t * - 'video': 选择了视频文件;\r\n\t * - 'image': 选择了图片文件;\r\n\t * - 'file': 选择了除图片和视频的文件; */\r\n\ttype : 'video' | 'image' | 'file' | 'all'\r\n}\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\n\r\nexport type ChooseFileSuccessCallbackResult = {\r\n\t/** 返回选择的文件的本地临时文件对象数组 */\r\n\ttempFiles : ChooseFile[],\r\n\terrMsg : string\r\n}\r\n\r\n\r\n/** 接口调用成功的回调函数 */\r\nexport type ChooseFileSuccessCallback = (\r\n\tresult : ChooseFileSuccessCallbackResult\r\n) => void\r\n\r\n/** 接口调用失败的回调函数 */\r\nexport type ChooseFileFailCallback = (res : GeneralCallbackResult) => void\r\n\r\n/** 接口调用结束的回调函数(调用成功、失败都会执行) */\r\nexport type ChooseFileCompleteCallback = (\r\n\tres : GeneralCallbackResult\r\n) => void\r\n\r\nexport type ChooseFileOption = {\r\n\t/**\r\n\t * 指定文件名,如果是多选就在后面增加上时间\r\n\t */\r\n\tfilename?: string\r\n\t/**\r\n\t * 最多可以选择的文件数量。\r\n\t * @defaultValue 100\r\n\t */\r\n\tcount ?: number | null,\r\n\t/**\r\n\t * 所选文件类型\r\n\t * @defaultValue all\r\n\t */\r\n\ttype ?: string | null,\r\n\t/**\r\n\t * 根据文件拓展名过滤,每一项都不能是空字符串。默认不过滤。仅H5支持\r\n\t */\r\n\textension ?: (string[]) | null,\r\n\t/**\r\n\t * 成功则返回图片的本地文件路径列表 tempFilePaths\r\n\t */\r\n\tsuccess ?: ChooseFileSuccessCallback | null,\r\n\t/**\r\n\t * 接口调用失败的回调函数\r\n\t */\r\n\tfail ?: ChooseFileFailCallback | null,\r\n\t/**\r\n\t * 接口调用结束的回调函数(调用成功、失败都会执行)\r\n\t */\r\n\tcomplete ?: ChooseFileCompleteCallback | null\r\n}","// @ts-nocheck\r\n/* 此规范为 uni 规范,可以按照自己的需要选择是否实现 */\r\nimport { ChooseFileErrorCode, GeneralCallbackResult } from \"./interface.uts\"\r\n/**\r\n * 错误主题\r\n * 注意:错误主题一般为插件名称,每个组件不同,需要使用时请更改。\r\n * [可选实现]\r\n */\r\nexport const UniErrorSubject = 'chooseFile\"';\r\n\r\n\r\n/**\r\n * 错误信息\r\n * @UniError\r\n * [可选实现]\r\n */\r\nexport const UniErrors : Map = new Map([\r\n /**\r\n * 错误码及对应的错误信息\r\n */\r\n [9010001, 'chooseFile:ok'],\r\n [9010002, 'ChooseFile:failed'],\r\n]);\r\n\r\n\r\n/**\r\n * 错误对象实现\r\n */\r\nexport class GeneralCallbackResultImpl extends UniError implements GeneralCallbackResult {\r\n\r\n /**\r\n * 错误对象构造函数\r\n */\r\n constructor(errCode : ChooseFileErrorCode, errMsg: string|null = null) {\r\n super();\r\n this.errSubject = UniErrorSubject;\r\n this.errCode = errCode;\r\n this.errMsg = errMsg ?? UniErrors[errCode] ?? \"\";\r\n }\r\n}"],"names":[],"mappings":";;AACA,OAAmB,sBAAwB,AAAC;AAE5C,OAAgB,eAAiB,AAAC;AAElC,OAA4B,gCAAkC,AAAC;;;;;;;;AAE/D,OAAiB,YAAc,AAAC;AAEhC,OAA6B,wBAA0B,AAAC;;;;;;UCF5C,sBAAsB,MAAO;AAInC,SAEL,CAFgB,wBAA8B;aAC9C,GAA6B,CAA7B,SAAU;;AAML,SAgBL,CAhBgB;IAEhB,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAEb,GAAa,CAAb,MAAO,MAAM;IAOb,GAAyC,CAAzC,MAAO,MAAO;;AAuB+B,WAAlC;IAEX;aAAA,oBAAY,YAAa;IACzB;aAAA,QAAS,MAAM,CAAA;;;;;;UAKJ,6BACX,QAAS,oCACL,IAAI;UAGG,0BAA0B,KAAM,0BAA0B,IAAI;UAG9D,8BACX,KAAM,0BACF,IAAI;AAEsB,WAAnB;IAIX,SAAA,UAAW,MAAM,SAAA;IAKjB,SAAA,OAAS,MAAM,SAAQ;IAKvB,SAAA,MAAQ,MAAM,SAAQ;IAItB,SAAA,oBAAc,MAAM,UAAW;IAI/B,SAAA,SAAW,kCAAiC;IAI5C,SAAA,MAAQ,+BAA8B;IAItC,SAAA,UAAY,mCAAiC;;;;;;AClGvC,IAAM,kBAAkB;AAQxB,IAAM,WAAY,uBAAI,CAAmB,CAAE,MAAM,IAAI,AAAI,IAAI;IAIlE;AAAC,eAAO,AAAP,CAAO;QAAE;KAAgB,AAA1B,CAA0B;IAC1B;AAAC,eAAO,AAAP,CAAO;QAAE;KAAoB;CAC/B;AAMK,WAAO,4BAAkC,+BAAoB,CAAqB;;;;IAKtF,YAAY,4BAA6B,AAA7B,CAA6B,CAAE,QAAQ,MAAM,IAAQ,IAAI,IACnE,KAAK,GAD8D;QAEnE,IAAI,CAAC,UAAU,GAAG;QAClB,IAAI,CAAC,OAAO,GAAG;QACf,IAAI,CAAC,MAAM,GAAG,OAAM,EAAA,CAAI,SAAS,CAAC,QAAQ,CAAA,EAAA,CAAI;IAChD;;AFtBF,IAAM,0BAA2B,MAAM,EAAE;AACzC,IAAI,kBAAmB,aAAc,GAAd,CAAiB,CAAE,YAAa,GAAb,CAAgB,CAAE,MAAQ,YAAW,IAAI,KAAW,IAAI;AAGlG,WAAM,2BAA0B,CAAU;;;;IACzC,aAAA,MAAO,MAAM,GAAG,EAAE;IAClB,aAAA,MAAO,MAAM,GAAG,EAAE;IAElB,aAAA,MAAO,MAAM,GAAG,CAAC;IACjB,aAAA,MAAO,MAAM,GAAG,CAAC;IACjB,aAAA,MAAO,MAAM,GAAG,MAAM;IAEtB,YAAQ,yBAAyB;IACjC,YAAY,KAAM,GAAG,AAAT,CAAS,CAAE,yBAA0B,CAAA;QAEhD,IAAI,CAAC,OAAO,GAAG;QACf,IAAI,CAAC,IAAI,GAAG,KAAK,GAAG;QACpB,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC,kBAAkB,CAAC;QAEpC,IAAI,CAAC,kBAAkB,CAAC;QACxB,IAAI,IAAI,CAAC,OAAO,CAAC,UAAU;YAC1B,IAAI,CAAC,eAAe,CAAC;;IAGvB;IACA,YAAQ,QAAQ,yBAA0B,GAAI,OAAO,CAAA;QACpD,IAAM,YAAY,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI;QACjD,IAAM,aAAa,QAAQ,SAAS;QACpC,IAAM,OAAO,QAAQ,IAAI,CAAA,EAAA,CAAI;QAC7B,IAAM,eAAe,WAAU,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,UAAS,EAAA,CAAI,GAAE,EAAA,CAAI,WAAW,QAAQ,CAAC;QAClF,IAAM,iBAAiB;YAAC,OAAA,CAAO;YAAE;SAAQ,CAAC,QAAQ,CAAC;QACnD,IAAM,2BAA2B,KAAI,EAAA,CAAI,OAAM,EAAA,CAAI,CAAC;YAAC,OAAA,CAAO;YAAE;SAAQ,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI;QACzF,IAAI,CAAC,KAAI,EAAA,CAAI,MAAK,EAAA,CAAI,eAAc,EAAA,CAAI,wBAAwB,EAAC,EAAA,CAAI,CAAC,cAAc;YACnF,OAAO,IAAI;UACL,IAEN,CAFM;YACN,OAAO,KAAK;;IAEd;IACA,YAAQ,iBAAiB,UAAW,MAAM,GAAI,MAAM,CAAA;QACnD,IAAM,eAAe,SAAS,WAAW,CAAC;QAC1C,IAAI,aAAY,EAAA,CAAI,CAAC,CAAC,EAAE;YACvB,OAAO;;QAER,OAAO,SAAS,SAAS,CAAC,aAAY,CAAA,CAAG,CAAC;IAC3C;IACA,YAAQ,gBAAgB,KAAM,GAAG,EAAA;QAChC,IAAM,WAAW,WAAW,eAAe;QAC3C,IAAM,UAAU,WAAW,aAAa;QACxC,IAAG,SAAQ,EAAA,CAAI,IAAI,EAAE;YACpB,IAAM,OAAO,AAAI,KAAK;YACtB,IAAI,CAAC,KAAK,MAAM,IAAI;gBACnB,KAAK,KAAK;;;QAGZ,IAAI,WAAW,IAAI,CAAC,IAAI;QACxB,IAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAA,EAAA,CAAI,IAAI,EAAE;YACjC,WAAW,IAAI,CAAC,OAAO,CAAC,QAAQ;YAChC,IAAG,IAAI,CAAC,OAAO,CAAC,KAAK,CAAA,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,IAAI,CAAC,OAAO,CAAC,KAAK,GAAC,CAAA,CAAG,CAAC,EAAE;gBACzD,WAAW,KAAG,WAAQ,MAAI,KAAK,GAAG;;YAEnC,IAAM,YAAY,IAAI,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI;YAEjD,WAAW,KAAG,WAAQ,MAAI;;QAE3B,IAAM,WAAW,AAAI,KAAK,QAAA,CAAQ,CAAE;QAEpC,IAAI;YACH,IAAM,cAAc,UAAS,kBAAkB,GAAG,eAAe,CAAC;YAClE,IAAM,eAAe,AAAI,iBAAiB;YAC1C,IAAI,YAAW,EAAA,CAAI,IAAI,EAAE;gBACxB,IAAI,SAAS,UAAU,IAAI;gBAC3B,IAAI,IAAI,YAAY,IAAI,CAAC;gBACzB,MAAO,EAAC,CAAA,CAAG,CAAC,CAAE;oBACb,aAAa,KAAK,CAAC,MAAA,CAAM,CAAE,CAAC,AAAD,CAAC,CAAE;oBAC9B,IAAI,YAAY,IAAI,CAAC;;;YAGvB,IAAI,CAAC,IAAI,GAAG,SAAQ,CAAA,CAAG;;SACtB,OAAO,cAAG;IAGb;IACA,YAAQ,mBAAmB,KAAM,GAAG,GAAI,MAAM,CAAA;QAC7C,IAAM,UAAU,WAAW,aAAa;QACxC,IAAI,WAAW;QACf,IAAI,WAAW,UAAS,kBAAkB,GAAG,OAAO,CAAC;QACrD,IAAI,SAAQ,EAAA,CAAI,IAAI,EAAE;YACrB,IAAI,SAAS,UAAU,CAAC,UAAU;gBACjC,WAAW;cACL,IAEN,CAFM,IAAI,SAAS,UAAU,CAAC,UAAU;gBACxC,WAAW;;;QAGb,OAAO;IACR;IACA,YAAQ,mBAAmB,KAAM,GAAG,EAAA;QACnC,IAAM,UAAU,WAAW,aAAa;QACxC,IAAI,SAAS,UAAS,kBAAkB,GAAG,KAAK,CAAC,GAAA,CAAG,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI,AAAJ,CAAI,CAAE,IAAI;QAC5E,IAAI,OAAM,EAAA,CAAI,IAAI,CAAA,EAAA,CAAI,OAAO,WAAW,IAAI;YAC3C,IAAI,CAAC,IAAI,GAAG,OAAO,SAAS,CAAC,OAAO,qBAAqB,CAAC,gBAAgB,YAAY;YACtF,IAAM,WAAW,OAAO,OAAO,CAAC,OAAO,qBAAqB,CAAC,gBAAgB,IAAI;YACjF,IAAI,CAAC,IAAI,GAAG,UAAO,IAAI,CAAC;YACxB,OAAO,KAAK;UACN,IAKN,CALM,IAAI,OAAO,MAAM,CAAC,IAAI,SAAS,KAAK;YAC1C,IAAI,CAAC,IAAI,GAAG,IAAI,kBAAkB,GAAE,EAAA,CAAI;YACxC,IAAM,OAAO,AAAI,KAAK,IAAI,OAAO,GAAE,EAAA,CAAI;YACvC,IAAM,WAAW,KAAK,MAAM;YAC5B,IAAI,CAAC,IAAI,GAAG,UAAO,IAAI,CAAC;;IAE1B;;AAIK,IAAU,WAAW,yBAA0B,EAAA;IACpD,IAAI,eAAc,EAAA,CAAI,IAAI,EAAE;QAC3B,WAAW,oBAAoB,CAAC;;IAEjC,IAAM,OAAO,QAAQ,IAAI,CAAA,EAAA,CAAI;IAC7B,IAAM,SAAS,AAAI,OAAO,OAAO,kBAAkB;IACnD,IAAI,KAAK,MAAM,CAAC,OAAM,EAAA,CAAI,KAAK,MAAM,CAAC,SAAS;QAC9C,OAAO,OAAO,CAAC;MACT,IAIN,CAJM,IAAI,KAAK,MAAM,CAAC,UAAU;QAChC,OAAO,OAAO,CAAC;MACT,IAEN,CAFM,IAAI,KAAK,MAAM,CAAC,UAAU;QAChC,OAAO,OAAO,CAAC;;IAEhB,OAAO,WAAW,CAAC,OAAO,iBAAiB;IAC3C,OAAO,QAAQ,CAAC,OAAO,oBAAoB,AAA3B,CAA2B,CAAE,IAAA,QAAQ,KAAK,CAAA,EAAA,CAAI,CAAC,EAAG;QAAA,KAAK;IAAL,EAAQ,IAAI,CAAJ;QAAA,IAAI;IAAJ;IAAI;IAE9E,iBAAiB,IAAC,aAAc,GAAd,CAAiB,CAAE,YAAa,GAAb,CAAgB,CAAE,MAAQ,QAAU;QACxE,IAAI,YAAW,EAAA,CAAI,0BAA0B;YAC5C,WAAW,oBAAoB,CAAC;YAChC,IAAI,WAAU,EAAA,CAAI,CAAC,CAAC,CAAA,EAAA,CAAI,KAAI,EAAA,CAAI,IAAI,EAAE;gBACrC,IAAM,WAAW,KAAK,WAAW;gBACjC,IAAM,kCAA2B,KAAE;gBAEnC,IAAI,SAAQ,EAAA,CAAI,IAAI,EAAE;wBASrB;wBAAK,IAAI,YAAI,CAAC;wBAAd,MAAgB,EAAC,CAAA,CAAG,SAAS,YAAY;4BACxC,IAAM,MAAM,SAAS,SAAS,CAAC,EAAE,KAAK,IAAI,MAAM;4BAChD,IAAM,aAAa,AAAI,eAAe,GAAA,CAAG,CAAE;4BAC3C,IAAG,WAAW,IAAI,CAAA,EAAA,CAAG,IAAG;gCACvB,UAAU,IAAI,CAAC;;4BAJ4B;;;kBAOvC,IAUN,CAVM;oBAEN,IAAM,MAAM,KAAK,OAAO;oBACxB,IAAI,IAAG,EAAA,CAAI,IAAI,EAAE;wBAChB,IAAM,aAAa,AAAI,eAAe,GAAA,CAAG,CAAE;wBAC3C,IAAG,WAAW,IAAI,CAAA,EAAA,CAAG,IAAI;4BACxB,UAAU,IAAI,CAAC;;;iBAIjB;gBACD,IAAM,QAAQ,QAAQ,KAAK,CAAA,EAAA,CAAI,QAAQ,SAAS;gBAChD,IAAG,UAAU,MAAM,CAAA,CAAA,CAAG,CAAC,CAAA,EAAA,CAAI,MAAK,EAAA,CAAI,UAAU,MAAM,EAAC;oBACpD,QAAQ,OAAO,SAGV,gCAFJ,YAAA,WACA,SAAQ;kBAEH,IAIN,CAJM;oBACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;oBACnD,QAAQ,IAAI,SAAG;oBACf,QAAQ,QAAQ,SAAG;iBACnB;cACK,IAIN,CAJM;gBACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;gBACnD,QAAQ,IAAI,SAAG;gBACf,QAAQ,QAAQ,SAAG;aACnB;UACK,IAIN,CAJM;YACN,IAAM,MAAM,0BAA8B,OAAO,AAAP,CAAO,CAAE;YACnD,QAAQ,IAAI,SAAG;YACf,QAAQ,QAAQ,SAAG;;IAErB;IAEA,WAAW,mBAAmB,CAAC;IAC/B,WAAW,cAAc,KAAI,sBAAsB,CAAC,OAAO,aAAa,CAAC,MAAA,CAAM,CAAE,OAA7B,CAAoC,CAAE;AAE3F;ACjI+B;IAI9B,SAAA,UAAW,MAAM,QAAA;IAKjB,SAAA,OAAS,MAAM,QAAQ;IAKvB,SAAA,MAAQ,MAAM,QAAQ;IAItB,SAAA,oBAAc,MAAM,SAAW;IAI/B,SAAA,SAAS,mBAAmC;IAI5C,SAAA,MAAM,mBAAgC;IAItC,SAAA,UAAU,mBAAmC;;mBDuBnB,mCAA0B;6JChEpD,QAAS,kCACL,IAAI;gCADR;;iBAIqC,KAAM,wBAA0B,IAAI;6BAApC;;qBAIrC,KAAM,wBACF,IAAI;iCADR"} \ No newline at end of file diff --git a/unpackage/dist/dev/app-plus/app-config-service.js b/unpackage/dist/dev/app-plus/app-config-service.js index 010c1d8..84270da 100644 --- a/unpackage/dist/dev/app-plus/app-config-service.js +++ b/unpackage/dist/dev/app-plus/app-config-service.js @@ -2,7 +2,7 @@ ;(function(){ let u=void 0,isReady=false,onReadyCallbacks=[],isServiceReady=false,onServiceReadyCallbacks=[]; const __uniConfig = {"pages":[],"globalStyle":{"backgroundColor":"#F8F8F8","navigationBar":{"backgroundColor":"#F8F8F8","titleText":"uni-app","type":"default","titleColor":"#000000"},"isNVue":false},"nvue":{"compiler":"uni-app","styleCompiler":"uni-app","flex-direction":"column"},"renderer":"auto","appname":"test1","splashscreen":{"alwaysShowBeforeRender":true,"autoclose":true},"compilerVersion":"5.07","entryPagePath":"pages/Login/Login","entryPageQuery":"","realEntryPagePath":"","networkTimeout":{"request":60000,"connectSocket":60000,"uploadFile":60000,"downloadFile":60000},"locales":{},"darkmode":false,"themeConfig":{}}; - const __uniRoutes = [{"path":"pages/Login/Login","meta":{"isQuit":true,"isEntry":true,"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"登录页面","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/Chat/Chat","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"聊天页面(主页面)","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/WorkSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"工作区文件管理","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/UserProfileModal/UserProfileModal","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/ContactPages/ContactPages","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/TemplateSpace/TemplateSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/text/text","meta":{"navigationBar":{"titleText":"","type":"default"},"isNVue":false}},{"path":"pages/text/text2","meta":{"navigationBar":{"type":"default"},"isNVue":false}},{"path":"pages/CloudDatabase/CloudDatabase","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"云端数据","style":"custom","type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute)); + const __uniRoutes = [{"path":"pages/Login/Login","meta":{"isQuit":true,"isEntry":true,"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"登录页面","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/Chat/Chat","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"聊天页面(主页面)","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/WorkSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"工作区文件管理","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/UserProfileModal/UserProfileModal","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/ContactPages/ContactPages","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/WorkSpace/TemplateSpace/TemplateSpace","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/text/text","meta":{"navigationBar":{"titleText":"","type":"default"},"isNVue":false}},{"path":"pages/text/text2","meta":{"navigationBar":{"type":"default"},"isNVue":false}},{"path":"pages/CloudDatabase/CloudDatabase","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"云端数据","style":"custom","type":"default"},"isNVue":false}},{"path":"pages/CloudDbDetail/CloudDbDetail","meta":{"titleNView":false,"bounce":"none","softinputMode":"adjustResize","navigationBar":{"titleText":"数据库详情","style":"custom","type":"default"},"isNVue":false}}].map(uniRoute=>(uniRoute.meta.route=uniRoute.path,__uniConfig.pages.push(uniRoute.path),uniRoute.path='/'+uniRoute.path,uniRoute)); __uniConfig.styles=[];//styles __uniConfig.onReady=function(callback){if(__uniConfig.ready){callback()}else{onReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"ready",{get:function(){return isReady},set:function(val){isReady=val;if(!isReady){return}const callbacks=onReadyCallbacks.slice(0);onReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}}); __uniConfig.onServiceReady=function(callback){if(__uniConfig.serviceReady){callback()}else{onServiceReadyCallbacks.push(callback)}};Object.defineProperty(__uniConfig,"serviceReady",{get:function(){return isServiceReady},set:function(val){isServiceReady=val;if(!isServiceReady){return}const callbacks=onServiceReadyCallbacks.slice(0);onServiceReadyCallbacks.length=0;callbacks.forEach(function(callback){callback()})}}); diff --git a/unpackage/dist/dev/app-plus/app-service.js b/unpackage/dist/dev/app-plus/app-service.js index a2bec02..43f754c 100644 --- a/unpackage/dist/dev/app-plus/app-service.js +++ b/unpackage/dist/dev/app-plus/app-service.js @@ -498,6 +498,122 @@ if (uni.restoreGlobal) { }); }); }; + const workspaceUploadFileByURL = (token, workspacesId, urls, dirPath) => { + return new Promise((resolve, reject) => { + const urlList = Array.isArray(urls) ? urls : urls ? [urls] : []; + uni.request({ + url: `${BASE_URL}/cloud_api/phone/workspace/upload`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token, + "workspaces_id": workspacesId, + "dir_path": dirPath || "/", + "urls": urlList + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond); + } else { + const failedItems = (respond.results || []).filter((r2) => !r2.success).map((r2) => r2.error || "未知错误"); + const msg = failedItems.length > 0 ? `上传失败 ${respond.failed_count}/${respond.total_files}:${failedItems[0]}` : respond.summary || (respond == null ? void 0 : respond.error) || "上传文件到工作区出错啦"; + reject(msg); + } + } else { + reject(`上传文件到工作区失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const uploadFileToShortStorage = (workspacesId, files, filePath) => { + return new Promise((resolve, reject) => { + const fileList = Array.isArray(files) ? files : [files]; + const uploadFiles = fileList.map((file) => { + const fileUri = typeof file === "string" ? file : file.tempFilePath || file.path || file; + return { + name: "files", + uri: fileUri + }; + }); + formatAppLog("log", "at utils/cloud-api.js:587", "uploadFileToShortStorage 参数:", { workspacesId, fileCount: uploadFiles.length, filePath }); + uni.uploadFile({ + url: `${BASE_URL}/cloud_api/file/temp/upload`, + method: "POST", + formData: { + workspaces_id: workspacesId, + file_path: filePath || "/", + overwrite: "true" + }, + files: uploadFiles, + success: (res) => { + formatAppLog("log", "at utils/cloud-api.js:599", "uploadFileToShortStorage 响应状态:", res.statusCode, "数据:", res.data); + if (res.statusCode === 200) { + try { + const respond = JSON.parse(res.data); + if (Array.isArray(respond) && respond.length > 0) { + resolve(respond); + } else if (respond.success) { + resolve([{ url: respond.url || respond.message, success: true }]); + } else { + const msg = (respond == null ? void 0 : respond.error) || (respond == null ? void 0 : respond.message) || "上传文件(到短存云端)获取URL出错啦"; + reject(msg); + } + } catch (e2) { + reject("接口返回数据格式异常: " + res.data); + } + } else { + reject(`上传文件(到短存云端)获取URL失败:${res.statusCode} - ${res.data}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const updateWorkspaceFileName = (token, workspacesId, oldPath, newName) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/workspace/file/rename`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "workspaces_id": workspacesId, + "file_path": oldPath, + "new_name": newName + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.message || respond); + } else { + const msg = (respond == null ? void 0 : respond.error) || "重命名工作区文件出错啦"; + reject(msg); + } + } else { + reject(`重命名工作区文件失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; const updateUserInfo = (token, userId, username, email, avatarURL) => { return new Promise((resolve, reject) => { uni.request({ @@ -908,6 +1024,478 @@ if (uni.restoreGlobal) { }); }); }; + const getCloudDbList = (token) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/list`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.databases); + } else { + const msg = (respond == null ? void 0 : respond.error) || "获取用户可访问的数据库列表出错啦"; + reject(msg); + } + } else { + reject(`获取用户可访问的数据库列表失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const createCloudDb = (token, databaseName) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/create`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token, + "database_name": databaseName + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.message); + } else { + const msg = (respond == null ? void 0 : respond.error) || "创建数据库出错啦"; + reject(msg); + } + } else { + reject(`创建数据库失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const uploadCloudDbFile = (token, filePath) => { + return new Promise((resolve, reject) => { + const fileUri = typeof filePath === "string" ? filePath : filePath.tempFilePath || filePath.path || filePath; + const fileName = typeof filePath === "string" ? filePath.split("/").pop() || "database.db" : filePath.name || "database.db"; + uni.uploadFile({ + url: `${BASE_URL}/cloud_api/database/upload/db`, + method: "POST", + header: {}, + formData: { + access_token: token + }, + file: { + name: fileName, + uri: fileUri + }, + files: [{ + name: "file", + uri: fileUri + }], + success: (res) => { + if (res.statusCode === 200) { + try { + const respond = JSON.parse(res.data); + if (respond.success) { + resolve(respond.message); + } else { + const msg = (respond == null ? void 0 : respond.error) || "上传db出错啦"; + reject(msg); + } + } catch (e2) { + reject("接口返回数据格式异常"); + } + } else { + reject(`上传db失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const deleteCloudDb = (token, databaseId) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/delete`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token, + "database_id": databaseId + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.message); + } else { + const msg = (respond == null ? void 0 : respond.error) || "删除数据库出错啦"; + reject(msg); + } + } else { + reject(`删除数据库失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const getCloudDbTables = (token, databaseId, isDetail) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/tables`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token, + "database_id": databaseId, + "is_detail": isDetail + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.tables); + } else { + const msg = (respond == null ? void 0 : respond.error) || "获取用户可访问的数据库列表出错啦"; + reject(msg); + } + } else { + reject(`获取用户可访问的数据库列表失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const getCloudDbTableData = (token, databaseId, tableName, limit = "20", offset = "0") => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/table/data`, + method: "POST", + header: { + "Content-Type": "application/json" + }, + data: { + "access_token": token, + "database_id": databaseId, + "table_name": tableName, + "limit": limit, + "offset": offset + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.data); + } else { + const msg = (respond == null ? void 0 : respond.error) || "获取表数据出错啦"; + reject(msg); + } + } else { + reject(`获取表数据失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const deleteCloudDbTable = async (token, databaseId, tableName) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/table/drop`, + method: "POST", + data: { + "access_token": token, + "database_id": databaseId, + "table_name": tableName + }, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.message); + } else { + const msg = respond.error || "删除数据库中的表出错啦"; + reject(msg); + } + } else { + reject(`删除数据库中的表失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const updateCloudDbTableData = (token, databaseId, tableName, whereData, updateData) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/table/update/by/id`, + method: "POST", + data: { + "access_token": token, + "database_id": databaseId, + "table_name": tableName, + "where_data": whereData, + "update_data": updateData + }, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.message); + } else { + const msg = respond.error || "更新表数据出错啦"; + reject(msg); + } + } else { + reject(`更新表数据失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const importFileToCloudDb = (token, forceOverwrite, databaseId, filePath, tableName) => { + return new Promise((resolve, reject) => { + const fileUri = typeof filePath === "string" ? filePath : filePath.tempFilePath || filePath.path || filePath; + const fileName = typeof filePath === "string" ? filePath.split("/").pop() || "file" : filePath.name || "file"; + uni.uploadFile({ + url: `${BASE_URL}/cloud_api/database/import`, + method: "POST", + header: {}, + formData: { + access_token: token, + force_overwrite: forceOverwrite, + database_id: databaseId, + table_name: tableName + }, + // uni.uploadFile 的 file 参数需要是对象格式:{ name, uri } + file: { + name: fileName, + uri: fileUri + }, + // 同时用 files 方式兜底 + files: [{ + name: "file", + uri: fileUri + }], + success: (res) => { + if (res.statusCode === 200) { + try { + const respond = JSON.parse(res.data); + if (respond.success) { + resolve(respond.message); + } else { + const msg = (respond == null ? void 0 : respond.error) || "导入文件到数据库出错啦"; + reject(msg); + } + } catch (e2) { + reject("接口返回数据格式异常"); + } + } else { + reject(`导入文件到数据库失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const getCloudDbPermission = (token, databaseId, type, id) => { + return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId + }; + if (type === "user_id") { + requestData.user_id = id; + } else if (type === "team_id") { + requestData.team_id = id; + } + uni.request({ + url: `${BASE_URL}/cloud_api/database/permission/info`, + method: "POST", + data: requestData, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.data); + } else if (Array.isArray(respond)) { + resolve(respond); + } else { + const msg = (respond == null ? void 0 : respond.error) || "查看 个人/团队 数据库权限信息出错啦"; + reject(msg); + } + } else { + reject(`查看 个人/团队 数据库权限信息失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const deleteCloudDbPermission = (token, databaseId, type, id) => { + return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId + }; + if (type === "user_id") { + requestData.user_id = id; + } else if (type === "team_id") { + requestData.team_id = id; + } + uni.request({ + url: `${BASE_URL}/cloud_api/database/permission/delete`, + method: "POST", + data: requestData, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.message); + } else { + const msg = respond.error || "删除 团队/用户 对数据库权限出错啦"; + reject(msg); + } + } else { + reject(`删除 团队/用户 对数据库权限失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const updateCloudDbPermission = (token, databaseId, type, id, level) => { + return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId, + "access_level": level + }; + if (type === "user_id") { + requestData.user_id = id; + } else if (type === "team_id") { + requestData.team_id = id; + } + uni.request({ + url: `${BASE_URL}/cloud_api/database/permission/update`, + method: "POST", + data: requestData, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.message); + } else { + const msg = respond.error || "修改/增加 团队/用户 对数据库权限出错啦"; + reject(msg); + } + } else { + reject(`修改/增加 团队/用户 对数据库权限失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; + const dbTransferToTeam = async (token, databaseId, teamId) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/transfer_to_team`, + method: "POST", + data: { + "access_token": token, + "database_id": databaseId, + "team_id": teamId + }, + header: { + "Content-Type": "application/json" + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond == null ? void 0 : respond.success) { + resolve(respond.message); + } else { + const msg = respond.error || "个人数据库移交团队出错啦"; + reject(msg); + } + } else { + reject(`个人数据库移交团队失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || "网络错误"; + reject(msg); + } + }); + }); + }; const _export_sfc = (sfc, props) => { const target = sfc.__vccOpts || sfc; for (const [key, val] of props) { @@ -915,7 +1503,7 @@ if (uni.restoreGlobal) { } return target; }; - const _sfc_main$b = { + const _sfc_main$c = { __name: "Login", setup(__props, { expose: __expose }) { __expose(); @@ -1009,7 +1597,7 @@ if (uni.restoreGlobal) { return __returned__; } }; - function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) { return vue.openBlock(), vue.createElementBlock( vue.Fragment, null, @@ -1107,7 +1695,7 @@ if (uni.restoreGlobal) { /* STABLE_FRAGMENT */ ); } - const PagesLoginLogin = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$a], ["__scopeId", "data-v-461d1d79"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/Login/Login.vue"]]); + const PagesLoginLogin = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$b], ["__scopeId", "data-v-461d1d79"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/Login/Login.vue"]]); const fontData = [ { "font_class": "arrow-down", @@ -1758,7 +2346,7 @@ if (uni.restoreGlobal) { const reg = /^[0-9]*$/g; return typeof val === "number" || reg.test(val) ? val + "px" : val; }; - const _sfc_main$a = { + const _sfc_main$b = { name: "UniIcons", emits: ["click"], props: { @@ -1812,7 +2400,7 @@ if (uni.restoreGlobal) { } } }; - function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) { return vue.openBlock(), vue.createElementBlock( "text", { @@ -1827,7 +2415,7 @@ if (uni.restoreGlobal) { /* CLASS, STYLE */ ); } - const __easycom_0 = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$9], ["__scopeId", "data-v-d31e1c47"], ["__file", "D:/Projects/uniapp/app-test/test1/uni_modules/uni-icons/components/uni-icons/uni-icons.vue"]]); + const __easycom_0 = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$a], ["__scopeId", "data-v-d31e1c47"], ["__file", "D:/Projects/uniapp/app-test/test1/uni_modules/uni-icons/components/uni-icons/uni-icons.vue"]]); const getToken = () => { return uni.getStorageSync("token"); }; @@ -1854,7 +2442,7 @@ if (uni.restoreGlobal) { const getWorkspaceId = () => { return uni.getStorageSync("workspace_id"); }; - const _sfc_main$9 = /* @__PURE__ */ Object.assign({ + const _sfc_main$a = /* @__PURE__ */ Object.assign({ name: "ChatSidebar" }, { __name: "ChatSidebar", @@ -2018,7 +2606,7 @@ if (uni.restoreGlobal) { return __returned__; } }); - function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock("view", { class: "chat-sidebar-container" }, [ vue.createElementVNode("view", { class: "status-bar" }), @@ -2287,7 +2875,7 @@ if (uni.restoreGlobal) { ]) ]); } - const ChatSidebar = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$8], ["__scopeId", "data-v-0c6c7315"], ["__file", "D:/Projects/uniapp/app-test/test1/components/ChatSidebar.vue"]]); + const ChatSidebar = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$9], ["__scopeId", "data-v-0c6c7315"], ["__file", "D:/Projects/uniapp/app-test/test1/components/ChatSidebar.vue"]]); var e = { "": ["", ""], _: ["", ""], "*": ["", ""], "~": ["", ""], "\n": ["
    "], " ": ["
    "], "-": ["
    "] }; function n(e2) { return e2.replace(RegExp("^" + (e2.match(/^(\t| )+/) || "")[0], "gm"), ""); @@ -4949,12 +5537,9 @@ This will fail in production.`); const is_uni_modules = true; const pkg = /* @__PURE__ */ initUTSPackageName(name, is_uni_modules); const cls = /* @__PURE__ */ initUTSIndexClassName(name, is_uni_modules); - const exports$1 = { __esModule: true }; - exports$1.chooseFile = /* @__PURE__ */ initUTSProxyFunction(false, { moduleName, moduleType, errMsg, main: true, package: pkg, class: cls, name: "chooseFileByJs", keepAlive: false, params: [{ "name": "options", "type": "UTSSDKModulesLimeChooseFileChooseFileOptionJSONObject" }], return: "" }); - uni.registerUTSPlugin("uni_modules/lime-choose-file", exports$1); - const limeChooseFile_utsProxy = uni.requireUTSPlugin("uni_modules/lime-choose-file"); + const chooseFile = /* @__PURE__ */ initUTSProxyFunction(false, { moduleName, moduleType, errMsg, main: true, package: pkg, class: cls, name: "chooseFileByJs", keepAlive: false, params: [{ "name": "options", "type": "UTSSDKModulesLimeChooseFileChooseFileOptionJSONObject" }], return: "" }); const pageInfoNumber = 100; - const _sfc_main$8 = { + const _sfc_main$9 = { __name: "Chat", setup(__props, { expose: __expose }) { __expose(); @@ -5201,7 +5786,7 @@ This will fail in production.`); const fileList = vue.ref([]); const uploadFile = () => { formatAppLog("log", "at pages/Chat/Chat.vue:588", "点击了上传文件"); - limeChooseFile_utsProxy.chooseFile({ + chooseFile({ count: 5, type: "all", success: (res) => { @@ -5725,7 +6310,7 @@ This will fail in production.`); }, get useFriendSocketStore() { return useFriendSocketStore; }, get chooseFile() { - return limeChooseFile_utsProxy.chooseFile; + return chooseFile; }, get socketManager() { return socketManager; } }; @@ -5733,7 +6318,7 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock( vue.Fragment, @@ -6263,8 +6848,8 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesChatChat = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$7], ["__scopeId", "data-v-5eb7b895"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/Chat/Chat.vue"]]); - const _sfc_main$7 = { + const PagesChatChat = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$8], ["__scopeId", "data-v-5eb7b895"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/Chat/Chat.vue"]]); + const _sfc_main$8 = { __name: "WorkSpace", setup(__props, { expose: __expose }) { __expose(); @@ -6298,6 +6883,66 @@ This will fail in production.`); const newWorkspaceFolder = () => { showNewFolder.value = true; }; + const handleUploadFile = () => { + chooseFile({ + count: 10, + type: "all", + success: async (res) => { + const files = res.tempFiles || []; + if (files.length === 0) { + uni.showToast({ + title: "未选择文件", + icon: "none" + }); + return; + } + await doUploadWorkspaceFiles(files); + }, + fail: (err) => { + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:176", "选择文件失败:", err); + } + }); + }; + const doUploadWorkspaceFiles = async (files) => { + uni.showLoading({ + title: "上传中..." + }); + try { + const dirPath = folderStack.value.length > 0 ? "./" + folderStack.value.map((f) => f.name).join("/") + "/" : "/"; + const results = await uploadFileToShortStorage( + workspaceId.value, + files, + dirPath + ); + const successUrls = results.filter((r2) => r2.success).map((r2) => r2.url); + if (successUrls.length === 0) { + const errors = results.filter((r2) => !r2.success).map((r2) => r2.error).join("; "); + throw new Error(errors || "所有文件上传失败"); + } + await workspaceUploadFileByURL( + UserToken.value, + workspaceId.value, + successUrls, + dirPath + ); + uni.hideLoading(); + const total = files.length; + const failed = total - successUrls.length; + const msg = failed > 0 ? `上传完成:成功 ${successUrls.length},失败 ${failed}` : `成功上传 ${total} 个文件`; + uni.showToast({ + title: msg, + icon: successUrls.length > 0 ? "success" : "error" + }); + initCurrentFolderList(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:229", "上传文件失败:", error); + uni.showToast({ + title: typeof error === "string" ? error : "上传失败,请重试", + icon: "error" + }); + } + }; const currentFolderPath = vue.computed(() => { if (folderStack.value.length === 0) return "根目录"; @@ -6314,75 +6959,113 @@ This will fail in production.`); const confirmCreateFolder = async () => { const name2 = newFolderName.value.trim(); if (!name2) { - uni.showToast({ title: "请输入目录名称", icon: "none" }); + uni.showToast({ + title: "请输入目录名称", + icon: "none" + }); return; } try { const folderPath = folderStack.value.map((f) => f.name).join("/"); const dirPath = folderPath ? `./${folderPath}/${name2}` : `./${name2}`; await createWorkspaceFolder(UserToken.value, workspaceId.value, dirPath); - uni.showToast({ title: "创建成功", icon: "success" }); + uni.showToast({ + title: "创建成功", + icon: "success" + }); closeNewFolderModal(); initCurrentFolderList(); } catch (error) { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:183", "创建文件夹失败:", error); - uni.showToast({ title: "创建失败,请重试", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:275", "创建文件夹失败:", error); + uni.showToast({ + title: "创建失败,请重试", + icon: "error" + }); } }; const handleLongPress = (folder) => { if (isSelectFolder.value) return; uni.showActionSheet({ - itemList: ["重命名", "删除", "下载", "压缩"], + itemList: ["下载", "删除"], + // ['删除', '下载', '压缩', '重命名'] success: (res) => { switch (res.tapIndex) { case 0: - handleRename(folder); + handleDownload(folder); break; case 1: handleDelete(folder); break; - case 2: - handleDownload(folder); - break; - case 3: - handleDownload(folder); - break; } } }); }; - const handleRename = (folder) => { + const handleRename = async (folder) => { uni.showModal({ title: "重命名", content: "请输入新名称", editable: true, placeholderText: folder.name, - success: (res) => { + success: async (res) => { if (res.confirm && res.content) { - updateFolderName(folder.id, res.content); + try { + uni.showLoading({ + title: "重命名中..." + }); + const dirPath = folderStack.value.length > 0 ? "./" + folderStack.value.map((f) => f.name).join("/") + "/" : "/"; + const filePath = dirPath + folder.name; + await updateWorkspaceFileName( + workspaceId.value, + filePath, + res.content + ); + uni.hideLoading(); + uni.showToast({ + title: "重命名成功", + icon: "success" + }); + initCurrentFolderList(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:339", "重命名失败:", error); + uni.showToast({ + title: typeof error === "string" ? error : "重命名失败,请重试", + icon: "error" + }); + } } } }); }; const handleDownload = async (folder) => { if (folder.type === "directory") { - uni.showToast({ title: "暂不支持下载目录", icon: "none" }); + uni.showToast({ + title: "暂不支持下载目录", + icon: "none" + }); return; } try { - uni.showLoading({ title: "获取下载链接..." }); + uni.showLoading({ + title: "获取下载链接..." + }); const filePath = folder.path.startsWith("./") ? folder.path.slice(2) : folder.path; const result = await getWorkspaceFileURL(UserToken.value, workspaceId.value, filePath); uni.hideLoading(); const fileInfo = Array.isArray(result) ? result[0] : result; if (!fileInfo || !fileInfo.url) { - uni.showToast({ title: "获取下载链接失败", icon: "error" }); + uni.showToast({ + title: "获取下载链接失败", + icon: "error" + }); return; } const downloadUrl = fileInfo.url; const fileName = folder.name; - uni.showLoading({ title: "下载中..." }); + uni.showLoading({ + title: "下载中..." + }); uni.downloadFile({ url: downloadUrl, name: fileName, @@ -6392,19 +7075,28 @@ This will fail in production.`); const tempPath = downloadRes.tempFilePath; saveFileToYxd(fileName, tempPath); } else { - uni.showToast({ title: "下载失败", icon: "error" }); + uni.showToast({ + title: "下载失败", + icon: "error" + }); } }, fail: (err) => { uni.hideLoading(); - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:333", "下载文件失败:", err); - uni.showToast({ title: "下载失败,请重试", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:406", "下载文件失败:", err); + uni.showToast({ + title: "下载失败,请重试", + icon: "error" + }); } }); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:339", "获取下载链接失败:", error); - uni.showToast({ title: "获取下载链接失败,请重试", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:415", "获取下载链接失败:", error); + uni.showToast({ + title: "获取下载链接失败,请重试", + icon: "error" + }); } }; const saveFileToYxd = (fileName, tempPath) => { @@ -6414,16 +7106,24 @@ This will fail in production.`); callback(dirEntry); }, () => { plus.io.resolveLocalFileSystemURL("/storage/emulated/0/", (rootEntry) => { - rootEntry.getDirectory("yxd", { create: true }, (dirEntry) => { + rootEntry.getDirectory("yxd", { + create: true + }, (dirEntry) => { callback(dirEntry); }, (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:358", "创建 yxd 目录失败:", JSON.stringify(err)); - uni.showToast({ title: "创建目录失败", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:439", "创建 yxd 目录失败:", JSON.stringify(err)); + uni.showToast({ + title: "创建目录失败", + icon: "error" + }); openFileConfirm(fileName, tempPath); }); }, (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:363", "访问外部存储根目录失败:", JSON.stringify(err)); - uni.showToast({ title: "无法访问存储目录", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:447", "访问外部存储根目录失败:", JSON.stringify(err)); + uni.showToast({ + title: "无法访问存储目录", + icon: "error" + }); openFileConfirm(fileName, tempPath); }); }); @@ -6435,16 +7135,16 @@ This will fail in production.`); fileName, () => { const targetPath = YXD_PATH + fileName; - formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:377", "文件已保存到:", targetPath); + formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:464", "文件已保存到:", targetPath); openFileConfirm(fileName, targetPath); }, (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:381", "复制文件失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:468", "复制文件失败:", JSON.stringify(err)); openFileConfirm(fileName, tempPath); } ); }, (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:386", "读取临时文件失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:473", "读取临时文件失败:", JSON.stringify(err)); openFileConfirm(fileName, tempPath); }); }); @@ -6485,7 +7185,7 @@ This will fail in production.`); icon: "success" }), fail: (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:443", "打开文件失败:", err); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:530", "打开文件失败:", err); uni.showToast({ title: "无法打开此文件", icon: "error" @@ -6502,7 +7202,7 @@ This will fail in production.`); icon: "success" }), fail: (err) => { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:462", "打开文件失败:", err); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:549", "打开文件失败:", err); uni.showToast({ title: "无法打开此文件", icon: "error" @@ -6518,13 +7218,19 @@ This will fail in production.`); if (res.confirm) { try { const filePath = `./${folder.path}`; - formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:481", "删除的是:", filePath); + formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:568", "删除的是:", filePath); await daleteWorkspace(UserToken.value, workspaceId.value, filePath); - uni.showToast({ title: "删除成功", icon: "success" }); + uni.showToast({ + title: "删除成功", + icon: "success" + }); initCurrentFolderList(); } catch (error) { - formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:486", "删除失败:", error); - uni.showToast({ title: "删除失败,请重试", icon: "error" }); + formatAppLog("error", "at pages/WorkSpace/WorkSpace.vue:576", "删除失败:", error); + uni.showToast({ + title: "删除失败,请重试", + icon: "error" + }); } } } @@ -6588,7 +7294,7 @@ This will fail in production.`); const currentFolderList = vue.ref([]); const getCurrentFolderList = () => { var _a, _b; - formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:564", "当前路径为:", JSON.stringify(folderStack.value)); + formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:657", "当前路径为:", JSON.stringify(folderStack.value)); const currentPath = folderStack.value.length > 0 ? folderStack.value[folderStack.value.length - 1].path : "."; if (currentPath === ".") { return ((_a = allFoldersData.value) == null ? void 0 : _a.children) || []; @@ -6612,7 +7318,7 @@ This will fail in production.`); const initCurrentFolderList = async () => { workspaceId.value = getWorkspaceId(); UserToken.value = getToken(); - formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:591", "getWorkspaceId:", workspaceId.value); + formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:684", "getWorkspaceId:", workspaceId.value); allFoldersData.value = await getWorkspaceList(UserToken.value, workspaceId.value); currentFolderList.value = getCurrentFolderList(); }; @@ -6657,7 +7363,7 @@ This will fail in production.`); uni.navigateBack({ delta: 1, fail() { - formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:648", "返回失败,进入兜底跳转"); + formatAppLog("log", "at pages/WorkSpace/WorkSpace.vue:741", "返回失败,进入兜底跳转"); uni.reLaunch({ url: "/pages/Chat/Chat" }); @@ -6668,10 +7374,12 @@ This will fail in production.`); vue.onMounted(() => { initCurrentFolderList(); }); - const __returned__ = { UserToken, workspaceId, navbarBeforeTitle, navbarTitle, isSelectFolder, selectFileList, handleSelectFolder, selectFolder, showNewFolder, isNFNFocused, newFolderName, closeNewFolderModal, newWorkspaceFolder, currentFolderPath, folderPathPreview, confirmCreateFolder, handleLongPress, handleRename, handleDownload, saveFileToYxd, openFileConfirm, openFile, openFileWithMenu, handleDelete, isMenuOpen, handleMenu, searchKeyword, isSearchFocus, handleSearchFocus, getFileIcon, allFoldersData, folderStack, currentFolderList, getCurrentFolderList, initCurrentFolderList, handleFolderClick, handleSelectAll, handleBackOrCheck, onMounted: vue.onMounted, ref: vue.ref, computed: vue.computed, get getWorkspaceId() { + const __returned__ = { UserToken, workspaceId, navbarBeforeTitle, navbarTitle, isSelectFolder, selectFileList, handleSelectFolder, selectFolder, showNewFolder, isNFNFocused, newFolderName, closeNewFolderModal, newWorkspaceFolder, handleUploadFile, doUploadWorkspaceFiles, currentFolderPath, folderPathPreview, confirmCreateFolder, handleLongPress, handleRename, handleDownload, saveFileToYxd, openFileConfirm, openFile, openFileWithMenu, handleDelete, isMenuOpen, handleMenu, searchKeyword, isSearchFocus, handleSearchFocus, getFileIcon, allFoldersData, folderStack, currentFolderList, getCurrentFolderList, initCurrentFolderList, handleFolderClick, handleSelectAll, handleBackOrCheck, onMounted: vue.onMounted, ref: vue.ref, computed: vue.computed, get getWorkspaceId() { return getWorkspaceId; }, get getToken() { return getToken; + }, get chooseFile() { + return chooseFile; }, get getWorkspaceList() { return getWorkspaceList; }, get createWorkspaceFolder() { @@ -6680,12 +7388,18 @@ This will fail in production.`); return daleteWorkspace; }, get getWorkspaceFileURL() { return getWorkspaceFileURL; + }, get uploadFileToShortStorage() { + return uploadFileToShortStorage; + }, get workspaceUploadFileByURL() { + return workspaceUploadFileByURL; + }, get updateWorkspaceFileName() { + return updateWorkspaceFileName; } }; Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true }); return __returned__; } }; - function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock( vue.Fragment, @@ -6810,10 +7524,10 @@ This will fail in production.`); vue.createElementVNode("view", { class: "menu-card-item", onClick: _cache[6] || (_cache[6] = ($event) => { - $setup.handleSelectFolder(); + $setup.handleUploadFile(); $setup.handleMenu(); }) - }, "选择"), + }, "上传文件"), vue.createElementVNode("view", { class: "solid-line" }), vue.createElementVNode("view", { class: "menu-card-item", @@ -6921,11 +7635,11 @@ This will fail in production.`); class: vue.normalizeClass(["workspace-footer", { "folder-actions": $setup.selectFileList.length > 0 }]) }, [ - vue.createElementVNode("view", { class: "iconfont icon-shangchuan" }), - vue.createElementVNode("view", { class: "iconfont icon-fuzhi" }), - vue.createElementVNode("view", { class: "iconfont icon-wenjian" }), - vue.createElementVNode("view", { class: "iconfont icon-del" }), - vue.createElementVNode("view", { class: "iconfont icon-gengduo" }) + vue.createElementVNode("view", { + class: "iconfont icon-shangchuan", + onClick: $setup.handleUploadFile + }), + vue.createElementVNode("view", { class: "iconfont icon-del" }) ], 2 /* CLASS */ @@ -6936,8 +7650,8 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesWorkSpaceWorkSpace = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$6], ["__scopeId", "data-v-c1a60359"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/WorkSpace/WorkSpace.vue"]]); - const _sfc_main$6 = { + const PagesWorkSpaceWorkSpace = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$7], ["__scopeId", "data-v-c1a60359"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/WorkSpace/WorkSpace.vue"]]); + const _sfc_main$7 = { __name: "UserProfileModal", setup(__props, { expose: __expose }) { __expose(); @@ -7026,7 +7740,7 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock( vue.Fragment, @@ -7124,8 +7838,8 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesUserProfileModalUserProfileModal = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$5], ["__scopeId", "data-v-d2908b51"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/UserProfileModal/UserProfileModal.vue"]]); - const _sfc_main$5 = { + const PagesUserProfileModalUserProfileModal = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$6], ["__scopeId", "data-v-d2908b51"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/UserProfileModal/UserProfileModal.vue"]]); + const _sfc_main$6 = { __name: "ContactPages", setup(__props, { expose: __expose }) { __expose(); @@ -7178,11 +7892,11 @@ This will fail in production.`); label: "添加好友", icon: "➕" }, - { - name: "videoCall", - label: "视频会议", - icon: "📹" - }, + // { + // name: 'videoCall', + // label: '视频会议', + // icon: '📹' + // }, { name: "friendRequest", label: "好友申请", @@ -7545,7 +8259,7 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock( vue.Fragment, @@ -8011,110 +8725,6 @@ This will fail in production.`); ]) ]) ]), - vue.createElementVNode("swiper-item", { class: "content-swiper-item" }, [ - vue.createElementVNode("view", { class: "tabpage-containner" }, [ - vue.createElementVNode("view", { class: "tabpage-header" }, [ - vue.createElementVNode("view", { - class: "iconfont icon-fanhui", - onClick: $setup.handleBack - }), - vue.createElementVNode("view", { class: "tabpage-title" }, "视频会议") - ]), - vue.createElementVNode("view", { class: "tabpage-body" }, [ - vue.createElementVNode("view", { class: "join-meeting-wrapper" }, [ - vue.createElementVNode("view", null, "加入会议"), - vue.createElementVNode("input", { - class: "input-meeting", - placeholder: "请输入会议号" - }), - vue.createElementVNode("view", { class: "meeting-btn text-btn" }, "加入会议") - ]), - vue.createElementVNode("view", { class: "solid-line" }), - vue.createElementVNode("view", { class: "create-meeting-wrapper" }, [ - vue.createElementVNode("view", null, "创建会议"), - vue.createElementVNode("view", { class: "meeting-field" }, [ - vue.createElementVNode("view", { class: "meeting-label" }, "会议主题"), - vue.createElementVNode("input", { - class: "input-meeting", - placeholder: "例如:XXX" - }) - ]), - vue.createElementVNode("view", { class: "meeting-field" }, [ - vue.createElementVNode("view", { class: "meeting-label" }, "会议密码"), - vue.createElementVNode("input", { - class: "input-meeting", - placeholder: "留空则无密码" - }) - ]), - vue.createElementVNode("view", { class: "meeting-field" }, [ - vue.createElementVNode("view", { class: "meeting-label" }, "邀请好友"), - vue.createElementVNode("view", { class: "friend-card" }, [ - vue.createElementVNode("view", { class: "friend-card-left" }, [ - vue.createElementVNode("view", { class: "friend-avatar" }, "avatar") - ]), - vue.createElementVNode("view", { class: "friend-card-middle" }, [ - vue.createElementVNode("view", { class: "friend-name" }, "friend.nickname"), - vue.createElementVNode("view", { class: "friend-label" }, "friend.email") - ]), - vue.createElementVNode("view", { - class: "friend-card-right", - onClick: _cache[4] || (_cache[4] = ($event) => _ctx.addMeetingMembers(_ctx.friend.id)) - }, [ - vue.createElementVNode("view", { class: "add-btn text-btn" }, "添加") - ]) - ]) - ]), - vue.createElementVNode("view", { class: "meeting-toggles" }, [ - vue.createElementVNode("view", { class: "meeting-toggles-item" }, [ - vue.createElementVNode("view", { class: "meeting-toggles-icon icon-btn" }, [ - vue.createVNode(_component_uni_icons, { type: "mic-filled" }), - vue.createTextVNode("开启麦克风入会 ") - ]), - vue.createElementVNode("view", { - class: "meeting-toggles-switch", - onClick: $setup.togglesVoice - }, [ - vue.createElementVNode( - "view", - { - class: vue.normalizeClass(["switch-box", { active: $setup.isVoice }]) - }, - [ - vue.createElementVNode("view", { class: "switch-track" }) - ], - 2 - /* CLASS */ - ) - ]) - ]), - vue.createElementVNode("view", { class: "meeting-toggles-item" }, [ - vue.createElementVNode("view", { class: "meeting-toggles-icon icon-btn" }, [ - vue.createVNode(_component_uni_icons, { type: "eye-filled" }), - vue.createTextVNode("开启摄像头入会 ") - ]), - vue.createElementVNode("view", { - class: "meeting-toggles-switch", - onClick: $setup.togglesCamera - }, [ - vue.createElementVNode( - "view", - { - class: vue.normalizeClass(["switch-box", { active: $setup.isCamera }]) - }, - [ - vue.createElementVNode("view", { class: "switch-track" }) - ], - 2 - /* CLASS */ - ) - ]) - ]) - ]), - vue.createElementVNode("view", { class: "meeting-btn text-btn" }, "加入会议") - ]) - ]) - ]) - ]), vue.createElementVNode("swiper-item", { class: "content-swiper-item" }, [ vue.createElementVNode("view", { class: "tabpage-containner" }, [ vue.createElementVNode("view", { class: "tabpage-header" }, [ @@ -8237,8 +8847,8 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesContactPagesContactPages = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$4], ["__scopeId", "data-v-976117c3"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/ContactPages/ContactPages.vue"]]); - const _sfc_main$4 = { + const PagesContactPagesContactPages = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$5], ["__scopeId", "data-v-976117c3"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/ContactPages/ContactPages.vue"]]); + const _sfc_main$5 = { __name: "TemplateSpace", setup(__props, { expose: __expose }) { __expose(); @@ -8552,7 +9162,7 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) { return vue.openBlock(), vue.createElementBlock( vue.Fragment, null, @@ -8795,8 +9405,8 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesWorkSpaceTemplateSpaceTemplateSpace = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$3], ["__scopeId", "data-v-769edd25"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/WorkSpace/TemplateSpace/TemplateSpace.vue"]]); - const _sfc_main$3 = { + const PagesWorkSpaceTemplateSpaceTemplateSpace = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$4], ["__scopeId", "data-v-769edd25"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/WorkSpace/TemplateSpace/TemplateSpace.vue"]]); + const _sfc_main$4 = { __name: "text", setup(__props, { expose: __expose }) { __expose(); @@ -8951,15 +9561,15 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) { return vue.openBlock(), vue.createElementBlock("view", null, [ vue.createElementVNode("view", { innerHTML: $setup.sanitizeContent($setup.formHtml) }, null, 8, ["innerHTML"]) ]); } - const PagesTextText = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$2], ["__file", "D:/Projects/uniapp/app-test/test1/pages/text/text.vue"]]); - const _sfc_main$2 = { + const PagesTextText = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$3], ["__file", "D:/Projects/uniapp/app-test/test1/pages/text/text.vue"]]); + const _sfc_main$3 = { __name: "text2", setup(__props, { expose: __expose }) { __expose(); @@ -9116,7 +9726,7 @@ This will fail in production.`); return __returned__; } }; - function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) { return vue.openBlock(), vue.createElementBlock("view", { class: "container" }, [ vue.createElementVNode("view", { class: "status-card" }, [ vue.createElementVNode("text", { class: "status-label" }, "连接状态"), @@ -9313,8 +9923,8 @@ This will fail in production.`); ]) ]); } - const PagesTextText2 = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$1], ["__scopeId", "data-v-cd5869b7"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/text/text2.vue"]]); - const _sfc_main$1 = { + const PagesTextText2 = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$2], ["__scopeId", "data-v-cd5869b7"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/text/text2.vue"]]); + const _sfc_main$2 = { __name: "CloudDatabase", setup(__props, { expose: __expose }) { __expose(); @@ -9502,7 +10112,7 @@ This will fail in production.`); personalFiles.value = personalData || []; } } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:652", "获取文件列表失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:689", "获取文件列表失败:", error); rawPersonalFileData.value = []; personalFiles.value = []; } @@ -9511,11 +10121,11 @@ This will fail in production.`); try { teamId = teamId == null ? "" : String(teamId); const teamData = await getCloudFileList(userToken.value, "team", "/", teamId); - formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:663", "团队云端文件:", JSON.stringify(teamData)); + formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:700", "团队云端文件:", JSON.stringify(teamData)); rawTeamFileData.value = teamData || []; teamFiles.value = teamData || []; } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:667", "获取团队文件列表失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:704", "获取团队文件列表失败:", error); rawTeamFileData.value = []; teamFiles.value = []; } @@ -9620,7 +10230,7 @@ This will fail in production.`); }); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:784", "下载失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:821", "下载失败:", error); uni.showToast({ title: "下载失败,请重试", icon: "error" @@ -9637,12 +10247,12 @@ This will fail in production.`); rootEntry.getDirectory("yxd", { create: true }, (dirEntry) => { callback(dirEntry); }, (err) => { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:808", "创建 yxd 目录失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:845", "创建 yxd 目录失败:", JSON.stringify(err)); uni.showToast({ title: "创建目录失败", icon: "error" }); openFileConfirm(fileName, tempPath); }); }, (err) => { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:813", "访问外部存储根目录失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:850", "访问外部存储根目录失败:", JSON.stringify(err)); uni.showToast({ title: "无法访问存储目录", icon: "error" }); openFileConfirm(fileName, tempPath); }); @@ -9655,16 +10265,16 @@ This will fail in production.`); fileName, () => { const targetPath = YXD_PATH + fileName; - formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:827", "文件已保存到:", targetPath); + formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:864", "文件已保存到:", targetPath); openFileConfirm(fileName, targetPath); }, (err) => { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:831", "复制文件失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:868", "复制文件失败:", JSON.stringify(err)); openFileConfirm(fileName, tempPath); } ); }, (err) => { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:836", "读取临时文件失败:", JSON.stringify(err)); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:873", "读取临时文件失败:", JSON.stringify(err)); openFileConfirm(fileName, tempPath); }); }); @@ -9705,14 +10315,14 @@ This will fail in production.`); icon: "success" }), fail: (err) => { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:899", "打开文件失败:", err); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:936", "打开文件失败:", err); openFileWithMenu(filePath); } }); }; const openFileWithMenu = (filePath) => { plus.runtime.openFile(filePath, {}, (e2) => { - formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:911", "文件打开成功"); + formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:948", "文件打开成功"); }); }; const handleRename = (file) => { @@ -9754,7 +10364,7 @@ This will fail in production.`); refreshCurrentFileList(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:977", "deleteCloudFile 失败,尝试 daleteWorkspace:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1014", "deleteCloudFile 失败,尝试 daleteWorkspace:", error); try { const filePath = file.path || "/" + file.name; if (workspaceId.value) { @@ -9766,7 +10376,7 @@ This will fail in production.`); }); refreshCurrentFileList(); } catch (err2) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:989", "删除失败:", err2); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1026", "删除失败:", err2); uni.showToast({ title: "删除失败,请重试", icon: "error" @@ -9816,7 +10426,7 @@ This will fail in production.`); closeNewFolderModal(); refreshCurrentFileList(); } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1046", "创建文件夹失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1083", "创建文件夹失败:", error); uni.showToast({ title: "创建失败,请重试", icon: "error" @@ -9841,24 +10451,27 @@ This will fail in production.`); chooseAndUploadFile(); }; const chooseAndUploadFile = () => { - plus.io.chooseFile( - (res) => { - const files = Array.isArray(res) ? res : res.files || []; - if (files.length === 0) { + chooseFile({ + count: 10, + type: "all", + success: (res) => { + const tempFiles = (res.tempFiles || []).map((f) => ({ + tempFilePath: f.path || f.tempFilePath, + name: f.name + })); + if (tempFiles.length === 0) { uni.showToast({ title: "未选择文件", icon: "none" }); return; } - doUploadFiles(files); + doUploadFiles(tempFiles); }, - (err) => { - if (err.code !== 11) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1095", "选择文件失败:", err); - } + fail: (err) => { + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1133", "选择文件失败:", err); } - ); + }); }; const doUploadFiles = async (files) => { uni.showLoading({ @@ -9877,92 +10490,152 @@ This will fail in production.`); refreshCurrentFileList(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1147", "上传文件失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1159", "上传文件失败:", error); uni.showToast({ title: "上传失败,请重试", icon: "error" }); } }; - const personalTables = vue.ref([ - { - id: "1", - name: "users", - desc: "用户信息表", - rowCount: 128 - }, - { - id: "2", - name: "messages", - desc: "聊天记录表", - rowCount: 2048 - }, - { - id: "3", - name: "settings", - desc: "用户配置表", - rowCount: 56 + const allDatabases = vue.ref([]); + const isDbLoading = vue.ref(false); + const personalDatabases = vue.computed(() => allDatabases.value); + const teamDatabases = vue.computed(() => allDatabases.value.filter((db) => db.team_id && String(db.team_id) === String(currentTeamId.value))); + const showNewDb = vue.ref(false); + const newDbName = vue.ref(""); + const fetchDbList = async () => { + isDbLoading.value = true; + try { + const token = getToken(); + const list = await getCloudDbList(token); + allDatabases.value = list || []; + } catch (error) { + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1185", "获取数据库列表失败:", error); + allDatabases.value = []; + } finally { + isDbLoading.value = false; } - ]); - const teamTables = vue.ref([ - { - id: "t1", - name: "team_tasks", - desc: "团队任务表", - rowCount: 32 - }, - { - id: "t2", - name: "team_docs", - desc: "团队文档表", - rowCount: 15 - } - ]); - const showNewTable = vue.ref(false); - const newTableName = vue.ref(""); - const newTableDesc = vue.ref(""); - const openNewTableModal = () => { - showNewTable.value = true; - newTableName.value = ""; - newTableDesc.value = ""; }; - const closeNewTableModal = () => { - showNewTable.value = false; - newTableName.value = ""; - newTableDesc.value = ""; + const openNewDbModal = () => { + showNewDb.value = true; + newDbName.value = ""; }; - const confirmCreateTable = () => { - const name2 = newTableName.value.trim(); + const closeNewDbModal = () => { + showNewDb.value = false; + newDbName.value = ""; + }; + const confirmCreateDb = async () => { + const name2 = newDbName.value.trim(); if (!name2) { - uni.showToast({ - title: "请输入表名称", - icon: "none" - }); + uni.showToast({ title: "请输入数据库名称", icon: "none" }); return; } - const newTable = { - id: Date.now().toString(), - name: name2, - desc: newTableDesc.value.trim() || "无描述", - rowCount: 0 - }; - if (currentCategory.value === "user") { - personalTables.value.push(newTable); - } else { - teamTables.value.push(newTable); + uni.showLoading({ title: "创建中..." }); + try { + const token = getToken(); + await createCloudDb(token, name2); + uni.hideLoading(); + uni.showToast({ title: "创建成功", icon: "success" }); + closeNewDbModal(); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1216", "创建数据库失败:", error); + uni.showToast({ title: "创建失败,请重试", icon: "error" }); } - uni.showToast({ - title: "创建成功", - icon: "success" - }); - closeNewTableModal(); }; - const handleTableClick = (table) => { - uni.showToast({ - title: `进入数据表:${table.name}`, - icon: "none" + const showUploadDb = vue.ref(false); + const uploadDbFileName = vue.ref(""); + const uploadDbFilePath = vue.ref(""); + const openUploadDbModal = () => { + showUploadDb.value = true; + uploadDbFileName.value = ""; + uploadDbFilePath.value = ""; + }; + const closeUploadDbModal = () => { + showUploadDb.value = false; + }; + const handlePickDbFile = () => { + chooseFile({ + count: 1, + type: "all", + success: (res) => { + const file = res.tempFiles[0]; + uploadDbFileName.value = file.name || "unknown"; + uploadDbFilePath.value = file.path; + }, + fail: (err) => { + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1245", "选择文件失败:", err); + uni.showToast({ title: "选择文件失败", icon: "none" }); + } }); }; + const confirmUploadDb = async () => { + var _a; + if (!uploadDbFilePath.value) { + uni.showToast({ title: "请选择数据库文件", icon: "none" }); + return; + } + const ext = (_a = uploadDbFileName.value.split(".").pop()) == null ? void 0 : _a.toLowerCase(); + const allowedExts = ["db", "sqlite", "sqlite3"]; + if (!allowedExts.includes(ext)) { + uni.showToast({ title: "仅支持 .db / .sqlite / .sqlite3 文件", icon: "none" }); + return; + } + uni.showLoading({ title: "上传中..." }); + try { + const token = getToken(); + await uploadCloudDbFile(token, uploadDbFilePath.value); + uni.hideLoading(); + uni.showToast({ title: "上传成功", icon: "success" }); + closeUploadDbModal(); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1273", "上传数据库失败:", error); + uni.showToast({ title: "上传失败,请重试", icon: "error" }); + } + }; + const handleDeleteDb = (db) => { + uni.showModal({ + title: "删除数据库", + content: `确定要删除数据库"${db.database_name}"吗?此操作不可恢复。`, + success: async (res) => { + if (res.confirm) { + uni.showLoading({ title: "删除中..." }); + try { + const token = getToken(); + await deleteCloudDb(token, db.database_id); + uni.hideLoading(); + uni.showToast({ title: "删除成功", icon: "success" }); + await fetchDbList(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1293", "删除数据库失败:", error); + uni.showToast({ title: "删除失败,请重试", icon: "error" }); + } + } + } + }); + }; + const handleDbClick = (db) => { + uni.navigateTo({ + url: `/pages/CloudDbDetail/CloudDbDetail?databaseId=${db.database_id}&databaseName=${encodeURIComponent(db.database_name)}&teamId=${db.team_id || ""}` + }); + }; + const formatDbTime = (timestamp) => { + if (!timestamp) + return ""; + const date = new Date(timestamp * 1e3); + const y = date.getFullYear(); + const m = String(date.getMonth() + 1).padStart(2, "0"); + const d = String(date.getDate()).padStart(2, "0"); + return `${y}-${m}-${d}`; + }; + const getAccessLevelLabel = (level) => { + const labels = { 0: "无权限", 1: "只读", 2: "读写", 3: "管理" }; + return labels[level] || "未知"; + }; const showTeamManage = vue.ref(false); const teamGroups = vue.ref([]); const currentTeamId = vue.ref(""); @@ -9996,12 +10669,12 @@ This will fail in production.`); const groups = await getTeamList(token); teamGroups.value = groups || []; } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1278", "获取团队列表失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1362", "获取团队列表失败:", error); teamGroups.value = []; } }; const selectTeam = async (teamId) => { - formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:1284", "团队id为", teamId); + formatAppLog("log", "at pages/CloudDatabase/CloudDatabase.vue:1368", "团队id为", teamId); currentTeamId.value = teamId; try { const token = getToken(); @@ -10020,7 +10693,7 @@ This will fail in production.`); }; }); } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1301", "获取团队成员失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1385", "获取团队成员失败:", error); currentTeamMembers.value = []; } currentFolderPath.value = []; @@ -10052,7 +10725,7 @@ This will fail in production.`); }; }); } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1335", "获取团队成员失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1419", "获取团队成员失败:", error); uni.showToast({ title: "获取团队信息失败", icon: "none" }); return; } @@ -10114,7 +10787,7 @@ This will fail in production.`); currentTeamId.value = currentTeamId.value; } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1407", "修改团队信息失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1491", "修改团队信息失败:", error); uni.showToast({ title: "修改失败,请重试", icon: "error" }); } }; @@ -10135,7 +10808,7 @@ This will fail in production.`); await refreshTeamMembers(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1432", "调整成员身份失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1516", "调整成员身份失败:", error); uni.showToast({ title: "操作失败,请重试", icon: "error" }); } } @@ -10159,7 +10832,7 @@ This will fail in production.`); await refreshTeamMembers(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1458", "移除团队成员失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1542", "移除团队成员失败:", error); uni.showToast({ title: "移除失败,请重试", icon: "error" }); } } @@ -10199,7 +10872,7 @@ This will fail in production.`); if (searchResultList.value.length === 0) { } } catch (error) { - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1500", "搜索用户失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1584", "搜索用户失败:", error); searchResultList.value = []; searched.value = true; } @@ -10222,7 +10895,7 @@ This will fail in production.`); await refreshTeamMembers(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1526", "添加团队成员失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1610", "添加团队成员失败:", error); uni.showToast({ title: "添加失败,请重试", icon: "error" }); } } @@ -10253,7 +10926,7 @@ This will fail in production.`); closeTeamManage(); } catch (error) { uni.hideLoading(); - formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1560", "删除团队失败:", error); + formatAppLog("error", "at pages/CloudDatabase/CloudDatabase.vue:1644", "删除团队失败:", error); uni.showToast({ title: "删除失败,请重试", icon: "error" }); } } @@ -10263,9 +10936,12 @@ This will fail in production.`); vue.onMounted(async () => { await fetchFileList(); await fetchTeamList(); + await fetchDbList(); }); - const __returned__ = { userToken, userId, workspaceId, currentCategory, switchCategory, navbarTitle, isMenuOpen, isSelectFolder, selectFileList, handleMenu, handleSelectFolder, parentFolderName, handleBackOrUp, rawPersonalFileData, rawTeamFileData, personalFiles, teamFiles, currentFolderPath, isFolder, getFileExtension, getFileIcon, formatFileSize, currentFolderDisplayPath, personalFileCount, findFolderByPath, loadCurrentFiles, fetchFileList, fetchTeamFileList, handleFileClick, handleFileLongPress, handleDownload, saveFileToYxd, openFileConfirm, openFile, openFileWithMenu, handleRename, handleDeleteFile, refreshCurrentFileList, showNewFolder, newFolderName, openNewFolderModal, closeNewFolderModal, confirmCreateFolder, showUploadPathInput, uploadPath, handleUploadFile, closeUploadPathInput, confirmUploadPath, chooseAndUploadFile, doUploadFiles, personalTables, teamTables, showNewTable, newTableName, newTableDesc, openNewTableModal, closeNewTableModal, confirmCreateTable, handleTableClick, showTeamManage, teamGroups, currentTeamId, currentTeamMembers, inviteKeyword, currentTeamDescription, currentTeamType, currentUserRoleInTeam, isTeamAdmin, fetchTeamList, selectTeam, openTeamManage, closeTeamManage, showEditTeam, editTeamName, editTeamDesc, editTeamType, openEditTeamModal, closeEditTeamModal, confirmEditTeam, toggleMemberRole, removeTeamMemberHandler, refreshTeamMembers, searchResultList, searched, searchTeamMember, addTeamMemberHandler, handleDeleteTeam, onMounted: vue.onMounted, ref: vue.ref, computed: vue.computed, get getToken() { + const __returned__ = { userToken, userId, workspaceId, currentCategory, switchCategory, navbarTitle, isMenuOpen, isSelectFolder, selectFileList, handleMenu, handleSelectFolder, parentFolderName, handleBackOrUp, rawPersonalFileData, rawTeamFileData, personalFiles, teamFiles, currentFolderPath, isFolder, getFileExtension, getFileIcon, formatFileSize, currentFolderDisplayPath, personalFileCount, findFolderByPath, loadCurrentFiles, fetchFileList, fetchTeamFileList, handleFileClick, handleFileLongPress, handleDownload, saveFileToYxd, openFileConfirm, openFile, openFileWithMenu, handleRename, handleDeleteFile, refreshCurrentFileList, showNewFolder, newFolderName, openNewFolderModal, closeNewFolderModal, confirmCreateFolder, showUploadPathInput, uploadPath, handleUploadFile, closeUploadPathInput, confirmUploadPath, chooseAndUploadFile, doUploadFiles, allDatabases, isDbLoading, personalDatabases, teamDatabases, showNewDb, newDbName, fetchDbList, openNewDbModal, closeNewDbModal, confirmCreateDb, showUploadDb, uploadDbFileName, uploadDbFilePath, openUploadDbModal, closeUploadDbModal, handlePickDbFile, confirmUploadDb, handleDeleteDb, handleDbClick, formatDbTime, getAccessLevelLabel, showTeamManage, teamGroups, currentTeamId, currentTeamMembers, inviteKeyword, currentTeamDescription, currentTeamType, currentUserRoleInTeam, isTeamAdmin, fetchTeamList, selectTeam, openTeamManage, closeTeamManage, showEditTeam, editTeamName, editTeamDesc, editTeamType, openEditTeamModal, closeEditTeamModal, confirmEditTeam, toggleMemberRole, removeTeamMemberHandler, refreshTeamMembers, searchResultList, searched, searchTeamMember, addTeamMemberHandler, handleDeleteTeam, onMounted: vue.onMounted, ref: vue.ref, computed: vue.computed, get getToken() { return getToken; + }, get chooseFile() { + return chooseFile; }, get getUserInfo() { return getUserInfo; }, get getCloudFileList() { @@ -10298,12 +10974,20 @@ This will fail in production.`); return deleteCloudFile; }, get deleteTeam() { return deleteTeam; + }, get getCloudDbList() { + return getCloudDbList; + }, get createCloudDb() { + return createCloudDb; + }, get uploadCloudDbFile() { + return uploadCloudDbFile; + }, get deleteCloudDb() { + return deleteCloudDb; } }; Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true }); return __returned__; } }; - function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { + function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) { const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); return vue.openBlock(), vue.createElementBlock( vue.Fragment, @@ -10682,10 +11366,55 @@ This will fail in production.`); ]) ]) ])) : vue.createCommentVNode("v-if", true), - $setup.showNewTable ? (vue.openBlock(), vue.createElementBlock("view", { + $setup.showNewDb ? (vue.openBlock(), vue.createElementBlock("view", { key: 4, class: "popup-overlay", - onClick: $setup.closeNewTableModal + onClick: $setup.closeNewDbModal + }, [ + vue.createElementVNode("view", { + class: "popup-card", + onClick: _cache[10] || (_cache[10] = vue.withModifiers(() => { + }, ["stop"])) + }, [ + vue.createElementVNode("view", { + class: "close-popup-card", + onClick: $setup.closeNewDbModal + }, [ + vue.createElementVNode("view", { class: "iconfont icon-quxiao" }) + ]), + vue.createElementVNode("view", { class: "popup-title" }, "新建个人数据库"), + vue.createElementVNode("view", { class: "new-folder-name" }, "数据库名称"), + vue.createElementVNode("view", { class: "create-folder-name" }, [ + vue.withDirectives(vue.createElementVNode( + "input", + { + "onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => $setup.newDbName = $event), + type: "text", + placeholder: "输入数据库名称" + }, + null, + 512 + /* NEED_PATCH */ + ), [ + [vue.vModelText, $setup.newDbName] + ]) + ]), + vue.createElementVNode("view", { class: "option-wrapper" }, [ + vue.createElementVNode("view", { + class: "opt-btn opt-cancel", + onClick: $setup.closeNewDbModal + }, "取消"), + vue.createElementVNode("view", { + class: "opt-btn opt-confirm", + onClick: $setup.confirmCreateDb + }, "确认") + ]) + ]) + ])) : vue.createCommentVNode("v-if", true), + $setup.showUploadDb ? (vue.openBlock(), vue.createElementBlock("view", { + key: 5, + class: "popup-overlay", + onClick: $setup.closeUploadDbModal }, [ vue.createElementVNode("view", { class: "popup-card", @@ -10694,58 +11423,39 @@ This will fail in production.`); }, [ vue.createElementVNode("view", { class: "close-popup-card", - onClick: $setup.closeNewTableModal + onClick: $setup.closeUploadDbModal }, [ vue.createElementVNode("view", { class: "iconfont icon-quxiao" }) ]), - vue.createElementVNode( - "view", - { class: "popup-title" }, - "新建" + vue.toDisplayString($setup.currentCategory === "user" ? "个人" : "团队") + "数据表", - 1 - /* TEXT */ - ), - vue.createElementVNode("view", { class: "new-folder-name" }, "表名称"), - vue.createElementVNode("view", { class: "create-folder-name" }, [ - vue.withDirectives(vue.createElementVNode( - "input", + vue.createElementVNode("view", { class: "popup-title" }, "上传数据库文件"), + vue.createElementVNode("view", { class: "upload-db-hint" }, "支持 .db / .sqlite / .sqlite3 格式的 SQLite 数据库文件"), + vue.createElementVNode("view", { + class: "upload-file-area", + onClick: $setup.handlePickDbFile + }, [ + $setup.uploadDbFileName ? (vue.openBlock(), vue.createElementBlock( + "view", { - "onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => $setup.newTableName = $event), - type: "text", - placeholder: "输入表名称,如:users" + key: 0, + class: "selected-file" }, - null, - 512 - /* NEED_PATCH */ - ), [ - [vue.vModelText, $setup.newTableName] - ]) - ]), - vue.createElementVNode("view", { class: "new-folder-name" }, "描述"), - vue.createElementVNode("view", { class: "create-folder-name" }, [ - vue.withDirectives(vue.createElementVNode( - "input", - { - "onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => $setup.newTableDesc = $event), - type: "text", - placeholder: "输入表描述(可选)" - }, - null, - 512 - /* NEED_PATCH */ - ), [ - [vue.vModelText, $setup.newTableDesc] - ]) + vue.toDisplayString($setup.uploadDbFileName), + 1 + /* TEXT */ + )) : (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "upload-hint" + }, "点击选择数据库文件")) ]), vue.createElementVNode("view", { class: "option-wrapper" }, [ vue.createElementVNode("view", { class: "opt-btn opt-cancel", - onClick: $setup.closeNewTableModal + onClick: $setup.closeUploadDbModal }, "取消"), vue.createElementVNode("view", { class: "opt-btn opt-confirm", - onClick: $setup.confirmCreateTable - }, "确认") + onClick: $setup.confirmUploadDb + }, "确认上传") ]) ]) ])) : vue.createCommentVNode("v-if", true), @@ -10775,30 +11485,34 @@ This will fail in production.`); 1 /* TEXT */ ), - vue.createElementVNode("view", { class: "navbar-right" }, [ - $setup.isSelectFolder ? (vue.openBlock(), vue.createElementBlock("view", { - key: 0, - class: "navbar-right-text", - onClick: $setup.handleSelectFolder - }, "完成")) : (vue.openBlock(), vue.createElementBlock( - "view", - { - key: 1, - class: vue.normalizeClass(["iconfont icon-gengduo", $setup.isMenuOpen ? "menu-open" : "custom-navbar-icon"]), - onClick: $setup.handleMenu - }, - null, - 2 - /* CLASS */ - )) - ]) + vue.createElementVNode("view", { class: "navbar-right" }), + $setup.isMenuOpen ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "menu-card" + }, [ + vue.createElementVNode("view", { + class: "menu-card-item", + onClick: _cache[12] || (_cache[12] = ($event) => { + $setup.handleSelectFolder(); + $setup.handleMenu(); + }) + }, "选择"), + vue.createElementVNode("view", { class: "solid-line" }), + vue.createElementVNode("view", { + class: "menu-card-item", + onClick: _cache[13] || (_cache[13] = ($event) => { + $setup.openNewFolderModal(); + $setup.handleMenu(); + }) + }, "新建文件夹") + ])) : vue.createCommentVNode("v-if", true) ]), vue.createElementVNode("view", { class: "category-tabs" }, [ vue.createElementVNode( "view", { class: vue.normalizeClass(["category-tab", { active: $setup.currentCategory === "user" }]), - onClick: _cache[12] || (_cache[12] = ($event) => $setup.switchCategory("user")) + onClick: _cache[14] || (_cache[14] = ($event) => $setup.switchCategory("user")) }, " 个人 ", 2 @@ -10808,7 +11522,7 @@ This will fail in production.`); "view", { class: vue.normalizeClass(["category-tab", { active: $setup.currentCategory === "team" }]), - onClick: _cache[13] || (_cache[13] = ($event) => $setup.switchCategory("team")) + onClick: _cache[15] || (_cache[15] = ($event) => $setup.switchCategory("team")) }, " 团队 ", 2 @@ -10929,40 +11643,64 @@ This will fail in production.`); vue.createElementVNode("view", { class: "section-header" }, [ vue.createElementVNode("view", { class: "section-title" }, [ vue.createElementVNode("view", { class: "iconfont icon-shujuku" }), - vue.createElementVNode("text", null, "云端数据库") + vue.createElementVNode("text", null, "云端数据库"), + vue.createElementVNode( + "text", + { class: "file-count" }, + vue.toDisplayString(!$setup.isDbLoading && $setup.personalDatabases.length > 0 ? "(" + $setup.personalDatabases.length + ")" : ""), + 1 + /* TEXT */ + ) ]), vue.createElementVNode("view", { class: "section-actions" }, [ vue.createElementVNode("view", { class: "action-btn", - onClick: $setup.openNewTableModal + onClick: $setup.openUploadDbModal + }, [ + vue.createVNode(_component_uni_icons, { + type: "upload", + size: "16" + }), + vue.createElementVNode("text", null, "上传数据库") + ]), + vue.createElementVNode("view", { + class: "action-btn", + onClick: $setup.openNewDbModal }, [ vue.createVNode(_component_uni_icons, { type: "plus", size: "16" }), - vue.createElementVNode("text", null, "新建表") + vue.createElementVNode("text", null, "新建数据库") ]) ]) ]), vue.createElementVNode("view", { class: "section-body" }, [ - $setup.personalTables.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + $setup.isDbLoading ? (vue.openBlock(), vue.createElementBlock("view", { key: 0, + class: "loading-area" + }, [ + vue.createElementVNode("view", { class: "loading-spinner" }), + vue.createElementVNode("text", { class: "loading-text" }, "加载中...") + ])) : $setup.personalDatabases.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 1, class: "empty-tip" }, [ vue.createElementVNode("view", { class: "iconfont icon-shujuku" }), - vue.createElementVNode("text", null, "暂无数据表") + vue.createElementVNode("text", null, "暂无数据库") ])) : (vue.openBlock(), vue.createElementBlock("view", { - key: 1, + key: 2, class: "table-list" }, [ (vue.openBlock(true), vue.createElementBlock( vue.Fragment, null, - vue.renderList($setup.personalTables, (table) => { + vue.renderList($setup.personalDatabases, (db) => { return vue.openBlock(), vue.createElementBlock("view", { class: "table-item", - key: table.id, - onClick: ($event) => $setup.handleTableClick(table) + key: db.database_id, + onClick: ($event) => $setup.handleDbClick(db), + onLongpress: ($event) => $setup.handleDeleteDb(db) }, [ vue.createElementVNode("view", { class: "table-icon" }, [ vue.createVNode(_component_uni_icons, { @@ -10972,17 +11710,26 @@ This will fail in production.`); }) ]), vue.createElementVNode("view", { class: "table-info" }, [ - vue.createElementVNode( - "view", - { class: "table-name" }, - vue.toDisplayString(table.name), - 1 - /* TEXT */ - ), + vue.createElementVNode("view", { class: "table-name" }, [ + vue.createTextVNode( + vue.toDisplayString(db.database_name) + " ", + 1 + /* TEXT */ + ), + vue.createElementVNode( + "text", + { + class: vue.normalizeClass(["db-tag", db.team_id ? "tag-team" : "tag-personal"]) + }, + vue.toDisplayString(db.team_id ? "团队共享" : "个人私有"), + 3 + /* TEXT, CLASS */ + ) + ]), vue.createElementVNode( "view", { class: "table-desc" }, - vue.toDisplayString(table.desc || "无描述"), + vue.toDisplayString(db.table_count || 0) + " 张表 · " + vue.toDisplayString($setup.getAccessLevelLabel(db.access_level)), 1 /* TEXT */ ) @@ -10991,7 +11738,7 @@ This will fail in production.`); vue.createElementVNode( "text", { class: "table-rows" }, - vue.toDisplayString(table.rowCount || 0) + " 条记录", + vue.toDisplayString($setup.formatDbTime(db.modified_time)), 1 /* TEXT */ ), @@ -11001,7 +11748,7 @@ This will fail in production.`); color: "#999" }) ]) - ], 8, ["onClick"]); + ], 40, ["onClick", "onLongpress"]); }), 128 /* KEYED_FRAGMENT */ @@ -11206,39 +11953,33 @@ This will fail in production.`); vue.createElementVNode("view", { class: "section-title" }, [ vue.createElementVNode("view", { class: "iconfont icon-shujuku" }), vue.createElementVNode("text", null, "团队云端数据库") - ]), - vue.createElementVNode("view", { class: "section-actions" }, [ - vue.createElementVNode("view", { - class: "action-btn", - onClick: $setup.openNewTableModal - }, [ - vue.createVNode(_component_uni_icons, { - type: "plus", - size: "16" - }), - vue.createElementVNode("text", null, "新建表") - ]) ]) ]), vue.createElementVNode("view", { class: "section-body" }, [ - $setup.teamTables.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + $setup.isDbLoading ? (vue.openBlock(), vue.createElementBlock("view", { key: 0, + class: "loading-area" + }, [ + vue.createElementVNode("view", { class: "loading-spinner" }), + vue.createElementVNode("text", { class: "loading-text" }, "加载中...") + ])) : $setup.teamDatabases.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 1, class: "empty-tip" }, [ vue.createElementVNode("view", { class: "iconfont icon-shujuku" }), - vue.createElementVNode("text", null, "暂无团队数据表") + vue.createElementVNode("text", null, "暂无团队数据库") ])) : (vue.openBlock(), vue.createElementBlock("view", { - key: 1, + key: 2, class: "table-list" }, [ (vue.openBlock(true), vue.createElementBlock( vue.Fragment, null, - vue.renderList($setup.teamTables, (table) => { + vue.renderList($setup.teamDatabases, (db) => { return vue.openBlock(), vue.createElementBlock("view", { class: "table-item", - key: table.id, - onClick: ($event) => $setup.handleTableClick(table) + key: db.database_id, + onClick: ($event) => $setup.handleDbClick(db) }, [ vue.createElementVNode("view", { class: "table-icon" }, [ vue.createVNode(_component_uni_icons, { @@ -11248,17 +11989,18 @@ This will fail in production.`); }) ]), vue.createElementVNode("view", { class: "table-info" }, [ - vue.createElementVNode( - "view", - { class: "table-name" }, - vue.toDisplayString(table.name), - 1 - /* TEXT */ - ), + vue.createElementVNode("view", { class: "table-name" }, [ + vue.createTextVNode( + vue.toDisplayString(db.database_name) + " ", + 1 + /* TEXT */ + ), + vue.createElementVNode("text", { class: "db-tag tag-team" }, "团队共享") + ]), vue.createElementVNode( "view", { class: "table-desc" }, - vue.toDisplayString(table.desc || "无描述"), + vue.toDisplayString(db.table_count || 0) + " 张表 · " + vue.toDisplayString($setup.getAccessLevelLabel(db.access_level)), 1 /* TEXT */ ) @@ -11267,7 +12009,7 @@ This will fail in production.`); vue.createElementVNode( "text", { class: "table-rows" }, - vue.toDisplayString(table.rowCount || 0) + " 条记录", + vue.toDisplayString($setup.formatDbTime(db.modified_time)), 1 /* TEXT */ ), @@ -11296,7 +12038,967 @@ This will fail in production.`); /* STABLE_FRAGMENT */ ); } - const PagesCloudDatabaseCloudDatabase = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render], ["__scopeId", "data-v-51006ffb"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/CloudDatabase/CloudDatabase.vue"]]); + const PagesCloudDatabaseCloudDatabase = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$1], ["__scopeId", "data-v-51006ffb"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/CloudDatabase/CloudDatabase.vue"]]); + const _sfc_main$1 = { + __name: "CloudDbDetail", + props: { + databaseId: { + type: String, + default: "" + }, + databaseName: { + type: String, + default: "" + }, + teamId: { + type: String, + default: "" + } + }, + setup(__props, { expose: __expose }) { + __expose(); + const props = __props; + const databaseId = vue.ref(props.databaseId || ""); + const databaseName = vue.ref(props.databaseName || ""); + const teamId = vue.ref(props.teamId || ""); + const dbAccessLevel = vue.ref(2); + const dbTableCount = vue.ref(0); + const tableList = vue.ref([]); + const isTableLoading = vue.ref(false); + const currentTable = vue.ref(null); + const tableData = vue.ref([]); + const tableColumns = vue.computed(() => { + var _a; + if (tableData.value.length > 0) { + const keys = /* @__PURE__ */ new Set(); + tableData.value.forEach((row) => Object.keys(row).forEach((k) => keys.add(k))); + return Array.from(keys).filter((k) => k !== "_row_id" && k !== "_id"); + } + if ((_a = currentTable.value) == null ? void 0 : _a.columns) { + return currentTable.value.columns.map((c) => c.name).filter((n2) => n2 !== "_row_id"); + } + return []; + }); + const isMenuOpen = vue.ref(false); + const handleMenu = () => { + isMenuOpen.value = !isMenuOpen.value; + }; + const handleBack = () => { + uni.navigateBack(); + }; + const fetchTables = async () => { + isTableLoading.value = true; + try { + const token = getToken(); + const tables = await getCloudDbTables(token, databaseId.value, true); + tableList.value = (tables || []).map((t2) => ({ + table_name: t2.name, + row_count: t2.row_count || 0, + columns: t2.columns || [] + })); + dbTableCount.value = tableList.value.length; + } catch (error) { + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:282", "获取表列表失败:", error); + tableList.value = []; + } finally { + isTableLoading.value = false; + } + }; + const selectTable = async (table) => { + currentTable.value = table; + tableData.value = []; + uni.showLoading({ + title: "加载中..." + }); + try { + const token = getToken(); + const data = await getCloudDbTableData(token, databaseId.value, table.table_name); + tableData.value = data || []; + uni.hideLoading(); + } catch (err) { + uni.hideLoading(); + uni.showToast({ + title: typeof err === "string" ? err : "加载表数据失败", + icon: "none" + }); + tableData.value = []; + } + }; + const handleDeleteTable = (table) => { + uni.showModal({ + title: "删除表", + content: `确定要删除表"${table.table_name}"吗?此操作不可恢复。`, + success: async (res) => { + var _a; + if (res.confirm) { + uni.showLoading({ + title: "删除中..." + }); + try { + const token = getToken(); + await deleteCloudDbTable(token, databaseId.value, table.table_name); + uni.hideLoading(); + uni.showToast({ + title: "删除成功", + icon: "success" + }); + if (((_a = currentTable.value) == null ? void 0 : _a.table_name) === table.table_name) { + currentTable.value = null; + tableData.value = []; + } + await fetchTables(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:335", "删除表失败:", error); + uni.showToast({ + title: "删除失败,请重试", + icon: "error" + }); + } + } + } + }); + }; + const openEditRow = (row) => { + const rowId = row._row_id || row._id; + if (!rowId) { + uni.showToast({ + title: "无法识别该行", + icon: "none" + }); + return; + } + const columns = tableColumns.value; + if (columns.length === 0) { + uni.showToast({ + title: "无可用列", + icon: "none" + }); + return; + } + const firstCol = columns[0]; + uni.showModal({ + title: `编辑 ${firstCol}`, + editable: true, + placeholderText: row[firstCol] || "", + content: "", + success: async (res) => { + if (res.confirm && res.content !== void 0) { + uni.showLoading({ + title: "更新中..." + }); + try { + const token = getToken(); + await updateCloudDbTableData( + token, + databaseId.value, + currentTable.value.table_name, + { + _row_id: rowId + }, + { + [firstCol]: res.content + } + ); + uni.hideLoading(); + uni.showToast({ + title: "更新成功", + icon: "success" + }); + row[firstCol] = res.content; + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:397", "更新失败:", error); + uni.showToast({ + title: error, + icon: "error" + }); + } + } + } + }); + }; + const showNewTable = vue.ref(false); + const importTableName = vue.ref(""); + const importFileName = vue.ref(""); + const importFilePath = vue.ref(""); + const openImportModal = () => { + showNewTable.value = true; + importTableName.value = ""; + importFileName.value = ""; + importFilePath.value = ""; + }; + const closeNewTableModal = () => { + showNewTable.value = false; + }; + const handlePickFile = () => { + chooseFile({ + count: 1, + type: "all", + success: (res) => { + const file = res.tempFiles[0]; + importFileName.value = file.name || "unknown"; + importFilePath.value = file.path; + }, + fail: (err) => { + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:434", "选择文件失败:", err); + uni.showToast({ + title: "选择文件失败", + icon: "none" + }); + } + }); + }; + const confirmImportFile = async () => { + const tableName = importTableName.value.trim() || ""; + if (!importFilePath.value) { + uni.showToast({ + title: "请选择文件", + icon: "none" + }); + return; + } + uni.showLoading({ + title: "导入中..." + }); + try { + const token = getToken(); + await importFileToCloudDb(token, false, databaseId.value, importFilePath.value, tableName); + uni.hideLoading(); + uni.showToast({ + title: "导入成功", + icon: "success" + }); + closeNewTableModal(); + await fetchTables(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:474", "导入失败:", error); + if (error === "table_exists") { + uni.showToast({ + title: "文件已存在", + icon: "error" + }); + } else { + uni.showToast({ + title: "导入失败,请重试", + icon: "error" + }); + } + } + }; + const showPermission = vue.ref(false); + const permissionList = vue.ref([]); + const openPermissionModal = async () => { + showPermission.value = true; + uni.showLoading({ + title: "加载中..." + }); + try { + const token = getToken(); + let result; + if (teamId.value) { + result = await getCloudDbPermission(token, databaseId.value, "team_id", teamId.value); + } else { + result = await getCloudDbPermission(token, databaseId.value, "user_id", getUserId()); + } + const rawList = Array.isArray(result) ? result : []; + permissionList.value = rawList.map((item) => { + var _a, _b, _c; + if (item.team) { + return { + _id: item._id, + database_id: item.database_id, + access_level: item.access_level, + permType: "team_id", + id: item.team._id || item.team.id, + name: item.team.name + }; + } else if (item.team_id) { + return { + database_id: item.database_id, + access_level: item.access_level, + permType: "team_id", + id: item.team_id, + name: ((_a = item.database) == null ? void 0 : _a.database_name) || "" + }; + } else { + return { + database_id: item.database_id, + access_level: item.access_level, + permType: "user_id", + id: item.user_id || ((_b = item.database) == null ? void 0 : _b.user_id) || getUserId(), + name: ((_c = item.database) == null ? void 0 : _c.database_name) || "" + }; + } + }); + } catch (error) { + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:544", "获取权限失败:", error); + permissionList.value = []; + } + uni.hideLoading(); + }; + const closePermissionModal = () => { + showPermission.value = false; + }; + const changePermission = (perm, action) => { + if (action === "delete") { + uni.showModal({ + title: "移除权限", + content: `确定要移除"${perm.name}"的权限吗?`, + success: async (res) => { + if (res.confirm) { + uni.showLoading({ + title: "移除中..." + }); + try { + const token = getToken(); + await deleteCloudDbPermission(token, databaseId.value, perm.permType, perm.id); + uni.hideLoading(); + uni.showToast({ + title: "已移除", + icon: "success" + }); + await openPermissionModal(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:574", "移除权限失败:", error); + uni.showToast({ + title: "操作失败,请重试", + icon: "error" + }); + } + } + } + }); + } else { + const levels = ["无权限访问", "仅访问", "管理员完全控制", "团队完全控制"]; + const currentLevel = perm.access_level || 0; + uni.showActionSheet({ + title: "选择权限级别", + itemList: levels.map((label, idx) => `${idx}. ${label}`), + success: async (res) => { + const newLevel = res.tapIndex; + if (newLevel === currentLevel) + return; + uni.showLoading({ + title: "更新中..." + }); + try { + const token = getToken(); + await updateCloudDbPermission( + token, + databaseId.value, + perm.permType, + perm.id, + newLevel + ); + uni.hideLoading(); + uni.showToast({ + title: "已更新", + icon: "success" + }); + await openPermissionModal(); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:608", "更新权限失败:", error); + uni.showToast({ + title: "操作失败,请重试", + icon: "error" + }); + } + } + }); + } + }; + const showTransfer = vue.ref(false); + const teamList = vue.ref([]); + const selectedTeamId = vue.ref(""); + const openTransferModal = async () => { + showTransfer.value = true; + selectedTeamId.value = ""; + try { + const token = getToken(); + const teams = await getTeamList(token); + teamList.value = teams || []; + } catch (error) { + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:632", "获取团队列表失败:", error); + teamList.value = []; + } + }; + const closeTransferModal = () => { + showTransfer.value = false; + }; + const confirmTransfer = async () => { + if (!selectedTeamId.value) { + uni.showToast({ + title: "请选择目标团队", + icon: "none" + }); + return; + } + uni.showModal({ + title: "确认移交", + content: "移交后数据库将归属于该团队,确定继续吗?", + success: async (res) => { + if (res.confirm) { + uni.showLoading({ + title: "移交中..." + }); + try { + const token = getToken(); + await dbTransferToTeam(token, databaseId.value, selectedTeamId.value); + uni.hideLoading(); + uni.showToast({ + title: "移交成功", + icon: "success" + }); + closeTransferModal(); + setTimeout(() => { + uni.navigateBack(); + }, 1e3); + } catch (error) { + uni.hideLoading(); + formatAppLog("error", "at pages/CloudDbDetail/CloudDbDetail.vue:670", "移交失败:", error); + uni.showToast({ + title: "移交失败,请重试", + icon: "error" + }); + } + } + } + }); + }; + const getAccessLevelLabel = (level) => { + const labels = { + 0: "无权限访问", + 1: "仅访问", + 2: "管理员完全控制", + 3: "团队完全控制" + }; + return labels[level] || "未知"; + }; + const formatCellValue = (val) => { + if (val === null || val === void 0) + return ""; + if (typeof val === "object") + return JSON.stringify(val); + return String(val); + }; + vue.onMounted(() => { + var _a; + const pages = getCurrentPages(); + const currentPage = pages[pages.length - 1]; + const options = ((_a = currentPage.$page) == null ? void 0 : _a.options) || currentPage.options || {}; + databaseId.value = options.databaseId || ""; + databaseName.value = decodeURIComponent(options.databaseName || "数据库详情"); + teamId.value = options.teamId || ""; + if (databaseId.value) { + fetchTables(); + } + }); + const __returned__ = { props, databaseId, databaseName, teamId, dbAccessLevel, dbTableCount, tableList, isTableLoading, currentTable, tableData, tableColumns, isMenuOpen, handleMenu, handleBack, fetchTables, selectTable, handleDeleteTable, openEditRow, showNewTable, importTableName, importFileName, importFilePath, openImportModal, closeNewTableModal, handlePickFile, confirmImportFile, showPermission, permissionList, openPermissionModal, closePermissionModal, changePermission, showTransfer, teamList, selectedTeamId, openTransferModal, closeTransferModal, confirmTransfer, getAccessLevelLabel, formatCellValue, onMounted: vue.onMounted, ref: vue.ref, computed: vue.computed, get getToken() { + return getToken; + }, get getUserId() { + return getUserId; + }, get chooseFile() { + return chooseFile; + }, get getCloudDbTables() { + return getCloudDbTables; + }, get deleteCloudDbTable() { + return deleteCloudDbTable; + }, get getCloudDbTableData() { + return getCloudDbTableData; + }, get updateCloudDbTableData() { + return updateCloudDbTableData; + }, get importFileToCloudDb() { + return importFileToCloudDb; + }, get getCloudDbPermission() { + return getCloudDbPermission; + }, get deleteCloudDbPermission() { + return deleteCloudDbPermission; + }, get updateCloudDbPermission() { + return updateCloudDbPermission; + }, get dbTransferToTeam() { + return dbTransferToTeam; + }, get getTeamList() { + return getTeamList; + } }; + Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true }); + return __returned__; + } + }; + function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { + const _component_uni_icons = resolveEasycom(vue.resolveDynamicComponent("uni-icons"), __easycom_0); + return vue.openBlock(), vue.createElementBlock("view", { class: "cloud-db-detail-wrapper" }, [ + vue.createElementVNode("view", { class: "status-bar" }), + $setup.showNewTable ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "popup-overlay", + onClick: $setup.closeNewTableModal + }, [ + vue.createElementVNode("view", { + class: "popup-card", + onClick: _cache[1] || (_cache[1] = vue.withModifiers(() => { + }, ["stop"])) + }, [ + vue.createElementVNode("view", { + class: "close-popup-card", + onClick: $setup.closeNewTableModal + }, [ + vue.createElementVNode("view", { class: "iconfont icon-quxiao" }) + ]), + vue.createElementVNode("view", { class: "popup-title" }, "导入文件到数据库"), + vue.createElementVNode("view", { class: "new-folder-name" }, "表名称"), + vue.createElementVNode("view", { class: "create-folder-name" }, [ + vue.withDirectives(vue.createElementVNode( + "input", + { + "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => $setup.importTableName = $event), + type: "text", + placeholder: "输入表名称" + }, + null, + 512 + /* NEED_PATCH */ + ), [ + [vue.vModelText, $setup.importTableName] + ]) + ]), + vue.createElementVNode("view", { class: "new-folder-name" }, "文件"), + vue.createElementVNode("view", { + class: "upload-file-area", + onClick: $setup.handlePickFile + }, [ + $setup.importFileName ? (vue.openBlock(), vue.createElementBlock( + "view", + { + key: 0, + class: "selected-file" + }, + vue.toDisplayString($setup.importFileName), + 1 + /* TEXT */ + )) : (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "upload-hint" + }, "点击选择文件(支持 CSV/Excel/SQLite)")) + ]), + vue.createElementVNode("view", { class: "option-wrapper" }, [ + vue.createElementVNode("view", { + class: "opt-btn opt-cancel", + onClick: $setup.closeNewTableModal + }, "取消"), + vue.createElementVNode("view", { + class: "opt-btn opt-confirm", + onClick: $setup.confirmImportFile + }, "确认导入") + ]) + ]) + ])) : vue.createCommentVNode("v-if", true), + $setup.showPermission ? (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "popup-overlay", + onClick: $setup.closePermissionModal + }, [ + vue.createElementVNode("view", { + class: "popup-card", + onClick: _cache[2] || (_cache[2] = vue.withModifiers(() => { + }, ["stop"])) + }, [ + vue.createElementVNode("view", { + class: "close-popup-card", + onClick: $setup.closePermissionModal + }, [ + vue.createElementVNode("view", { class: "iconfont icon-quxiao" }) + ]), + vue.createElementVNode("view", { class: "popup-title" }, "权限管理"), + vue.createElementVNode("scroll-view", { + class: "permission-body", + "scroll-y": "" + }, [ + $setup.permissionList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "folder-null" + }, "暂无权限记录")) : (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "permission-list" + }, [ + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.permissionList, (perm) => { + return vue.openBlock(), vue.createElementBlock("view", { + class: "permission-item", + key: perm._id || perm.id + }, [ + vue.createElementVNode("view", { class: "perm-info" }, [ + vue.createElementVNode( + "text", + { class: "perm-type" }, + vue.toDisplayString(perm.permType === "team_id" ? "团队" : "个人"), + 1 + /* TEXT */ + ) + ]), + vue.createElementVNode( + "view", + { class: "perm-level" }, + vue.toDisplayString($setup.getAccessLevelLabel(perm.access_level)), + 1 + /* TEXT */ + ), + vue.createElementVNode("view", { class: "perm-actions" }, [ + vue.createElementVNode("view", { + class: "perm-action-btn", + onClick: ($event) => $setup.changePermission(perm, "change") + }, "修改", 8, ["onClick"]), + vue.createElementVNode("view", { + class: "perm-action-btn delete", + onClick: ($event) => $setup.changePermission(perm, "delete") + }, "移除", 8, ["onClick"]) + ]) + ]); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ])) + ]), + vue.createElementVNode("view", { + class: "close-permission-btn", + onClick: $setup.closePermissionModal + }, "关闭") + ]) + ])) : vue.createCommentVNode("v-if", true), + $setup.showTransfer ? (vue.openBlock(), vue.createElementBlock("view", { + key: 2, + class: "popup-overlay", + onClick: $setup.closeTransferModal + }, [ + vue.createElementVNode("view", { + class: "popup-card", + onClick: _cache[3] || (_cache[3] = vue.withModifiers(() => { + }, ["stop"])) + }, [ + vue.createElementVNode("view", { + class: "close-popup-card", + onClick: $setup.closeTransferModal + }, [ + vue.createElementVNode("view", { class: "iconfont icon-quxiao" }) + ]), + vue.createElementVNode("view", { class: "popup-title" }, "移交数据库到团队"), + vue.createElementVNode("scroll-view", { + class: "transfer-body", + "scroll-y": "" + }, [ + $setup.teamList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "folder-null" + }, "暂无可用团队")) : (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "transfer-list" + }, [ + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.teamList, (team) => { + return vue.openBlock(), vue.createElementBlock("view", { + class: vue.normalizeClass(["transfer-item", { active: $setup.selectedTeamId === team.id }]), + key: team.id, + onClick: ($event) => $setup.selectedTeamId = team.id + }, [ + vue.createElementVNode( + "text", + { class: "transfer-name" }, + vue.toDisplayString(team.name), + 1 + /* TEXT */ + ), + $setup.selectedTeamId === team.id ? (vue.openBlock(), vue.createBlock(_component_uni_icons, { + key: 0, + type: "checkmarkempty", + size: "20", + color: "#3b86ff" + })) : vue.createCommentVNode("v-if", true) + ], 10, ["onClick"]); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ])) + ]), + vue.createElementVNode("view", { class: "option-wrapper" }, [ + vue.createElementVNode("view", { + class: "opt-btn opt-cancel", + onClick: $setup.closeTransferModal + }, "取消"), + vue.createElementVNode("view", { + class: "opt-btn opt-confirm", + onClick: $setup.confirmTransfer + }, "确认移交") + ]) + ]) + ])) : vue.createCommentVNode("v-if", true), + vue.createElementVNode("view", { class: "cloud-db-detail page-container" }, [ + vue.createElementVNode("view", { class: "cloud-db-header" }, [ + vue.createElementVNode("view", { class: "custom-navbar" }, [ + vue.createElementVNode("view", { + class: "navbar-left", + onClick: $setup.handleBack + }, [ + vue.createElementVNode("view", { class: "iconfont icon-fanhui custom-navbar-icon" }) + ]), + vue.createElementVNode( + "view", + { class: "navbar-title" }, + vue.toDisplayString($setup.databaseName), + 1 + /* TEXT */ + ), + vue.createElementVNode("view", { class: "navbar-right" }, [ + vue.createElementVNode("view", { + class: "iconfont icon-gengduo custom-navbar-icon", + onClick: $setup.handleMenu + }) + ]) + ]), + $setup.isMenuOpen ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "menu-card" + }, [ + vue.createElementVNode("view", { + class: "menu-card-item", + onClick: _cache[4] || (_cache[4] = ($event) => { + $setup.openImportModal(); + $setup.handleMenu(); + }) + }, "导入文件"), + vue.createElementVNode("view", { class: "solid-line" }), + vue.createElementVNode("view", { + class: "menu-card-item", + onClick: _cache[5] || (_cache[5] = ($event) => { + $setup.openPermissionModal(); + $setup.handleMenu(); + }) + }, "权限管理"), + !$setup.teamId ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "solid-line" + })) : vue.createCommentVNode("v-if", true), + !$setup.teamId ? (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "menu-card-item", + onClick: _cache[6] || (_cache[6] = ($event) => { + $setup.openTransferModal(); + $setup.handleMenu(); + }) + }, "移交团队")) : vue.createCommentVNode("v-if", true) + ])) : vue.createCommentVNode("v-if", true) + ]), + vue.createElementVNode("scroll-view", { + class: "cloud-db-content", + "scroll-y": "" + }, [ + vue.createElementVNode("view", { class: "db-info-bar" }, [ + vue.createElementVNode( + "text", + { class: "db-info-text" }, + vue.toDisplayString($setup.dbTableCount) + " 张表", + 1 + /* TEXT */ + ), + vue.createElementVNode( + "text", + { class: "db-info-text" }, + "权限:" + vue.toDisplayString($setup.getAccessLevelLabel($setup.dbAccessLevel)), + 1 + /* TEXT */ + ) + ]), + vue.createElementVNode("view", { class: "section-block" }, [ + vue.createElementVNode("view", { class: "section-header" }, [ + vue.createElementVNode("view", { class: "section-title" }, [ + vue.createElementVNode("view", { class: "iconfont icon-biaoge" }), + vue.createElementVNode("text", null, "数据表") + ]) + ]), + vue.createElementVNode("view", { class: "section-body" }, [ + $setup.isTableLoading ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "loading-area" + }, [ + vue.createElementVNode("view", { class: "loading-spinner" }), + vue.createElementVNode("text", { class: "loading-text" }, "加载中...") + ])) : $setup.tableList.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "empty-tip" + }, [ + vue.createElementVNode("view", { class: "iconfont icon-shujuku" }), + vue.createElementVNode("text", null, "暂无数据表") + ])) : (vue.openBlock(), vue.createElementBlock("view", { + key: 2, + class: "table-list" + }, [ + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.tableList, (table) => { + return vue.openBlock(), vue.createElementBlock("view", { + class: "table-item", + key: table.table_name, + onClick: ($event) => $setup.selectTable(table), + onLongpress: ($event) => $setup.handleDeleteTable(table) + }, [ + vue.createElementVNode("view", { class: "table-icon" }, [ + vue.createVNode(_component_uni_icons, { + type: "compose", + size: "22", + color: "#3b86ff" + }) + ]), + vue.createElementVNode("view", { class: "table-info" }, [ + vue.createElementVNode( + "view", + { class: "table-name" }, + vue.toDisplayString(table.table_name), + 1 + /* TEXT */ + ), + vue.createElementVNode( + "view", + { class: "table-desc" }, + vue.toDisplayString(table.row_count || 0) + " 条记录", + 1 + /* TEXT */ + ) + ]), + vue.createElementVNode("view", { class: "table-meta" }, [ + vue.createVNode(_component_uni_icons, { + type: "right", + size: "14", + color: "#999" + }) + ]) + ], 40, ["onClick", "onLongpress"]); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ])) + ]) + ]), + $setup.currentTable ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "section-block" + }, [ + vue.createElementVNode("view", { class: "section-divider" }), + vue.createElementVNode("view", { class: "section-header" }, [ + vue.createElementVNode("view", { class: "section-title" }, [ + vue.createElementVNode("view", { class: "iconfont icon-biaoge" }), + vue.createElementVNode( + "text", + null, + vue.toDisplayString($setup.currentTable.table_name), + 1 + /* TEXT */ + ) + ]), + vue.createElementVNode("view", { class: "section-actions" }, [ + vue.createElementVNode( + "text", + { class: "row-count" }, + vue.toDisplayString($setup.tableData.length) + " / " + vue.toDisplayString($setup.currentTable.row_count || 0) + " 条", + 1 + /* TEXT */ + ) + ]) + ]), + vue.createElementVNode("view", { class: "section-body" }, [ + $setup.tableData.length === 0 ? (vue.openBlock(), vue.createElementBlock("view", { + key: 0, + class: "empty-tip" + }, [ + vue.createElementVNode("text", null, "暂无数据") + ])) : (vue.openBlock(), vue.createElementBlock("view", { + key: 1, + class: "data-table-wrapper" + }, [ + vue.createElementVNode("scroll-view", { + "scroll-x": "", + class: "data-table-scroll" + }, [ + vue.createElementVNode("view", { class: "data-table" }, [ + vue.createElementVNode("view", { class: "data-row data-header" }, [ + vue.createElementVNode("view", { class: "data-cell index-cell" }, "#"), + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.tableColumns, (col) => { + return vue.openBlock(), vue.createElementBlock( + "view", + { + key: col, + class: "data-cell" + }, + vue.toDisplayString(col), + 1 + /* TEXT */ + ); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ]), + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.tableData, (row, rowIdx) => { + return vue.openBlock(), vue.createElementBlock("view", { + class: "data-row", + key: row._row_id || rowIdx, + onClick: ($event) => $setup.openEditRow(row) + }, [ + vue.createElementVNode( + "view", + { class: "data-cell index-cell" }, + vue.toDisplayString(rowIdx + 1), + 1 + /* TEXT */ + ), + (vue.openBlock(true), vue.createElementBlock( + vue.Fragment, + null, + vue.renderList($setup.tableColumns, (col) => { + return vue.openBlock(), vue.createElementBlock( + "view", + { + key: col, + class: "data-cell" + }, + vue.toDisplayString($setup.formatCellValue(row[col])), + 1 + /* TEXT */ + ); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ], 8, ["onClick"]); + }), + 128 + /* KEYED_FRAGMENT */ + )) + ]) + ]) + ])) + ]) + ])) : vue.createCommentVNode("v-if", true) + ]) + ]) + ]); + } + const PagesCloudDbDetailCloudDbDetail = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render], ["__scopeId", "data-v-96fa4671"], ["__file", "D:/Projects/uniapp/app-test/test1/pages/CloudDbDetail/CloudDbDetail.vue"]]); __definePage("pages/Login/Login", PagesLoginLogin); __definePage("pages/Chat/Chat", PagesChatChat); __definePage("pages/WorkSpace/WorkSpace", PagesWorkSpaceWorkSpace); @@ -11306,6 +13008,7 @@ This will fail in production.`); __definePage("pages/text/text", PagesTextText); __definePage("pages/text/text2", PagesTextText2); __definePage("pages/CloudDatabase/CloudDatabase", PagesCloudDatabaseCloudDatabase); + __definePage("pages/CloudDbDetail/CloudDbDetail", PagesCloudDbDetailCloudDbDetail); const _sfc_main = { onLaunch: function() { formatAppLog("log", "at App.vue:4", "App Launch"); diff --git a/unpackage/dist/dev/app-plus/manifest.json b/unpackage/dist/dev/app-plus/manifest.json index 703d9f6..e24e9c0 100644 --- a/unpackage/dist/dev/app-plus/manifest.json +++ b/unpackage/dist/dev/app-plus/manifest.json @@ -7,7 +7,7 @@ "id": "__UNI__923FD9E", "name": "test1", "version": { - "name": "1.0.0", + "name": "1.1.1", "code": "1" }, "description": "", @@ -46,6 +46,46 @@ "nvueStyleCompiler": "uni-app", "compilerVersion": 3, "distribute": { + "icons": { + "android": { + "hdpi": "unpackage/res/icons/72x72.png", + "xhdpi": "unpackage/res/icons/96x96.png", + "xxhdpi": "unpackage/res/icons/144x144.png", + "xxxhdpi": "unpackage/res/icons/192x192.png" + }, + "ios": { + "appstore": "unpackage/res/icons/1024x1024.png", + "ipad": { + "app": "unpackage/res/icons/76x76.png", + "app@2x": "unpackage/res/icons/152x152.png", + "notification": "unpackage/res/icons/20x20.png", + "notification@2x": "unpackage/res/icons/40x40.png", + "proapp@2x": "unpackage/res/icons/167x167.png", + "settings": "unpackage/res/icons/29x29.png", + "settings@2x": "unpackage/res/icons/58x58.png", + "spotlight": "unpackage/res/icons/40x40.png", + "spotlight@2x": "unpackage/res/icons/80x80.png" + }, + "iphone": { + "app@2x": "unpackage/res/icons/120x120.png", + "app@3x": "unpackage/res/icons/180x180.png", + "notification@2x": "unpackage/res/icons/40x40.png", + "notification@3x": "unpackage/res/icons/60x60.png", + "settings@2x": "unpackage/res/icons/58x58.png", + "settings@3x": "unpackage/res/icons/87x87.png", + "spotlight@2x": "unpackage/res/icons/80x80.png", + "spotlight@3x": "unpackage/res/icons/120x120.png" + } + } + }, + "splashscreen": { + "androidStyle": "default", + "android": { + "hdpi": "C:/Users/ADMIN/Pictures/480-762.png", + "xhdpi": "C:/Users/ADMIN/Pictures/720-1242.png", + "xxhdpi": "C:/Users/ADMIN/Pictures/1080-1882.png" + } + }, "google": { "permissions": [ "", diff --git a/unpackage/dist/dev/app-plus/pages/CloudDatabase/CloudDatabase.css b/unpackage/dist/dev/app-plus/pages/CloudDatabase/CloudDatabase.css index c177277..1bc4f43 100644 --- a/unpackage/dist/dev/app-plus/pages/CloudDatabase/CloudDatabase.css +++ b/unpackage/dist/dev/app-plus/pages/CloudDatabase/CloudDatabase.css @@ -1276,3 +1276,81 @@ margin-bottom: 0.625rem; text-align: center; } + +/* ===== 加载动画 ===== */ +.loading-area[data-v-51006ffb] { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 1.875rem 0; + gap: 0.5rem; +} +.loading-spinner[data-v-51006ffb] { + width: 1.75rem; + height: 1.75rem; + border: 0.125rem solid #e8e8e8; + border-top-color: #3b86ff; + border-radius: 50%; + animation: spin-51006ffb 0.8s linear infinite; +} +@keyframes spin-51006ffb { +to { + transform: rotate(360deg); +} +} +.loading-text[data-v-51006ffb] { + font-size: 0.75rem; + color: #999; +} + +/* ===== 数据库标签 ===== */ +.db-tag[data-v-51006ffb] { + display: inline-block; + font-size: 0.625rem; + font-weight: 500; + padding: 0.0625rem 0.375rem; + border-radius: 0.25rem; + margin-left: 0.3125rem; + vertical-align: middle; +} +.db-tag.tag-personal[data-v-51006ffb] { + color: #3b86ff; + background: rgba(59, 134, 255, 0.08); + border: 0.03125rem solid rgba(59, 134, 255, 0.2); +} +.db-tag.tag-team[data-v-51006ffb] { + color: #67c23a; + background: rgba(103, 194, 58, 0.08); + border: 0.03125rem solid rgba(103, 194, 58, 0.2); +} + +/* ===== 上传数据库弹窗 ===== */ +.upload-db-hint[data-v-51006ffb] { + font-size: 0.6875rem; + color: #999; + margin-bottom: 0.625rem; + text-align: center; +} +.upload-file-area[data-v-51006ffb] { + padding: 1.25rem; + border: 0.0625rem dashed #d0d0d0; + border-radius: 0.5rem; + background: #f9fafb; + text-align: center; + margin-bottom: 0.625rem; +} +.upload-file-area[data-v-51006ffb]:active { + border-color: #3b86ff; + background: rgba(59, 134, 255, 0.03); +} +.selected-file[data-v-51006ffb] { + font-size: 0.8125rem; + color: #3b86ff; + font-weight: 500; + word-break: break-all; +} +.upload-hint[data-v-51006ffb] { + font-size: 0.75rem; + color: #bbb; +} diff --git a/unpackage/dist/dev/app-plus/pages/CloudDbDetail/CloudDbDetail.css b/unpackage/dist/dev/app-plus/pages/CloudDbDetail/CloudDbDetail.css new file mode 100644 index 0000000..861d016 --- /dev/null +++ b/unpackage/dist/dev/app-plus/pages/CloudDbDetail/CloudDbDetail.css @@ -0,0 +1,998 @@ +/** + * 这里是uni-app内置的常用样式变量 + * + * uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量 + * 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App + * + */ +/** + * 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能 + * + * 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件 + */ +/* 颜色变量 */ +/* 行为相关颜色 */ +/* 文字基本颜色 */ +/* 背景颜色 */ +/* 边框颜色 */ +/* 尺寸变量 */ +/* 文字尺寸 */ +/* 图片尺寸 */ +/* Border Radius */ +/* 水平间距 */ +/* 垂直间距 */ +/* 透明度 */ +/* 文章场景相关 */ +.uniui-cart-filled[data-v-d31e1c47]:before { + content: "\e6d0"; +} +.uniui-gift-filled[data-v-d31e1c47]:before { + content: "\e6c4"; +} +.uniui-color[data-v-d31e1c47]:before { + content: "\e6cf"; +} +.uniui-wallet[data-v-d31e1c47]:before { + content: "\e6b1"; +} +.uniui-settings-filled[data-v-d31e1c47]:before { + content: "\e6ce"; +} +.uniui-auth-filled[data-v-d31e1c47]:before { + content: "\e6cc"; +} +.uniui-shop-filled[data-v-d31e1c47]:before { + content: "\e6cd"; +} +.uniui-staff-filled[data-v-d31e1c47]:before { + content: "\e6cb"; +} +.uniui-vip-filled[data-v-d31e1c47]:before { + content: "\e6c6"; +} +.uniui-plus-filled[data-v-d31e1c47]:before { + content: "\e6c7"; +} +.uniui-folder-add-filled[data-v-d31e1c47]:before { + content: "\e6c8"; +} +.uniui-color-filled[data-v-d31e1c47]:before { + content: "\e6c9"; +} +.uniui-tune-filled[data-v-d31e1c47]:before { + content: "\e6ca"; +} +.uniui-calendar-filled[data-v-d31e1c47]:before { + content: "\e6c0"; +} +.uniui-notification-filled[data-v-d31e1c47]:before { + content: "\e6c1"; +} +.uniui-wallet-filled[data-v-d31e1c47]:before { + content: "\e6c2"; +} +.uniui-medal-filled[data-v-d31e1c47]:before { + content: "\e6c3"; +} +.uniui-fire-filled[data-v-d31e1c47]:before { + content: "\e6c5"; +} +.uniui-refreshempty[data-v-d31e1c47]:before { + content: "\e6bf"; +} +.uniui-location-filled[data-v-d31e1c47]:before { + content: "\e6af"; +} +.uniui-person-filled[data-v-d31e1c47]:before { + content: "\e69d"; +} +.uniui-personadd-filled[data-v-d31e1c47]:before { + content: "\e698"; +} +.uniui-arrowthinleft[data-v-d31e1c47]:before { + content: "\e6d2"; +} +.uniui-arrowthinup[data-v-d31e1c47]:before { + content: "\e6d3"; +} +.uniui-arrowthindown[data-v-d31e1c47]:before { + content: "\e6d4"; +} +.uniui-back[data-v-d31e1c47]:before { + content: "\e6b9"; +} +.uniui-forward[data-v-d31e1c47]:before { + content: "\e6ba"; +} +.uniui-arrow-right[data-v-d31e1c47]:before { + content: "\e6bb"; +} +.uniui-arrow-left[data-v-d31e1c47]:before { + content: "\e6bc"; +} +.uniui-arrow-up[data-v-d31e1c47]:before { + content: "\e6bd"; +} +.uniui-arrow-down[data-v-d31e1c47]:before { + content: "\e6be"; +} +.uniui-arrowthinright[data-v-d31e1c47]:before { + content: "\e6d1"; +} +.uniui-down[data-v-d31e1c47]:before { + content: "\e6b8"; +} +.uniui-bottom[data-v-d31e1c47]:before { + content: "\e6b8"; +} +.uniui-arrowright[data-v-d31e1c47]:before { + content: "\e6d5"; +} +.uniui-right[data-v-d31e1c47]:before { + content: "\e6b5"; +} +.uniui-up[data-v-d31e1c47]:before { + content: "\e6b6"; +} +.uniui-top[data-v-d31e1c47]:before { + content: "\e6b6"; +} +.uniui-left[data-v-d31e1c47]:before { + content: "\e6b7"; +} +.uniui-arrowup[data-v-d31e1c47]:before { + content: "\e6d6"; +} +.uniui-eye[data-v-d31e1c47]:before { + content: "\e651"; +} +.uniui-eye-filled[data-v-d31e1c47]:before { + content: "\e66a"; +} +.uniui-eye-slash[data-v-d31e1c47]:before { + content: "\e6b3"; +} +.uniui-eye-slash-filled[data-v-d31e1c47]:before { + content: "\e6b4"; +} +.uniui-info-filled[data-v-d31e1c47]:before { + content: "\e649"; +} +.uniui-reload[data-v-d31e1c47]:before { + content: "\e6b2"; +} +.uniui-micoff-filled[data-v-d31e1c47]:before { + content: "\e6b0"; +} +.uniui-map-pin-ellipse[data-v-d31e1c47]:before { + content: "\e6ac"; +} +.uniui-map-pin[data-v-d31e1c47]:before { + content: "\e6ad"; +} +.uniui-location[data-v-d31e1c47]:before { + content: "\e6ae"; +} +.uniui-starhalf[data-v-d31e1c47]:before { + content: "\e683"; +} +.uniui-star[data-v-d31e1c47]:before { + content: "\e688"; +} +.uniui-star-filled[data-v-d31e1c47]:before { + content: "\e68f"; +} +.uniui-calendar[data-v-d31e1c47]:before { + content: "\e6a0"; +} +.uniui-fire[data-v-d31e1c47]:before { + content: "\e6a1"; +} +.uniui-medal[data-v-d31e1c47]:before { + content: "\e6a2"; +} +.uniui-font[data-v-d31e1c47]:before { + content: "\e6a3"; +} +.uniui-gift[data-v-d31e1c47]:before { + content: "\e6a4"; +} +.uniui-link[data-v-d31e1c47]:before { + content: "\e6a5"; +} +.uniui-notification[data-v-d31e1c47]:before { + content: "\e6a6"; +} +.uniui-staff[data-v-d31e1c47]:before { + content: "\e6a7"; +} +.uniui-vip[data-v-d31e1c47]:before { + content: "\e6a8"; +} +.uniui-folder-add[data-v-d31e1c47]:before { + content: "\e6a9"; +} +.uniui-tune[data-v-d31e1c47]:before { + content: "\e6aa"; +} +.uniui-auth[data-v-d31e1c47]:before { + content: "\e6ab"; +} +.uniui-person[data-v-d31e1c47]:before { + content: "\e699"; +} +.uniui-email-filled[data-v-d31e1c47]:before { + content: "\e69a"; +} +.uniui-phone-filled[data-v-d31e1c47]:before { + content: "\e69b"; +} +.uniui-phone[data-v-d31e1c47]:before { + content: "\e69c"; +} +.uniui-email[data-v-d31e1c47]:before { + content: "\e69e"; +} +.uniui-personadd[data-v-d31e1c47]:before { + content: "\e69f"; +} +.uniui-chatboxes-filled[data-v-d31e1c47]:before { + content: "\e692"; +} +.uniui-contact[data-v-d31e1c47]:before { + content: "\e693"; +} +.uniui-chatbubble-filled[data-v-d31e1c47]:before { + content: "\e694"; +} +.uniui-contact-filled[data-v-d31e1c47]:before { + content: "\e695"; +} +.uniui-chatboxes[data-v-d31e1c47]:before { + content: "\e696"; +} +.uniui-chatbubble[data-v-d31e1c47]:before { + content: "\e697"; +} +.uniui-upload-filled[data-v-d31e1c47]:before { + content: "\e68e"; +} +.uniui-upload[data-v-d31e1c47]:before { + content: "\e690"; +} +.uniui-weixin[data-v-d31e1c47]:before { + content: "\e691"; +} +.uniui-compose[data-v-d31e1c47]:before { + content: "\e67f"; +} +.uniui-qq[data-v-d31e1c47]:before { + content: "\e680"; +} +.uniui-download-filled[data-v-d31e1c47]:before { + content: "\e681"; +} +.uniui-pyq[data-v-d31e1c47]:before { + content: "\e682"; +} +.uniui-sound[data-v-d31e1c47]:before { + content: "\e684"; +} +.uniui-trash-filled[data-v-d31e1c47]:before { + content: "\e685"; +} +.uniui-sound-filled[data-v-d31e1c47]:before { + content: "\e686"; +} +.uniui-trash[data-v-d31e1c47]:before { + content: "\e687"; +} +.uniui-videocam-filled[data-v-d31e1c47]:before { + content: "\e689"; +} +.uniui-spinner-cycle[data-v-d31e1c47]:before { + content: "\e68a"; +} +.uniui-weibo[data-v-d31e1c47]:before { + content: "\e68b"; +} +.uniui-videocam[data-v-d31e1c47]:before { + content: "\e68c"; +} +.uniui-download[data-v-d31e1c47]:before { + content: "\e68d"; +} +.uniui-help[data-v-d31e1c47]:before { + content: "\e679"; +} +.uniui-navigate-filled[data-v-d31e1c47]:before { + content: "\e67a"; +} +.uniui-plusempty[data-v-d31e1c47]:before { + content: "\e67b"; +} +.uniui-smallcircle[data-v-d31e1c47]:before { + content: "\e67c"; +} +.uniui-minus-filled[data-v-d31e1c47]:before { + content: "\e67d"; +} +.uniui-micoff[data-v-d31e1c47]:before { + content: "\e67e"; +} +.uniui-closeempty[data-v-d31e1c47]:before { + content: "\e66c"; +} +.uniui-clear[data-v-d31e1c47]:before { + content: "\e66d"; +} +.uniui-navigate[data-v-d31e1c47]:before { + content: "\e66e"; +} +.uniui-minus[data-v-d31e1c47]:before { + content: "\e66f"; +} +.uniui-image[data-v-d31e1c47]:before { + content: "\e670"; +} +.uniui-mic[data-v-d31e1c47]:before { + content: "\e671"; +} +.uniui-paperplane[data-v-d31e1c47]:before { + content: "\e672"; +} +.uniui-close[data-v-d31e1c47]:before { + content: "\e673"; +} +.uniui-help-filled[data-v-d31e1c47]:before { + content: "\e674"; +} +.uniui-paperplane-filled[data-v-d31e1c47]:before { + content: "\e675"; +} +.uniui-plus[data-v-d31e1c47]:before { + content: "\e676"; +} +.uniui-mic-filled[data-v-d31e1c47]:before { + content: "\e677"; +} +.uniui-image-filled[data-v-d31e1c47]:before { + content: "\e678"; +} +.uniui-locked-filled[data-v-d31e1c47]:before { + content: "\e668"; +} +.uniui-info[data-v-d31e1c47]:before { + content: "\e669"; +} +.uniui-locked[data-v-d31e1c47]:before { + content: "\e66b"; +} +.uniui-camera-filled[data-v-d31e1c47]:before { + content: "\e658"; +} +.uniui-chat-filled[data-v-d31e1c47]:before { + content: "\e659"; +} +.uniui-camera[data-v-d31e1c47]:before { + content: "\e65a"; +} +.uniui-circle[data-v-d31e1c47]:before { + content: "\e65b"; +} +.uniui-checkmarkempty[data-v-d31e1c47]:before { + content: "\e65c"; +} +.uniui-chat[data-v-d31e1c47]:before { + content: "\e65d"; +} +.uniui-circle-filled[data-v-d31e1c47]:before { + content: "\e65e"; +} +.uniui-flag[data-v-d31e1c47]:before { + content: "\e65f"; +} +.uniui-flag-filled[data-v-d31e1c47]:before { + content: "\e660"; +} +.uniui-gear-filled[data-v-d31e1c47]:before { + content: "\e661"; +} +.uniui-home[data-v-d31e1c47]:before { + content: "\e662"; +} +.uniui-home-filled[data-v-d31e1c47]:before { + content: "\e663"; +} +.uniui-gear[data-v-d31e1c47]:before { + content: "\e664"; +} +.uniui-smallcircle-filled[data-v-d31e1c47]:before { + content: "\e665"; +} +.uniui-map-filled[data-v-d31e1c47]:before { + content: "\e666"; +} +.uniui-map[data-v-d31e1c47]:before { + content: "\e667"; +} +.uniui-refresh-filled[data-v-d31e1c47]:before { + content: "\e656"; +} +.uniui-refresh[data-v-d31e1c47]:before { + content: "\e657"; +} +.uniui-cloud-upload[data-v-d31e1c47]:before { + content: "\e645"; +} +.uniui-cloud-download-filled[data-v-d31e1c47]:before { + content: "\e646"; +} +.uniui-cloud-download[data-v-d31e1c47]:before { + content: "\e647"; +} +.uniui-cloud-upload-filled[data-v-d31e1c47]:before { + content: "\e648"; +} +.uniui-redo[data-v-d31e1c47]:before { + content: "\e64a"; +} +.uniui-images-filled[data-v-d31e1c47]:before { + content: "\e64b"; +} +.uniui-undo-filled[data-v-d31e1c47]:before { + content: "\e64c"; +} +.uniui-more[data-v-d31e1c47]:before { + content: "\e64d"; +} +.uniui-more-filled[data-v-d31e1c47]:before { + content: "\e64e"; +} +.uniui-undo[data-v-d31e1c47]:before { + content: "\e64f"; +} +.uniui-images[data-v-d31e1c47]:before { + content: "\e650"; +} +.uniui-paperclip[data-v-d31e1c47]:before { + content: "\e652"; +} +.uniui-settings[data-v-d31e1c47]:before { + content: "\e653"; +} +.uniui-search[data-v-d31e1c47]:before { + content: "\e654"; +} +.uniui-redo-filled[data-v-d31e1c47]:before { + content: "\e655"; +} +.uniui-list[data-v-d31e1c47]:before { + content: "\e644"; +} +.uniui-mail-open-filled[data-v-d31e1c47]:before { + content: "\e63a"; +} +.uniui-hand-down-filled[data-v-d31e1c47]:before { + content: "\e63c"; +} +.uniui-hand-down[data-v-d31e1c47]:before { + content: "\e63d"; +} +.uniui-hand-up-filled[data-v-d31e1c47]:before { + content: "\e63e"; +} +.uniui-hand-up[data-v-d31e1c47]:before { + content: "\e63f"; +} +.uniui-heart-filled[data-v-d31e1c47]:before { + content: "\e641"; +} +.uniui-mail-open[data-v-d31e1c47]:before { + content: "\e643"; +} +.uniui-heart[data-v-d31e1c47]:before { + content: "\e639"; +} +.uniui-loop[data-v-d31e1c47]:before { + content: "\e633"; +} +.uniui-pulldown[data-v-d31e1c47]:before { + content: "\e632"; +} +.uniui-scan[data-v-d31e1c47]:before { + content: "\e62a"; +} +.uniui-bars[data-v-d31e1c47]:before { + content: "\e627"; +} +.uniui-checkbox[data-v-d31e1c47]:before { + content: "\e62b"; +} +.uniui-checkbox-filled[data-v-d31e1c47]:before { + content: "\e62c"; +} +.uniui-shop[data-v-d31e1c47]:before { + content: "\e62f"; +} +.uniui-headphones[data-v-d31e1c47]:before { + content: "\e630"; +} +.uniui-cart[data-v-d31e1c47]:before { + content: "\e631"; +} +@font-face { + font-family: uniicons; + src: url("../../assets/uniicons.32e978a5.ttf"); +} +.uni-icons[data-v-d31e1c47] { + font-family: uniicons; + text-decoration: none; + text-align: center; +} +/* ========== 通用 ========== */ +.status-bar[data-v-96fa4671] { + height: var(--status-bar-height); + background-color: #ffffff; +} +.page-container[data-v-96fa4671] { + display: flex; + flex-direction: column; + height: 100vh; + background-color: #f5f6fa; +} +/* ========== 导航栏 ========== */ +.cloud-db-header[data-v-96fa4671] { + background-color: #ffffff; + flex-shrink: 0; + position: relative; + z-index: 10; +} +.custom-navbar[data-v-96fa4671] { + display: flex; + align-items: center; + justify-content: space-between; + height: 2.75rem; + padding: 0 0.9375rem; +} +.navbar-left[data-v-96fa4671] { + display: flex; + align-items: center; + min-width: 3.75rem; +} +.custom-navbar-icon[data-v-96fa4671] { + font-size: 1.25rem; + color: #333; +} +.navbar-title[data-v-96fa4671] { + font-size: 1.0625rem; + font-weight: 600; + color: #333; + flex: 1; + text-align: center; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} +.navbar-right[data-v-96fa4671] { + min-width: 3.75rem; + display: flex; + justify-content: flex-end; +} +/* 下拉菜单 */ +.menu-card[data-v-96fa4671] { + position: absolute; + top: 2.75rem; + right: 0.625rem; + background: #fff; + border-radius: 0.5rem; + box-shadow: 0 0.25rem 1rem rgba(0,0,0,0.12); + z-index: 500; + overflow: hidden; + min-width: 6.25rem; +} +.menu-card-item[data-v-96fa4671] { + padding: 0.75rem 1.125rem; + font-size: 0.875rem; + color: #333; + text-align: center; +} +.menu-card-item[data-v-96fa4671]:active { + background-color: #f5f6fa; +} +.solid-line[data-v-96fa4671] { + height: 0.03125rem; + background-color: #eee; + margin: 0 0.625rem; +} +/* ========== 数据库信息栏 ========== */ +.db-info-bar[data-v-96fa4671] { + display: flex; + align-items: center; + gap: 0.75rem; + padding: 0.625rem 0.9375rem; + background: #fff; + border-bottom: 0.03125rem solid #f0f0f0; +} +.db-info-text[data-v-96fa4671] { + font-size: 0.75rem; + color: #999; +} +/* ========== 内容区域 ========== */ +.cloud-db-content[data-v-96fa4671] { + flex: 1; + overflow-y: auto; +} +.section-block[data-v-96fa4671] { + margin: 0.625rem; + background: #fff; + border-radius: 0.625rem; + overflow: hidden; +} +.section-header[data-v-96fa4671] { + display: flex; + align-items: center; + justify-content: space-between; + padding: 0.75rem 0.9375rem; + border-bottom: 0.03125rem solid #f5f6fa; +} +.section-title[data-v-96fa4671] { + display: flex; + align-items: center; + gap: 0.375rem; + font-size: 0.9375rem; + font-weight: 600; + color: #333; +} +.section-title .iconfont[data-v-96fa4671] { + font-size: 1.125rem; + color: #3b86ff; +} +.section-actions[data-v-96fa4671] { + display: flex; + align-items: center; + gap: 0.5rem; +} +.row-count[data-v-96fa4671] { + font-size: 0.75rem; + color: #999; +} +.section-divider[data-v-96fa4671] { + height: 0.03125rem; + background-color: #f0f0f0; + margin: 0 0.625rem; +} +.section-body[data-v-96fa4671] { + padding: 0.5rem 0; +} +/* ========== 空状态 ========== */ +.empty-tip[data-v-96fa4671] { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 1.875rem 0; + color: #ccc; + font-size: 0.8125rem; +} +.empty-tip .iconfont[data-v-96fa4671] { + font-size: 2.5rem; + margin-bottom: 0.5rem; +} +/* ========== 表列表 ========== */ +.table-list[data-v-96fa4671] { + padding: 0 0.9375rem; +} +.table-item[data-v-96fa4671] { + display: flex; + align-items: center; + padding: 0.75rem 0; + border-bottom: 0.03125rem solid #f5f6fa; +} +.table-item[data-v-96fa4671]:last-child { + border-bottom: none; +} +.table-item[data-v-96fa4671]:active { + background-color: #fafbfc; + margin: 0 -0.9375rem; + padding-left: 0.9375rem; + padding-right: 0.9375rem; +} +.table-icon[data-v-96fa4671] { + width: 2.25rem; + height: 2.25rem; + border-radius: 0.5rem; + background: rgba(59, 134, 255, 0.08); + display: flex; + align-items: center; + justify-content: center; + margin-right: 0.625rem; + flex-shrink: 0; +} +.table-info[data-v-96fa4671] { + flex: 1; + overflow: hidden; +} +.table-name[data-v-96fa4671] { + font-size: 0.9375rem; + font-weight: 500; + color: #333; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} +.table-desc[data-v-96fa4671] { + font-size: 0.75rem; + color: #999; + margin-top: 0.125rem; +} +.table-meta[data-v-96fa4671] { + display: flex; + align-items: center; + gap: 0.25rem; + flex-shrink: 0; +} +/* ========== 数据表格 ========== */ +.data-table-wrapper[data-v-96fa4671] { + padding: 0; +} +.data-table-scroll[data-v-96fa4671] { + width: 100%; +} +.data-table[data-v-96fa4671] { + min-width: 100%; +} +.data-row[data-v-96fa4671] { + display: flex; + flex-direction: row; + border-bottom: 0.03125rem solid #f0f0f0; +} +.data-row[data-v-96fa4671]:last-child { + border-bottom: none; +} +.data-header[data-v-96fa4671] { + background-color: #f8f9fb; +} +.data-cell[data-v-96fa4671] { + padding: 0.5rem 0.625rem; + font-size: 0.8125rem; + color: #333; + min-width: 5rem; + max-width: 9.375rem; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; + border-right: 0.03125rem solid #f0f0f0; + flex-shrink: 0; +} +.data-cell[data-v-96fa4671]:last-child { + border-right: none; +} +.data-header .data-cell[data-v-96fa4671] { + font-weight: 600; + color: #666; + font-size: 0.75rem; +} +.index-cell[data-v-96fa4671] { + min-width: 2.5rem !important; + max-width: 2.5rem !important; + text-align: center; + color: #999; + font-size: 0.75rem; +} +.data-row[data-v-96fa4671]:active { + background-color: #f5f7fa; +} +/* ========== 弹窗通用 ========== */ +.popup-overlay[data-v-96fa4671] { + position: fixed; + top: 0; + left: 0; + right: 0; + bottom: 0; + background: rgba(0, 0, 0, 0.5); + display: flex; + align-items: center; + justify-content: center; + z-index: 900; +} +.popup-card[data-v-96fa4671] { + width: 20rem; + background: #fff; + border-radius: 0.75rem; + padding: 1.25rem 1.125rem 0.9375rem; + position: relative; +} +.close-popup-card[data-v-96fa4671] { + position: absolute; + top: 0.625rem; + right: 0.625rem; + width: 1.5rem; + height: 1.5rem; + display: flex; + align-items: center; + justify-content: center; +} +.close-popup-card .iconfont[data-v-96fa4671] { + font-size: 1.125rem; + color: #999; +} +.popup-title[data-v-96fa4671] { + font-size: 1.0625rem; + font-weight: 600; + color: #333; + text-align: center; + margin-bottom: 0.9375rem; +} +.new-folder-name[data-v-96fa4671] { + font-size: 0.8125rem; + color: #666; + margin-bottom: 0.375rem; +} +.create-folder-name[data-v-96fa4671] { + margin-bottom: 0.75rem; +} +.create-folder-name uni-input[data-v-96fa4671] { + width: 100%; + height: 2.5rem; + border: 0.0625rem solid #e0e0e0; + border-radius: 0.375rem; + padding: 0 0.625rem; + font-size: 0.875rem; + box-sizing: border-box; + background: #f8f9fb; +} +.upload-file-area[data-v-96fa4671] { + width: 100%; + height: 3.75rem; + border: 0.0625rem dashed #d0d0d0; + border-radius: 0.375rem; + display: flex; + align-items: center; + justify-content: center; + margin-bottom: 0.75rem; + background: #fafbfc; +} +.selected-file[data-v-96fa4671] { + font-size: 0.8125rem; + color: #3b86ff; +} +.upload-hint[data-v-96fa4671] { + font-size: 0.75rem; + color: #999; +} +.option-wrapper[data-v-96fa4671] { + display: flex; + gap: 0.625rem; + margin-top: 0.3125rem; +} +.opt-btn[data-v-96fa4671] { + flex: 1; + height: 2.5rem; + border-radius: 0.375rem; + display: flex; + align-items: center; + justify-content: center; + font-size: 0.9375rem; +} +.opt-cancel[data-v-96fa4671] { + background: #f5f6fa; + color: #666; +} +.opt-confirm[data-v-96fa4671] { + background: #3b86ff; + color: #fff; +} +/* ========== 权限管理 ========== */ +.permission-body[data-v-96fa4671] { + max-height: 18.75rem; + margin-bottom: 0.625rem; +} +.permission-list[data-v-96fa4671] { + padding: 0 0.3125rem; +} +.permission-item[data-v-96fa4671] { + display: flex; + align-items: center; + padding: 0.625rem 0.3125rem; + border-bottom: 0.03125rem solid #f0f0f0; +} +.perm-info[data-v-96fa4671] { + flex: 1; + display: flex; + flex-direction: column; + gap: 0.125rem; +} +.perm-name[data-v-96fa4671] { + font-size: 0.875rem; + color: #333; +} +.perm-type[data-v-96fa4671] { + font-size: 0.6875rem; + color: #999; +} +.perm-level[data-v-96fa4671] { + font-size: 0.75rem; + color: #3b86ff; + background: rgba(59, 134, 255, 0.08); + padding: 0.1875rem 0.5rem; + border-radius: 0.25rem; + margin: 0 0.5rem; +} +.perm-actions[data-v-96fa4671] { + display: flex; + gap: 0.375rem; +} +.perm-action-btn[data-v-96fa4671] { + font-size: 0.75rem; + color: #3b86ff; + padding: 0.25rem 0.5rem; + border: 0.03125rem solid #3b86ff; + border-radius: 0.25rem; +} +.perm-action-btn.delete[data-v-96fa4671] { + color: #f56c6c; + border-color: #f56c6c; +} +.close-permission-btn[data-v-96fa4671] { + text-align: center; + font-size: 0.875rem; + color: #999; + padding: 0.5rem 0; +} +.folder-null[data-v-96fa4671] { + text-align: center; + padding: 1.25rem 0; + font-size: 0.8125rem; + color: #999; +} +/* ========== 移交团队 ========== */ +.transfer-body[data-v-96fa4671] { + max-height: 15.625rem; + margin-bottom: 0.625rem; +} +.transfer-list[data-v-96fa4671] { + padding: 0 0.3125rem; +} +.transfer-item[data-v-96fa4671] { + display: flex; + align-items: center; + justify-content: space-between; + padding: 0.75rem 0.5rem; + border-bottom: 0.03125rem solid #f0f0f0; + border-radius: 0.375rem; + margin-bottom: 0.25rem; +} +.transfer-item.active[data-v-96fa4671] { + background: rgba(59, 134, 255, 0.06); +} +.transfer-name[data-v-96fa4671] { + font-size: 0.875rem; + color: #333; +} +/* ===== 加载动画 ===== */ +.loading-area[data-v-96fa4671] { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + padding: 1.875rem 0; + gap: 0.5rem; +} +.loading-spinner[data-v-96fa4671] { + width: 1.75rem; + height: 1.75rem; + border: 0.125rem solid #e8e8e8; + border-top-color: #3b86ff; + border-radius: 50%; + animation: spin-96fa4671 0.8s linear infinite; +} +@keyframes spin-96fa4671 { +to { + transform: rotate(360deg); +} +} +.loading-text[data-v-96fa4671] { + font-size: 0.75rem; + color: #999; +} diff --git a/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/classes.dex b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/classes.dex new file mode 100644 index 0000000..841d32e Binary files /dev/null and b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/classes.dex differ diff --git a/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/config.json b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/config.json new file mode 100644 index 0000000..bf95925 --- /dev/null +++ b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/config.json @@ -0,0 +1,3 @@ +{ + "minSdkVersion": "21" +} \ No newline at end of file diff --git a/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.kt b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.kt new file mode 100644 index 0000000..5be51b9 --- /dev/null +++ b/unpackage/dist/dev/app-plus/uni_modules/lime-choose-file/utssdk/app-android/index.kt @@ -0,0 +1,277 @@ +@file:Suppress("UNCHECKED_CAST", "USELESS_CAST", "INAPPLICABLE_JVM_NAME", "UNUSED_ANONYMOUS_PARAMETER", "SENSELESS_COMPARISON", "NAME_SHADOWING", "UNNECESSARY_NOT_NULL_ASSERTION") +package uts.sdk.modules.limeChooseFile +import android.content.Intent +import android.net.Uri +import android.provider.OpenableColumns +import io.dcloud.uniapp.* +import io.dcloud.uniapp.extapi.* +import io.dcloud.unicloud.* +import io.dcloud.uts.* +import io.dcloud.uts.Map +import io.dcloud.uts.Set +import io.dcloud.uts.UTSAndroid +import java.io.File +import java.io.FileOutputStream +import kotlin.properties.Delegates +import kotlinx.coroutines.CoroutineScope +import kotlinx.coroutines.Deferred +import kotlinx.coroutines.Dispatchers +import kotlinx.coroutines.async +typealias ChooseFileErrorCode = Number +interface GeneralCallbackResult : IUniError { + override var errCode: ChooseFileErrorCode +} +interface ChooseFile { + var name: String + var path: String + var size: Number + var time: Number + var type: String +} +open class ChooseFileSuccessCallbackResult ( + @JsonNotNull + open var tempFiles: UTSArray, + @JsonNotNull + open var errMsg: String, +) : UTSObject(), IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileSuccessCallbackResult", "uni_modules/lime-choose-file/utssdk/interface.uts", 34, 13) + } +} +typealias ChooseFileSuccessCallback = (result: ChooseFileSuccessCallbackResult) -> Unit +typealias ChooseFileFailCallback = (res: GeneralCallbackResult) -> Unit +typealias ChooseFileCompleteCallback = (res: GeneralCallbackResult) -> Unit +open class ChooseFileOption ( + open var filename: String? = null, + open var count: Number? = null, + open var type: String? = null, + open var extension: UTSArray? = null, + open var success: ChooseFileSuccessCallback? = null, + open var fail: ChooseFileFailCallback? = null, + open var complete: ChooseFileCompleteCallback? = null, +) : UTSObject(), IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileOption", "uni_modules/lime-choose-file/utssdk/interface.uts", 45, 13) + } +} +val UniErrorSubject = "chooseFile\"" +val UniErrors: Map = Map(_uA( + _uA( + 9010001, + "chooseFile:ok" + ), + _uA( + 9010002, + "ChooseFile:failed" + ) +)) +open class GeneralCallbackResultImpl : UniError, GeneralCallbackResult, IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("GeneralCallbackResultImpl", "uni_modules/lime-choose-file/utssdk/unierror.uts", 25, 14) + } + constructor(errCode: ChooseFileErrorCode, errMsg: String? = null) : super() { + this.errSubject = UniErrorSubject + this.errCode = errCode + this.errMsg = errMsg ?: UniErrors[errCode] ?: "" + } +} +val REQUEST_CODE_CHOOSE_FILE: Int = 42 +var resultFunction: ((requestCode: Int, resultCode: Int, data: Intent?) -> Unit)? = null +open class ChooseFileImpl : ChooseFile, IUTSSourceMap { + override fun `__$getOriginalPosition`(): UTSSourceMapPosition? { + return UTSSourceMapPosition("ChooseFileImpl", "uni_modules/lime-choose-file/utssdk/app-android/index.uts", 17, 7) + } + override var name: String = "" + override var path: String = "" + override var size: Number = 0 + override var time: Number = 0 + override var type: String = "file" + private var options: ChooseFileOption + constructor(uri: Uri, options: ChooseFileOption){ + this.options = options + this.time = Date.now() + this.type = this.getFileTypeFromUri(uri) + this.getFileInfoFromUri(uri) + if (this.isCache(options)) { + this.copyFileToCache(uri) + } + } + private fun isCache(options: ChooseFileOption): Boolean { + val extension = this.getFileExtension(this.name) + val extensions = options.extension + val type = options.type ?: "all" + val hasExtension = extensions != null && extension != "" && extensions.includes(extension) + val isVideoOrImage = _uA( + "video", + "image" + ).includes(type) + val isFileAndNotVideoOrImage = type == "file" && !_uA( + "video", + "image" + ).includes(this.type) + if ((type == "all" || isVideoOrImage || isFileAndNotVideoOrImage) && !hasExtension) { + return true + } else { + return false + } + } + private fun getFileExtension(fileName: String): String { + val lastDotIndex = fileName.lastIndexOf(".") + if (lastDotIndex == -1) { + return "" + } + return fileName.substring(lastDotIndex + 1) + } + private fun copyFileToCache(uri: Uri) { + val cacheDir = UTSAndroid.getAppCachePath() + val context = UTSAndroid.getAppContext() + if (cacheDir != null) { + val path = File(cacheDir) + if (!path.exists()) { + path.mkdir() + } + } + var fileName = this.name + if (this.options.filename != null) { + fileName = this.options.filename!! + if (this.options.count != null && this.options.count!! > 1) { + fileName = "" + fileName + "_" + Date.now() + } + val extension = this.getFileExtension(this.name) + fileName = "" + fileName + "." + extension + } + val destFile = File(cacheDir, fileName) + try { + val inputStream = context!!.getContentResolver().openInputStream(uri) + val outputStream = FileOutputStream(destFile) + if (inputStream != null) { + var buffer = ByteArray(1024) + var c = inputStream.read(buffer) + while(c > 0){ + outputStream.write(buffer, 0, c) + c = inputStream.read(buffer) + } + } + this.path = cacheDir + fileName + } + catch (e: Throwable) {} + } + private fun getFileTypeFromUri(uri: Uri): String { + val context = UTSAndroid.getAppContext() + var fileType = "file" + var mimeType = context!!.getContentResolver().getType(uri) + if (mimeType != null) { + if (mimeType.startsWith("video")) { + fileType = "video" + } else if (mimeType.startsWith("image")) { + fileType = "image" + } + } + return fileType + } + private fun getFileInfoFromUri(uri: Uri) { + val context = UTSAndroid.getAppContext() + var cursor = context!!.getContentResolver().query(uri, null, null, null, null) + if (cursor != null && cursor.moveToFirst()) { + this.name = cursor.getString(cursor.getColumnIndexOrThrow(OpenableColumns.DISPLAY_NAME)) + val fileSize = cursor.getLong(cursor.getColumnIndexOrThrow(OpenableColumns.SIZE)) + this.size = UTSNumber.from(fileSize) + cursor.close() + } else if ("file".equals(uri.getScheme())) { + this.name = uri.getLastPathSegment() ?: "" + val file = File(uri.getPath() ?: "") + val fileSize = file.length() + this.size = UTSNumber.from(fileSize) + } + } +} +fun chooseFile(options: ChooseFileOption) { + if (resultFunction != null) { + UTSAndroid.offAppActivityResult(resultFunction!!) + } + val type = options.type ?: "all" + val intent = Intent(Intent.ACTION_GET_CONTENT) + if (type.equals("all") || type.equals("file")) { + intent.setType("*/*") + } else if (type.equals("video")) { + intent.setType("video/*") + } else if (type.equals("image")) { + intent.setType("image/*") + } + intent.addCategory(Intent.CATEGORY_OPENABLE) + intent.putExtra(Intent.EXTRA_ALLOW_MULTIPLE, if (options.count == 1) { + false + } else { + true + } + ) + resultFunction = fun(requestCode: Int, resultCode: Int, data: Intent?){ + if (requestCode == REQUEST_CODE_CHOOSE_FILE) { + UTSAndroid.offAppActivityResult(resultFunction!!) + if (resultCode == -1 && data != null) { + val clipData = data.getClipData() + val tempFiles: UTSArray = _uA() + if (clipData != null) { + run { + var i: Number = 0 + while(i < clipData.getItemCount()){ + val uri = clipData.getItemAt(i.toInt()).getUri() + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + i++ + } + } + } else { + val uri = data.getData() + if (uri != null) { + val chooseFile = ChooseFileImpl(uri, options) + if (chooseFile.path != "") { + tempFiles.push(chooseFile) + } + } + } + val count = options.count ?: Integer.MAX_VALUE + if (tempFiles.length > 0 && count >= tempFiles.length) { + options.success?.invoke(ChooseFileSuccessCallbackResult(tempFiles = tempFiles, errMsg = "chooseFile:ok")) + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件或文件超过设置数量") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } else { + val err = GeneralCallbackResultImpl(9010002, "没有可用的文件") + options.fail?.invoke(err) + options.complete?.invoke(err) + } + } + UTSAndroid.onAppActivityResult(resultFunction!!) + UTSAndroid.getUniActivity()!!.startActivityForResult(Intent.createChooser(intent, "选择文件"), REQUEST_CODE_CHOOSE_FILE) +} +open class ChooseFileOptionJSONObject : UTSJSONObject() { + open var filename: String? = null + open var count: Number? = null + open var type: String? = null + open var extension: UTSArray? = null + open var success: UTSCallback? = null + open var fail: UTSCallback? = null + open var complete: UTSCallback? = null +} +fun chooseFileByJs(options: ChooseFileOptionJSONObject) { + return chooseFile(ChooseFileOption(filename = options.filename, count = options.count, type = options.type, extension = options.extension, success = fun(result: ChooseFileSuccessCallbackResult): Unit { + options.success?.invoke(result) + } + , fail = fun(res: GeneralCallbackResult): Unit { + options.fail?.invoke(res) + } + , complete = fun(res: GeneralCallbackResult): Unit { + options.complete?.invoke(res) + } + )) +} diff --git a/unpackage/res/icons/1024x1024.png b/unpackage/res/icons/1024x1024.png new file mode 100644 index 0000000..a0b1e65 Binary files /dev/null and b/unpackage/res/icons/1024x1024.png differ diff --git a/unpackage/res/icons/120x120.png b/unpackage/res/icons/120x120.png new file mode 100644 index 0000000..2119cde Binary files /dev/null and b/unpackage/res/icons/120x120.png differ diff --git a/unpackage/res/icons/144x144.png b/unpackage/res/icons/144x144.png new file mode 100644 index 0000000..8874c0a Binary files /dev/null and b/unpackage/res/icons/144x144.png differ diff --git a/unpackage/res/icons/152x152.png b/unpackage/res/icons/152x152.png new file mode 100644 index 0000000..9901d73 Binary files /dev/null and b/unpackage/res/icons/152x152.png differ diff --git a/unpackage/res/icons/167x167.png b/unpackage/res/icons/167x167.png new file mode 100644 index 0000000..22350c6 Binary files /dev/null and b/unpackage/res/icons/167x167.png differ diff --git a/unpackage/res/icons/180x180.png b/unpackage/res/icons/180x180.png new file mode 100644 index 0000000..de978b8 Binary files /dev/null and b/unpackage/res/icons/180x180.png differ diff --git a/unpackage/res/icons/192x192.png b/unpackage/res/icons/192x192.png new file mode 100644 index 0000000..67ba86f Binary files /dev/null and b/unpackage/res/icons/192x192.png differ diff --git a/unpackage/res/icons/20x20.png b/unpackage/res/icons/20x20.png new file mode 100644 index 0000000..b69e436 Binary files /dev/null and b/unpackage/res/icons/20x20.png differ diff --git a/unpackage/res/icons/29x29.png b/unpackage/res/icons/29x29.png new file mode 100644 index 0000000..2dfc629 Binary files /dev/null and b/unpackage/res/icons/29x29.png differ diff --git a/unpackage/res/icons/40x40.png b/unpackage/res/icons/40x40.png new file mode 100644 index 0000000..0239fbf Binary files /dev/null and b/unpackage/res/icons/40x40.png differ diff --git a/unpackage/res/icons/58x58.png b/unpackage/res/icons/58x58.png new file mode 100644 index 0000000..4fa8363 Binary files /dev/null and b/unpackage/res/icons/58x58.png differ diff --git a/unpackage/res/icons/60x60.png b/unpackage/res/icons/60x60.png new file mode 100644 index 0000000..d3ff9c3 Binary files /dev/null and b/unpackage/res/icons/60x60.png differ diff --git a/unpackage/res/icons/72x72.png b/unpackage/res/icons/72x72.png new file mode 100644 index 0000000..95bc2df Binary files /dev/null and b/unpackage/res/icons/72x72.png differ diff --git a/unpackage/res/icons/76x76.png b/unpackage/res/icons/76x76.png new file mode 100644 index 0000000..c43cdae Binary files /dev/null and b/unpackage/res/icons/76x76.png differ diff --git a/unpackage/res/icons/80x80.png b/unpackage/res/icons/80x80.png new file mode 100644 index 0000000..23ba933 Binary files /dev/null and b/unpackage/res/icons/80x80.png differ diff --git a/unpackage/res/icons/87x87.png b/unpackage/res/icons/87x87.png new file mode 100644 index 0000000..6c5d514 Binary files /dev/null and b/unpackage/res/icons/87x87.png differ diff --git a/unpackage/res/icons/96x96.png b/unpackage/res/icons/96x96.png new file mode 100644 index 0000000..b3dd3ab Binary files /dev/null and b/unpackage/res/icons/96x96.png differ diff --git a/utils/cloud-api.js b/utils/cloud-api.js index e0806fb..b0b75d5 100644 --- a/utils/cloud-api.js +++ b/utils/cloud-api.js @@ -520,37 +520,146 @@ export const getWorkspaceFileURL = (token, workspacesId, path) => { }) } -// 上传文件到工作区(手机弃用,仅支持pc本地前缀) -// export const workspaceUploadFile = (workspacesId,file,path) => { -// return new Promise((resolve, reject) => { -// uni.request({ -// url: `${BASE_URL}/workspace/file/upload`, -// method: "POST", -// header: { -// 'Content-Type': 'application/json' -// }, -// data: { -// workspaces_id: workspacesId, -// file: file, -// file_path: path, -// overwrite: true -// }, -// success: (res) => { -// if(res.statusCode === 200){ -// const respond = res.data -// if (respond.success) { -// resolve(respond)Z -// } else { -// const msg = respond?.error || '上传文件到工作区出错啦' -// reject(msg) -// } -// }else { -// reject(`上传文件到工作区失败:${res.statusCode}`) -// } -// } -// }) -// }) -// } +// 上传文件(通过url)到工作区 +export const workspaceUploadFileByURL = (token, workspacesId, urls, dirPath) => { + return new Promise((resolve, reject) => { + // urls 支持字符串或数组 + const urlList = Array.isArray(urls) ? urls : (urls ? [urls] : []); + uni.request({ + url: `${BASE_URL}/cloud_api/phone/workspace/upload`, + method: "POST", + header: { + 'Content-Type': 'application/json' + }, + data: { + "access_token": token, + "workspaces_id": workspacesId, + "dir_path": dirPath || '/', + "urls": urlList + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + // 接口返回: { success, total_files, success_count, failed_count, results: [{ url, success, error }], summary } + if (respond.success) { + resolve(respond); + } else { + // 部分/全部失败时,收集失败信息 + const failedItems = (respond.results || []) + .filter(r => !r.success) + .map(r => r.error || '未知错误'); + const msg = failedItems.length > 0 + ? `上传失败 ${respond.failed_count}/${respond.total_files}:${failedItems[0]}` + : (respond.summary || respond?.error || '上传文件到工作区出错啦'); + reject(msg); + } + } else { + reject(`上传文件到工作区失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || '网络错误'; + reject(msg); + } + }); + }); +}; + + + +// 上传文件(到短存云端)获取URL +// files: 文件数组,每个元素为 { path, name } 或字符串路径 +// 返回格式: [{ url: "https://...", success: true }] +export const uploadFileToShortStorage = (workspacesId, files, filePath) => { + return new Promise((resolve, reject) => { + // 统一转为文件数组 + const fileList = Array.isArray(files) ? files : [files]; + + // 构建 files 数组供 uni.uploadFile 使用 + const uploadFiles = fileList.map((file) => { + const fileUri = typeof file === 'string' ? file : (file.tempFilePath || file.path || file); + return { + name: 'files', + uri: fileUri + }; + }); + + console.log('uploadFileToShortStorage 参数:', { workspacesId, fileCount: uploadFiles.length, filePath }); + + uni.uploadFile({ + url: `${BASE_URL}/cloud_api/file/temp/upload`, + method: "POST", + formData: { + workspaces_id: workspacesId, + file_path: filePath || '/', + overwrite: 'true' + }, + files: uploadFiles, + success: (res) => { + console.log('uploadFileToShortStorage 响应状态:', res.statusCode, '数据:', res.data); + if (res.statusCode === 200) { + try { + const respond = JSON.parse(res.data); + // 接口返回 [{ url, success }] 数组 + if (Array.isArray(respond) && respond.length > 0) { + // 返回完整的 results 数组,调用方可遍历 + resolve(respond); + } else if (respond.success) { + // 兼容 { success: true, url: "..." } 格式 + resolve([{ url: respond.url || respond.message, success: true }]); + } else { + const msg = respond?.error || respond?.message || '上传文件(到短存云端)获取URL出错啦'; + reject(msg); + } + } catch (e) { + reject('接口返回数据格式异常: ' + res.data); + } + } else { + reject(`上传文件(到短存云端)获取URL失败:${res.statusCode} - ${res.data}`); + } + }, + fail: (err) => { + const msg = err.errMsg || '网络错误'; + reject(msg); + } + }); + }); +}; + +// 重命名工作区文件/文件夹(电脑端) +export const updateWorkspaceFileName = (token, workspacesId, oldPath, newName) => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/workspace/file/rename`, + method: "POST", + header: { + 'Content-Type': 'application/json' + }, + data: { + "workspaces_id": workspacesId, + "file_path": oldPath, + "new_name": newName + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data; + if (respond.success) { + resolve(respond.message || respond); + } else { + const msg = respond?.error || '重命名工作区文件出错啦'; + reject(msg); + } + } else { + reject(`重命名工作区文件失败:${res.statusCode}`); + } + }, + fail: (err) => { + const msg = err.errMsg || '网络错误'; + reject(msg); + } + }); + }); +}; // 上传用户头像 export const uploadUserAvatar = (token, userId, username, email, avatarURL) => { @@ -1113,23 +1222,31 @@ export const createCloudDb = (token, databaseName) => { }) } -// 上传db -export const uploadCloudDbFile = (token, file) => { +// 上传db文件(.db / .sqlite 等数据库文件) +export const uploadCloudDbFile = (token, filePath) => { return new Promise((resolve, reject) => { + // filePath 可能是字符串路径或 { tempFilePath, name } 对象 + const fileUri = typeof filePath === 'string' ? filePath : (filePath.tempFilePath || filePath.path || + filePath); + const fileName = typeof filePath === 'string' ? + filePath.split('/').pop() || 'database.db' : + (filePath.name || 'database.db'); uni.uploadFile({ url: `${BASE_URL}/cloud_api/database/upload/db`, method: "POST", - // 不要手动设置 Content-Type,浏览器自动生成 multipart/form-data - header: { - // 如果后端把token放header就写这里,放表单里就写到formData - }, - // 普通文本参数(对应form-data里的文本项) + header: {}, formData: { access_token: token }, - // 多文件:每个文件name都叫files,和Postman保持一致 - file: files, + file: { + name: fileName, + uri: fileUri + }, + files: [{ + name: 'file', + uri: fileUri + }], success: (res) => { if (res.statusCode === 200) { try { @@ -1168,7 +1285,7 @@ export const deleteCloudDb = (token, databaseId) => { }, data: { "access_token": token, - "database_id": databaseName + "database_id": databaseId }, success: (res) => { if (res.statusCode === 200) { @@ -1195,7 +1312,7 @@ export const deleteCloudDb = (token, databaseId) => { export const getCloudDbTables = (token, databaseId, isDetail) => { return new Promise((resolve, reject) => { uni.request({ - url: `${BASE_URL}/cloud_api/database/list`, + url: `${BASE_URL}/cloud_api/database/tables`, method: "POST", header: { 'Content-Type': 'application/json' @@ -1226,16 +1343,54 @@ export const getCloudDbTables = (token, databaseId, isDetail) => { }) } +// 获取表数据 +export const getCloudDbTableData = (token, databaseId, tableName, limit = "20", offset = "0") => { + return new Promise((resolve, reject) => { + uni.request({ + url: `${BASE_URL}/cloud_api/database/table/data`, + method: "POST", + header: { + 'Content-Type': 'application/json' + }, + data: { + "access_token": token, + "database_id": databaseId, + "table_name": tableName, + "limit": limit, + "offset": offset + }, + success: (res) => { + if (res.statusCode === 200) { + const respond = res.data + if (respond.success) { + resolve(respond.data) + } else { + const msg = respond?.error || '获取表数据出错啦' + reject(msg) + } + } else { + reject(`获取表数据失败:${res.statusCode}`) + } + }, + fail: (err) => { + const msg = err.errMsg || '网络错误' + reject(msg) + } + }) + }) +} + + // 删除数据库中的表 export const deleteCloudDbTable = async (token, databaseId, tableName) => { return new Promise((resolve, reject) => { uni.request({ - url: `${BASE_URL}/delete_conversation`, + url: `${BASE_URL}/cloud_api/database/table/drop`, method: "POST", data: { "access_token": token, "database_id": databaseId, - "table_name": table_name + "table_name": tableName }, header: { 'Content-Type': 'application/json' @@ -1246,7 +1401,7 @@ export const deleteCloudDbTable = async (token, databaseId, tableName) => { if (respond?.success) { resolve(respond.message) } else { - const msg = respond.failed_ids.error || '删除数据库中的表出错啦' + const msg = respond.error || '删除数据库中的表出错啦' reject(msg) } } else { @@ -1262,7 +1417,7 @@ export const deleteCloudDbTable = async (token, databaseId, tableName) => { } // 更新表数据 -export const updateCloudDbTableData = async (token, databaseId, tableName, whereData, updateData) => { +export const updateCloudDbTableData = (token, databaseId, tableName, whereData, updateData) => { return new Promise((resolve, reject) => { uni.request({ url: `${BASE_URL}/cloud_api/database/table/update/by/id`, @@ -1270,13 +1425,9 @@ export const updateCloudDbTableData = async (token, databaseId, tableName, where data: { "access_token": token, "database_id": databaseId, - "table_name": table_name, - "where_data": { - "_row_id": 2 - }, - "update_data": { - "问题": "《水土保持监理规范2344444》制定的目的是什么" - } + "table_name": tableName, + "where_data": whereData, + "update_data": updateData }, header: { 'Content-Type': 'application/json' @@ -1287,7 +1438,7 @@ export const updateCloudDbTableData = async (token, databaseId, tableName, where if (respond?.success) { resolve(respond.message) } else { - const msg = respond.failed_ids.error || '更新表数据出错啦' + const msg = respond.error || '更新表数据出错啦' reject(msg) } } else { @@ -1304,24 +1455,35 @@ export const updateCloudDbTableData = async (token, databaseId, tableName, where // 导入文件到数据库 -export const importFileToCloudDb = (token, forceOverwrite, databaseId, file, tableName) => { +export const importFileToCloudDb = (token, forceOverwrite, databaseId, filePath, tableName) => { return new Promise((resolve, reject) => { + // filePath 可能是字符串路径或 { tempFilePath, name } 对象 + const fileUri = typeof filePath === 'string' ? filePath : (filePath.tempFilePath || filePath.path || + filePath); + const fileName = typeof filePath === 'string' ? + filePath.split('/').pop() || 'file' : + (filePath.name || 'file'); + uni.uploadFile({ - url: `${BASE_URL}/cloud_api/file/upload`, + url: `${BASE_URL}/cloud_api/database/import`, method: "POST", - // 不要手动设置 Content-Type,浏览器自动生成 multipart/form-data - header: { - // 如果后端把token放header就写这里,放表单里就写到formData - }, - // 普通文本参数(对应form-data里的文本项) + header: {}, formData: { access_token: token, force_overwrite: forceOverwrite, database_id: databaseId, - team_id: teamIdStr, table_name: tableName }, - file: file, + // uni.uploadFile 的 file 参数需要是对象格式:{ name, uri } + file: { + name: fileName, + uri: fileUri + }, + // 同时用 files 方式兜底 + files: [{ + name: 'file', + uri: fileUri + }], success: (res) => { if (res.statusCode === 200) { @@ -1349,18 +1511,23 @@ export const importFileToCloudDb = (token, forceOverwrite, databaseId, file, tab }; // 查看 个人/团队 数据库权限信息 -export const getCloudDbPermission = async (token, databaseId, type, Id) => { +export const getCloudDbPermission = (token, databaseId, type, id) => { return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId + }; + // type 只能是 user_id 或 team_id + if (type === 'user_id') { + requestData.user_id = id; + } else if (type === 'team_id') { + requestData.team_id = id; + } + uni.request({ url: `${BASE_URL}/cloud_api/database/permission/info`, method: "POST", - data: { - "access_token": token, - "database_id": databaseId, - type: Id - // "team_id": "6a02f6f0d99a03faefd1f437", - // "user_id": "690c72a6b8ffa329af2d5607", - }, + data: requestData, header: { 'Content-Type': 'application/json' }, @@ -1368,9 +1535,13 @@ export const getCloudDbPermission = async (token, databaseId, type, Id) => { if (res.statusCode === 200) { const respond = res.data if (respond?.success) { - resolve(respond.message) + // team_id 格式: { success: true, data: [...] } + resolve(respond.data) + } else if (Array.isArray(respond)) { + // user_id 格式: 直接返回数组 [...] + resolve(respond) } else { - const msg = respond.failed_ids.error || '查看 个人/团队 数据库权限信息出错啦' + const msg = respond?.error || '查看 个人/团队 数据库权限信息出错啦' reject(msg) } } else { @@ -1386,18 +1557,22 @@ export const getCloudDbPermission = async (token, databaseId, type, Id) => { } // 删除 团队/用户 对数据库权限 -export const deleteCloudDbPermission = async (token, databaseId, type, Id) => { +export const deleteCloudDbPermission = (token, databaseId, type, id) => { return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId + }; + if (type === 'user_id') { + requestData.user_id = id; + } else if (type === 'team_id') { + requestData.team_id = id; + } + uni.request({ url: `${BASE_URL}/cloud_api/database/permission/delete`, method: "POST", - data: { - "access_token": token, - "database_id": databaseId, - type: Id - // "team_id": "6a02f6f0d99a03faefd1f437", - // "user_id": "690c72a6b8ffa329af2d5607", - }, + data: requestData, header: { 'Content-Type': 'application/json' }, @@ -1407,7 +1582,7 @@ export const deleteCloudDbPermission = async (token, databaseId, type, Id) => { if (respond?.success) { resolve(respond.message) } else { - const msg = respond.failed_ids.error || '删除 团队/用户 对数据库权限出错啦' + const msg = respond.error || '删除 团队/用户 对数据库权限出错啦' reject(msg) } } else { @@ -1423,19 +1598,23 @@ export const deleteCloudDbPermission = async (token, databaseId, type, Id) => { } // 修改/增加 团队/用户 对数据库权限 -export const updateCloudDbPermission = async (token, databaseId, type, Id, level) => { +export const updateCloudDbPermission = (token, databaseId, type, id, level) => { return new Promise((resolve, reject) => { + const requestData = { + "access_token": token, + "database_id": databaseId, + "access_level": level + }; + if (type === 'user_id') { + requestData.user_id = id; + } else if (type === 'team_id') { + requestData.team_id = id; + } + uni.request({ url: `${BASE_URL}/cloud_api/database/permission/update`, method: "POST", - data: { - "access_token": token, - "database_id": databaseId, - "access_level": "3", - type: Id, - // "team_id": "6a02f6f0d99a03faefd1f437", - // "user_id": "690c72a6b8ffa329af2d5607", - }, + data: requestData, header: { 'Content-Type': 'application/json' }, @@ -1445,7 +1624,7 @@ export const updateCloudDbPermission = async (token, databaseId, type, Id, level if (respond?.success) { resolve(respond.message) } else { - const msg = respond.failed_ids.error || '修改/增加 团队/用户 对数据库权限出错啦' + const msg = respond.error || '修改/增加 团队/用户 对数据库权限出错啦' reject(msg) } } else { @@ -1461,7 +1640,7 @@ export const updateCloudDbPermission = async (token, databaseId, type, Id, level } // 个人数据库移交团队 -export const dbTransferToTeam = async (token, databaseId,teamId) => { +export const dbTransferToTeam = async (token, databaseId, teamId) => { return new Promise((resolve, reject) => { uni.request({ url: `${BASE_URL}/cloud_api/database/transfer_to_team`, @@ -1480,7 +1659,7 @@ export const dbTransferToTeam = async (token, databaseId,teamId) => { if (respond?.success) { resolve(respond.message) } else { - const msg = respond.failed_ids.error || '个人数据库移交团队出错啦' + const msg = respond.error || '个人数据库移交团队出错啦' reject(msg) } } else {