增加width、height、theme、simple参数,修复快捷发送可以发送空消息的问题,优化文档

This commit is contained in:
fan
2021-01-18 21:42:54 +08:00
parent 1e626ee84e
commit e88da7ae19
8 changed files with 104 additions and 15 deletions
+38
View File
@@ -10,6 +10,7 @@
<lemon-imui
:user="user"
ref="IMUI"
:theme="theme"
:hide-menu="hideMenu"
:hide-menu-avatar="hideMenuAvatar"
:hide-message-name="hideMessageName"
@@ -57,6 +58,8 @@
>切换头像显示</lemon-button
>
<lemon-button @click="changeMessageNameVisible">切换聊天窗口内联系人名字显示</lemon-button>
<br/>
<lemon-button @click="changeTheme">切换主题当前主题{{this.theme}}</lemon-button>
</div>
</div>
@@ -220,6 +223,34 @@
<td width="100">-</td>
<td>{id: "1",displayName: "测试",avatar: "url"};</td>
</tr>
<tr>
<td width="150">width</td>
<td width="350">宽度</td>
<td width="150">String</td>
<td width="100">850px</td>
<td></td>
</tr>
<tr>
<td width="150">height</td>
<td width="350">高度</td>
<td width="150">String</td>
<td width="100">580px</td>
<td></td>
</tr>
<tr>
<td width="150">theme</td>
<td width="350">主题</td>
<td width="150">default | blue</td>
<td width="100">default</td>
<td>主题颜色</td>
</tr>
<tr>
<td width="150">simple</td>
<td width="350">精简模式</td>
<td width="150">Boolean</td>
<td width="100">false</td>
<td>精简模式下左侧的导航和联系人列表会隐藏初始化时需要手动调用 changeContact 切换到聊天视图</td>
</tr>
<tr>
<td>messageTimeFormat</td>
<td>消息列表时间格式化函数</td>
@@ -652,6 +683,7 @@ export default {
name: "app",
data() {
return {
theme:'default',
tip:tip,
packageData,
hideMenuAvatar: false,
@@ -705,6 +737,9 @@ export default {
const { IMUI } = this.$refs;
// setTimeout(()=>{
// IMUI.changeContact('contact-1');
// },2000);
let data = [
{ ...contactData1 },
@@ -1117,6 +1152,9 @@ export default {
})
},
methods: {
changeTheme(){
this.theme = this.theme == 'default' ? 'blue' : 'default';
},
scrollToTop(){
document.body.scrollIntoView();
},
File diff suppressed because one or more lines are too long
+1 -1
View File
@@ -1 +1 @@
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><link rel=icon href=favicon.ico><title>Lemon IMUI</title><link href=css/index.895c486f.css rel=preload as=style><link href=js/chunk-vendors.e4810482.js rel=preload as=script><link href=js/index.26d175a9.js rel=preload as=script><link href=css/index.895c486f.css rel=stylesheet></head><body><noscript><strong>We're sorry but flat-im doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=js/chunk-vendors.e4810482.js></script><script src=js/index.26d175a9.js></script></body></html>
<!DOCTYPE html><html lang=en><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=no"><link rel=icon href=favicon.ico><title>Lemon IMUI</title><link href=css/index.4f9dd622.css rel=preload as=style><link href=js/chunk-vendors.e4810482.js rel=preload as=script><link href=js/index.7a6ff8e6.js rel=preload as=script><link href=css/index.4f9dd622.css rel=stylesheet></head><body><noscript><strong>We're sorry but flat-im doesn't work properly without JavaScript enabled. Please enable it to continue.</strong></noscript><div id=app></div><script src=js/chunk-vendors.e4810482.js></script><script src=js/index.7a6ff8e6.js></script></body></html>
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long