im-ui-mobile 0.0.98 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. package/components/im-avatar/im-avatar.vue +121 -121
  2. package/components/im-button/im-button.vue +630 -626
  3. package/components/im-cell/im-cell.vue +10 -15
  4. package/components/im-cell-group/im-cell-group.vue +16 -16
  5. package/components/im-chat-item/im-chat-item.vue +213 -213
  6. package/components/im-context-menu/im-context-menu.vue +138 -138
  7. package/components/im-file-upload/im-file-upload.vue +309 -309
  8. package/components/im-friend-item/im-friend-item.vue +82 -75
  9. package/components/im-group-item/im-group-item.vue +62 -62
  10. package/components/im-group-member-selector/im-group-member-selector.vue +202 -202
  11. package/components/im-group-rtc-join/im-group-rtc-join.vue +112 -112
  12. package/components/im-image-upload/im-image-upload.vue +94 -94
  13. package/components/im-loading/im-loading.vue +64 -64
  14. package/components/im-mention-picker/im-mention-picker.vue +191 -191
  15. package/components/im-message-item/im-message-item.vue +555 -555
  16. package/components/im-nav-bar/im-nav-bar.vue +98 -98
  17. package/components/im-read-receipt/im-read-receipt.vue +174 -174
  18. package/components/im-virtual-list/im-virtual-list.vue +52 -51
  19. package/components/im-voice-input/im-voice-input.vue +305 -305
  20. package/libs/index.ts +2 -3
  21. package/package.json +58 -58
  22. package/styles/button.scss +1 -1
  23. package/theme.scss +61 -62
  24. package/types/components.d.ts +0 -1
  25. package/types/index.d.ts +94 -94
  26. package/types/libs/index.d.ts +206 -204
  27. package/types/utils/datetime.d.ts +9 -9
  28. package/types/utils/dom.d.ts +11 -11
  29. package/types/utils/emoji.d.ts +8 -8
  30. package/types/utils/enums.d.ts +73 -73
  31. package/types/utils/messageType.d.ts +35 -35
  32. package/types/utils/recorderApp.d.ts +9 -9
  33. package/types/utils/recorderH5.d.ts +9 -9
  34. package/types/utils/requester.d.ts +15 -15
  35. package/types/utils/url.d.ts +5 -5
  36. package/types/utils/useDynamicRefs.d.ts +9 -9
  37. package/types/utils/websocket.d.ts +34 -34
  38. package/utils/enums.js +1 -1
  39. package/components/im-virtual-scroller/im-virtual-scroller.vue +0 -54
  40. package/types/components/virtual-scroller.d.ts +0 -20
