Skip to content

Commit a5ae9d9

Browse files
authored
feat: 开发消息功能 (#11)
* feat: back title * feat: 本地联调 * feat: 聊天室初始化,以及联动query * feat: useSocket,online users count * feat: 调整useSocket、useCreateRoom(优化hook) * feat: 拆分roomInfo、roomConnect 的 hook * feat: chat room 基本布局 * feat: chat * fix: 样式 + emoji * feat: 拖拽改变元素大小的hook,一些样式fix * feat: video chat init * feat: 调试摄像头、audio信息 * feat: video的一些设置,代码优化 * fix: 样式 * feat: 视频聊天的连接测试 * feat: https * feat: 多人视频通话,待优化整理代码 * feat: 代码优化、边界处理 * feat: 优化一轮使用体验 * feat: 构建相关
1 parent 40d7619 commit a5ae9d9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+3483
-54
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,5 @@ package-lock.json
5353

5454

5555
docker/mysql/data/*
56+
57+
client_dist

client/.vscode/settings.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
{
2+
}

client/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@
44
"description": "",
55
"main": "index.js",
66
"scripts": {
7-
"dev:web": "pnpm -C packages/rtc-web dev"
7+
"dev:web": "pnpm -C packages/rtc-web dev",
8+
"build:web": "pnpm -C packages/rtc-web build"
89
},
910
"keywords": [],
1011
"author": "",

client/packages/rtc-web/.eslintrc.cjs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,11 @@ module.exports = {
1818
},
1919
plugins: ['vue', '@typescript-eslint', 'prettier'],
2020
rules: {
21-
indent: ['error', 2],
21+
indent: ['error', 2, { offsetTernaryExpressions: true }],
2222
semi: ['error', 'always'],
2323
'vue/attribute-hyphenation': 'off',
2424
'@typescript-eslint/no-explicit-any': 'off',
2525
'no-debugger': 'off',
26+
'@typescript-eslint/no-non-null-assertion': 'off',
2627
},
2728
};

client/packages/rtc-web/package.json

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,15 @@
1111
"@types/lodash": "^4.14.195",
1212
"@vitejs/plugin-vue-jsx": "^3.0.1",
1313
"@vueuse/core": "^10.2.0",
14+
"@vueuse/router": "^10.2.1",
15+
"dayjs": "^1.11.9",
1416
"lodash": "^4.17.21",
1517
"nanoid": "^4.0.2",
18+
"socket.io-client": "2.3.0",
1619
"vue": "^3.3.4",
17-
"vue-router": "4"
20+
"vue-router": "4",
21+
"vue3-emoji-picker": "^1.1.7",
22+
"vue3-popper": "^1.5.0"
1823
},
1924
"devDependencies": {
2025
"@types/node": "^20.3.1",
@@ -32,7 +37,9 @@
3237
"prettier": "^2.8.8",
3338
"prettier-plugin-tailwindcss": "^0.3.0",
3439
"tailwindcss": "^3.3.2",
40+
"terser": "^5.19.4",
3541
"typescript": "^5.1.3",
42+
"vconsole": "^3.15.1",
3643
"vite": "^4.3.9",
3744
"vite-plugin-eslint": "^1.8.1",
3845
"vite-plugin-svg-icons": "^2.0.1",
Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,20 @@
11
<script lang="ts" setup>
22
import Layout from '@/layout/index.vue';
3+
import ErrorBoundary from '@/components/error-boundary/index.vue';
4+
import { useErrorCaptured } from '@/hooks';
5+
6+
const errors = useErrorCaptured();
37
</script>
48

59
<!-- 这里后面可以加 provider、区分登录和未登录页面 -->
610
<template>
7-
<Layout />
11+
<Suspense>
12+
<Layout />
13+
<template v-if="errors.length" #fallback>
14+
<ErrorBoundary
15+
class="h-screen"
16+
:tips-list="['服务器开小差了,请联系管理员']"
17+
/>
18+
</template>
19+
</Suspense>
820
</template>
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,21 @@
11
@import './tailwindcss';
2+
3+
/* width */
4+
::-webkit-scrollbar {
5+
width: 4px;
6+
}
7+
8+
/* Track */
9+
::-webkit-scrollbar-track {
10+
background: #f1f1f1;
11+
}
12+
13+
/* Handle */
14+
::-webkit-scrollbar-thumb {
15+
background: #888;
16+
}
17+
18+
/* Handle on hover */
19+
::-webkit-scrollbar-thumb:hover {
20+
background: #555;
21+
}
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading

0 commit comments

Comments
 (0)