package/package.json CHANGED
@@ -1,59 +1,59 @@
1
- {
2
- "name": "im-ui-mobile",
3
- "version": "0.0.98",
4
- "description": "A Vue3.0 + Typescript instant messaging component library for Uniapp",
5
- "type": "module",
6
- "main": "index.js",
7
- "types": "types/index.d.ts",
8
- "files": [
9
- "components",
10
- "libs",
11
- "types",
12
- "utils",
13
- "plugins",
14
- "index.js",
15
- "styles",
16
- "theme.scss",
17
- "index.scss"
18
- ],
19
- "scripts": {
20
- "wx": "cd examples1 && npm run dev:mp-weixin",
21
- "h5": "cd examples1 && npm run dev:h5",
22
- "build": "npm run build:types",
23
- "build:types": "vue-tsc -p tsconfig.build.json",
24
- "clean:types": "rmdir /s /q src/types 2>nul # '删除 types 目录'",
25
- "prepublishOnly": "npm run build"
26
- },
27
- "devDependencies": {
28
- "@dcloudio/uni-app": "3.0.0-4070520250711001",
29
- "@dcloudio/types": "^3.4.8",
30
- "@dcloudio/uni-cli-shared": "3.0.0-4070520250711001",
31
- "@dcloudio/vite-plugin-uni": "3.0.0-4070520250711001",
32
- "@types/node": "^24.10.1",
33
- "@vitejs/plugin-vue": "^4.0.0",
34
- "typescript": "~5.4.5",
35
- "vite": "^4.0.0",
36
- "vite-plugin-dts": "^3.0.0",
37
- "vue-tsc": "^1.0.0"
38
- },
39
- "peerDependencies": {
40
- "@dcloudio/uni-app": "3.0.0-4070520250711001",
41
- "uview-plus": "^3.1.0",
42
- "vue": "^3.3.0",
43
- "pinia": "^2.1.7"
44
- },
45
- "peerDependenciesMeta": {
46
- "pinia": {
47
- "optional": true
48
- }
49
- },
50
- "keywords": [
51
- "vue3",
52
- "components",
53
- "ui",
54
- "instant-messaging",
55
- "chat"
56
- ],
57
- "author": "Joncky Cai",
58
- "license": "MIT"
1
+ {
2
+ "name": "im-ui-mobile",
3
+ "version": "0.1.0",
4
+ "description": "A Vue3.0 + Typescript instant messaging component library for Uniapp",
5
+ "type": "module",
6
+ "main": "index.js",
7
+ "types": "types/index.d.ts",
8
+ "files": [
9
+ "components",
10
+ "libs",
11
+ "types",
12
+ "utils",
13
+ "plugins",
14
+ "index.js",
15
+ "styles",
16
+ "theme.scss",
17
+ "index.scss"
18
+ ],
19
+ "scripts": {
20
+ "wx": "cd examples-dev && npm run dev:mp-weixin",
21
+ "h5": "cd examples-dev && npm run dev:h5",
22
+ "build": "npm run build:types",
23
+ "build:types": "vue-tsc -p tsconfig.build.json",
24
+ "clean:types": "rmdir /s /q src/types 2>nul # '删除 types 目录'",
25
+ "prepublishOnly": "npm run build"
26
+ },
27
+ "devDependencies": {
28
+ "@dcloudio/uni-app": "3.0.0-4070520250711001",
29
+ "@dcloudio/types": "^3.4.8",
30
+ "@dcloudio/uni-cli-shared": "3.0.0-4070520250711001",
31
+ "@dcloudio/vite-plugin-uni": "3.0.0-4070520250711001",
32
+ "@types/node": "^24.10.1",
33
+ "@vitejs/plugin-vue": "^4.0.0",
34
+ "typescript": "~5.4.5",
35
+ "vite": "^4.0.0",
36
+ "vite-plugin-dts": "^3.0.0",
37
+ "vue-tsc": "^1.0.0"
38
+ },
39
+ "peerDependencies": {
40
+ "@dcloudio/uni-app": "3.0.0-4070520250711001",
41
+ "uview-plus": "^3.1.0",
42
+ "vue": "^3.3.0",
43
+ "pinia": "^2.1.7"
44
+ },
45
+ "peerDependenciesMeta": {
46
+ "pinia": {
47
+ "optional": true
48
+ }
49
+ },
50
+ "keywords": [
51
+ "vue3",
52
+ "components",
53
+ "ui",
54
+ "instant-messaging",
55
+ "chat"
56
+ ],
57
+ "author": "Joncky Cai",
58
+ "license": "MIT"
59
59
  }
@@ -28,7 +28,7 @@ button[type='warn'][plain] {
28
28
  }
29
29
 
30
30
  button[size='mini'] {
31
- font-size: $im-font-size-smaller !important;
31
+ font-size: $im-font-size-small !important;
32
32
  }
33
33
 
34
34
  // #endif
package/theme.scss CHANGED
@@ -1,62 +1,61 @@
1
- // 颜色
2
- $im-color-primary: #3e45d7;
3
- $im-color-primary-light-1: mix(#fff, $im-color-primary, 10%);
4
- $im-color-primary-light-2: mix(#fff, $im-color-primary, 20%);
5
- $im-color-primary-light-3: mix(#fff, $im-color-primary, 30%);
6
- $im-color-primary-light-4: mix(#fff, $im-color-primary, 40%);
7
- $im-color-primary-light-5: mix(#fff, $im-color-primary, 50%);
8
- $im-color-primary-light-6: mix(#fff, $im-color-primary, 60%);
9
- $im-color-primary-light-7: mix(#fff, $im-color-primary, 70%);
10
- $im-color-primary-light-8: mix(#fff, $im-color-primary, 80%);
11
- $im-color-primary-light-9: mix(#fff, $im-color-primary, 90%);
12
- $im-color-primary-dark-1: mix(#000, $im-color-primary, 10%);
13
- $im-color-primary-dark-2: mix(#000, $im-color-primary, 20%);
14
- $im-color-primary-dark-3: mix(#000, $im-color-primary, 30%);
15
- $im-color-primary-dark-4: mix(#000, $im-color-primary, 40%);
16
-
17
- $im-color-success: #18bc37;
18
- $im-color-warning: #f3a73f;
19
- $im-color-danger: #e43d33;
20
- $im-color-info: #8f939c;
21
-
22
- // 文字颜色
23
- $im-text-color: #000000;
24
- $im-text-color-light: #6a6a6a;
25
- $im-text-color-lighter: #909399;
26
- $im-text-color-lighter-extra: #c7c7c7;
27
-
28
- // 边框颜色
29
- $im-border: #F0F0F0;
30
- $im-border-light: #EDEDED;
31
- $im-border-lighter: #DCDCDC;
32
- $im-border-lighter-extra: #B9B9B9;
33
-
34
- // 文字大小
35
- $im-font-size: 30rpx;
36
- $im-font-size-small: 28rpx;
37
- $im-font-size-smaller: 26rpx;
38
- $im-font-size-smaller-extra: 24rpx;
39
- $im-font-size-large: 32rpx;
40
- $im-font-size-larger: 34rpx;
41
- $im-font-size-larger-extra: 36rpx;
42
-
43
- // 阴影
44
- $im-box-shadow: 0 2px 4px rgba(0, 0, 0, .12), 0 0 6px rgba(0, 0, 0, .04);
45
- $im-box-shadow-light: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
46
- $im-box-shadow-lighter: 0px 0px 6px rgba(0, 0, 0, .12);
47
- $im-box-shadow-dark: 0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5);
48
-
49
- // 背景
50
- $im-bg: #f8f9ff;
51
- $im-bg-linear: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
52
- $im-bg-active: #f7f8fc;
53
- $im-bg-active-dark: $im-color-primary-light-9;
54
- $im-bg-input: #fafafa;
55
-
56
-
57
- // 标题
58
- $im-title-size: 26px;
59
- $im-title-size-1: 22px;
60
- $im-title-size-2: 18px;
61
-
62
- $im-nav-bar-height: 50px;
1
+ // 颜色
2
+ $im-color-primary: #3e45d7;
3
+ $im-color-primary-light-1: mix(#fff, $im-color-primary, 10%);
4
+ $im-color-primary-light-2: mix(#fff, $im-color-primary, 20%);
5
+ $im-color-primary-light-3: mix(#fff, $im-color-primary, 30%);
6
+ $im-color-primary-light-4: mix(#fff, $im-color-primary, 40%);
7
+ $im-color-primary-light-5: mix(#fff, $im-color-primary, 50%);
8
+ $im-color-primary-light-6: mix(#fff, $im-color-primary, 60%);
9
+ $im-color-primary-light-7: mix(#fff, $im-color-primary, 70%);
10
+ $im-color-primary-light-8: mix(#fff, $im-color-primary, 80%);
11
+ $im-color-primary-light-9: mix(#fff, $im-color-primary, 90%);
12
+ $im-color-primary-dark-1: mix(#000, $im-color-primary, 10%);
13
+ $im-color-primary-dark-2: mix(#000, $im-color-primary, 20%);
14
+ $im-color-primary-dark-3: mix(#000, $im-color-primary, 30%);
15
+ $im-color-primary-dark-4: mix(#000, $im-color-primary, 40%);
16
+
17
+ $im-color-success: #18bc37;
18
+ $im-color-warning: #f3a73f;
19
+ $im-color-danger: #e43d33;
20
+ $im-color-info: #8f939c;
21
+
22
+ // 文字颜色
23
+ $im-text-color: #000000;
24
+ $im-text-color-light: #6a6a6a;
25
+ $im-text-color-lighter: #909399;
26
+ $im-text-color-lighter-extra: #c7c7c7;
27
+
28
+ // 边框颜色
29
+ $im-border: #F0F0F0;
30
+ $im-border-light: #EDEDED;
31
+ $im-border-lighter: #DCDCDC;
32
+ $im-border-lighter-extra: #B9B9B9;
33
+
34
+ // 文字大小
35
+ $im-font-size: 26rpx;
36
+ $im-font-size-small: 18rpx;
37
+ $im-font-size-mini: 14rpx;
38
+ $im-font-size-large: 32rpx;
39
+ $im-font-size-largex: 38rpx;
40
+ $im-font-size-largexx: 44rpx;
41
+
42
+ // 阴影
43
+ $im-box-shadow: 0 2px 4px rgba(0, 0, 0, .12), 0 0 6px rgba(0, 0, 0, .04);
44
+ $im-box-shadow-light: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
45
+ $im-box-shadow-lighter: 0px 0px 6px rgba(0, 0, 0, .12);
46
+ $im-box-shadow-dark: 0px 1px 10px 2px rgba($color: #a5a4a4, $alpha: 0.5);
47
+
48
+ // 背景
49
+ $im-bg: #f8f9ff;
50
+ $im-bg-linear: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
51
+ $im-bg-active: #f7f8fc;
52
+ $im-bg-active-dark: $im-color-primary-light-9;
53
+ $im-bg-input: #fafafa;
54
+
55
+
56
+ // 标题
57
+ $im-title-size: 26px;
58
+ $im-title-size-1: 22px;
59
+ $im-title-size-2: 18px;
60
+
61
+ $im-nav-bar-height: 50px;
@@ -16,7 +16,6 @@ declare module 'vue' {
16
16
  ['im-avatar']: typeof import('./components/avatar')['Avatar']
17
17
  ['im-loading']: typeof import('./components/loading')['Loading']
18
18
  ['im-context-menu']: typeof import('./components/context-menu')['ContextMenu']
19
- ['im-virtual-scroller']: typeof import('./components/virtual-scroller')['VirtualScroller']
20
19
  ['im-virtual-list']: typeof import('./components/virtual-list')['VirtualList']
21
20
  }
22
21
  }
package/types/index.d.ts CHANGED
@@ -1,95 +1,95 @@
1
- /// <reference path="./components.d.ts" />
2
-
3
- import eventBus from "./utils/eventBus.d.ts";
4
- import datetime from "./utils/datetime.d.ts";
5
- import Emoji from "./utils/emoji.d.ts";
6
- import { MESSAGE_TYPE, RTC_STATE, TERMINAL_TYPE, MESSAGE_STATUS } from "./utils/enums.d.ts";
7
- import * as dom from "./utils/dom.d.ts";
8
- import messageType from "./utils/messageType.d.ts";
9
- import RecorderApp from "./utils/recorderApp.d.ts";
10
- import RecorderH5 from "./utils/recorderH5.d.ts";
11
- import Requester from "./utils/requester.d.ts";
12
- import * as url from "./utils/url.d.ts";
13
- import { useDynamicRefs } from "./utils/useDynamicRefs.d.ts";
14
- import WebSocket from "./utils/websocket.d.ts";
15
- import type {
16
- // 类型常量
17
- RtcMode,
18
- RtcInfo,
19
- Chat,
20
- Message,
21
- Friend,
22
- OnlineTerminal,
23
- MenuItem,
24
- WebRTCMessage,
25
- GroupMember,
26
- Group,
27
- UploadImageResponse,
28
- SubmitItem,
29
- ImageItem,
30
- FileItem,
31
- ApiResponse,
32
- RecorderError,
33
- UploadRecorderFileResponse,
34
- UploadRecorderFileResult,
35
- RecorderFile,
36
- UserInfo,
37
- Response
38
- } from './libs';
39
-
40
- declare module 'im-ui-mobile' {
41
- export function install(): void
42
-
43
- interface Config {
44
- baseUrl: string;
45
- emojiUrl: string;
46
- }
47
-
48
- function getConfig(): Config;
49
-
50
- export {
51
- getConfig,
52
- eventBus,
53
- datetime,
54
- Emoji,
55
- dom,
56
- messageType,
57
- Requester,
58
- url,
59
- useDynamicRefs,
60
- WebSocket,
61
- RecorderApp,
62
- RecorderH5,
63
-
64
- // 枚举类型
65
- RTC_STATE,
66
- MESSAGE_TYPE,
67
- TERMINAL_TYPE,
68
- MESSAGE_STATUS,
69
-
70
- // 类型常量
71
- RtcMode,
72
- RtcInfo,
73
- Chat,
74
- Message,
75
- Friend,
76
- OnlineTerminal,
77
- MenuItem,
78
- WebRTCMessage,
79
- GroupMember,
80
- Group,
81
- UploadImageResponse,
82
- SubmitItem,
83
- ImageItem,
84
- FileItem,
85
- ApiResponse,
86
- RecorderError,
87
- UploadRecorderFileResponse,
88
- UploadRecorderFileResult,
89
- RecorderFile,
90
- UserInfo,
91
- Response
92
- }
93
- }
94
-
1
+ /// <reference path="./components.d.ts" />
2
+
3
+ import eventBus from "./utils/eventBus.d.ts";
4
+ import datetime from "./utils/datetime.d.ts";
5
+ import Emoji from "./utils/emoji.d.ts";
6
+ import { MESSAGE_TYPE, RTC_STATE, TERMINAL_TYPE, MESSAGE_STATUS } from "./utils/enums.d.ts";
7
+ import * as dom from "./utils/dom.d.ts";
8
+ import messageType from "./utils/messageType.d.ts";
9
+ import RecorderApp from "./utils/recorderApp.d.ts";
10
+ import RecorderH5 from "./utils/recorderH5.d.ts";
11
+ import Requester from "./utils/requester.d.ts";
12
+ import * as url from "./utils/url.d.ts";
13
+ import { useDynamicRefs } from "./utils/useDynamicRefs.d.ts";
14
+ import WebSocket from "./utils/websocket.d.ts";
15
+ import type {
16
+ // 类型常量
17
+ RtcMode,
18
+ RtcInfo,
19
+ Chat,
20
+ Message,
21
+ Friend,
22
+ OnlineTerminal,
23
+ MenuItem,
24
+ WebRTCMessage,
25
+ GroupMember,
26
+ Group,
27
+ UploadImageResponse,
28
+ SubmitItem,
29
+ ImageItem,
30
+ FileItem,
31
+ ApiResponse,
32
+ RecorderError,
33
+ UploadRecorderFileResponse,
34
+ UploadRecorderFileResult,
35
+ RecorderFile,
36
+ UserInfo,
37
+ Response
38
+ } from './libs';
39
+
40
+ declare module 'im-ui-mobile' {
41
+ export function install(): void
42
+
43
+ interface Config {
44
+ baseUrl: string;
45
+ emojiUrl: string;
46
+ }
47
+
48
+ function getConfig(): Config;
49
+
50
+ export {
51
+ getConfig,
52
+ eventBus,
53
+ datetime,
54
+ Emoji,
55
+ dom,
56
+ messageType,
57
+ Requester,
58
+ url,
59
+ useDynamicRefs,
60
+ WebSocket,
61
+ RecorderApp,
62
+ RecorderH5,
63
+
64
+ // 枚举类型
65
+ RTC_STATE,
66
+ MESSAGE_TYPE,
67
+ TERMINAL_TYPE,
68
+ MESSAGE_STATUS,
69
+
70
+ // 类型常量
71
+ RtcMode,
72
+ RtcInfo,
73
+ Chat,
74
+ Message,
75
+ Friend,
76
+ OnlineTerminal,
77
+ MenuItem,
78
+ WebRTCMessage,
79
+ GroupMember,
80
+ Group,
81
+ UploadImageResponse,
82
+ SubmitItem,
83
+ ImageItem,
84
+ FileItem,
85
+ ApiResponse,
86
+ RecorderError,
87
+ UploadRecorderFileResponse,
88
+ UploadRecorderFileResult,
89
+ RecorderFile,
90
+ UserInfo,
91
+ Response
92
+ }
93
+ }
94
+
95
95
  export { MESSAGE_TYPE, RTC_STATE, TERMINAL_TYPE, MESSAGE_STATUS }