修复BUG,v-lemon-contextmenu支持左键触发

This commit is contained in:
fan
2021-02-06 02:38:01 +08:00
parent 93dc874ea6
commit 0e9504f9b4
24 changed files with 15892 additions and 11585 deletions
+147
View File
@@ -0,0 +1,147 @@
export default [
{
id: 1,
displayName: "像梦一样自由",
avatar: "https://p.qqan.com/up/2020-2/2020022821001845128.jpg",
index: "X",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "你开心吗",
},
{
id: 2,
displayName: "梦醒时分、",
avatar: "https://p.qqan.com/up/2021-1/20211301122243621.jpg",
index: "M",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 3,
displayName: "凌云",
avatar: "https://p.qqan.com/up/2021-1/2021129102387841.jpg",
index: "L",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 4,
displayName: "小郭",
avatar: "https://p.qqan.com/up/2021-1/2021122135507881.jpg",
index: "X",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 5,
displayName: "杨玉泉",
avatar: "https://p.qqan.com/up/2021-1/20211211131598147.jpg",
index: "Y",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 6,
displayName: "森系Style",
avatar: "https://p.qqan.com/up/2021-1/2021113104111220.jpg",
index: "S",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 7,
displayName: "霸王花",
avatar: "https://p.qqan.com/up/2021-1/20211411391666.jpg",
index: "B",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "你怎么还不睡呀?",
},
{
id: 8,
displayName: "曾平",
avatar: "https://p.qqan.com/up/2020-12/202012291044425822.jpg",
index: "Z",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 9,
displayName: "淡然",
avatar: "https://p.qqan.com/up/2020-12/202012141813343503.jpg",
index: "D",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 10,
displayName: "叶子。",
avatar: "https://p.qqan.com/up/2021-1/20211301122243621.jpg",
index: "Y",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 11,
displayName: "土豆",
avatar: "https://p.qqan.com/up/2020-12/202012111157268739.jpg",
index: "T",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 12,
displayName: "清沫",
avatar: "https://p.qqan.com/up/2020-12/202012415467996.jpg",
index: "Q",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
{
id: 13,
displayName: "Lemon-imui交流群",
avatar: "https://p.qqan.com/up/2020-11/20201127157109035.jpg",
index: "L",
isGroup: true,
unread: 0,
lastSendTime: 1566047865417,
lastContent: "这个咋处理啊?",
},
{
id: 14,
displayName: "系统通知",
avatar: "https://p.qqan.com/up/2020-6/2020061117234279854.jpg",
index: "[1]系統通知",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "宁静致远通过了你的好友请求",
renderContainer() {
return (
<div style="padding:15px;">
<div>宁静致远通过了你的好友请求</div>
<div>宁静致远通过了你的好友请求</div>
<div>宁静致远通过了你的好友请求</div>
</div>
);
},
},
{
id: 15,
displayName: "宁静致远。",
avatar: "https://p.qqan.com/up/2020-6/2020060308522797777.jpg",
index: "N",
unread: 0,
lastSendTime: 1566047865417,
lastContent: "",
},
];
+292
View File
@@ -0,0 +1,292 @@
export default [
{
label: "表情",
children: [
{
name: "1f600",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f600.png",
},
{
name: "1f62c",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f62c.png",
},
{
name: "1f601",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f601.png",
},
{
name: "1f602",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f602.png",
},
{
name: "1f923",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f923.png",
},
{
name: "1f973",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f973.png",
},
{
name: "1f603",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f603.png",
},
{
name: "1f604",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f604.png",
},
{
name: "1f605",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f605.png",
},
{
name: "1f606",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f606.png",
},
{
name: "1f607",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f607.png",
},
{
name: "1f609",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f609.png",
},
{
name: "1f60a",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60a.png",
},
{
name: "1f642",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f642.png",
},
{
name: "1f643",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f643.png",
},
{
name: "1263a",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/263a.png",
},
{
name: "1f60b",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60b.png",
},
{
name: "1f60c",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60c.png",
},
{
name: "1f60d",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60d.png",
},
{
name: "1f970",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f970.png",
},
{
name: "1f618",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f618.png",
},
{
name: "1f617",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f617.png",
},
{
name: "1f619",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f619.png",
},
{
name: "1f61a",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61a.png",
},
{
name: "1f61c",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61c.png",
},
{
name: "1f92a",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f92a.png",
},
{
name: "1f928",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f928.png",
},
{
name: "1f9d0",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f9d0.png",
},
{
name: "1f61d",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61d.png",
},
{
name: "1f61b",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61b.png",
},
{
name: "1f911",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f911.png",
},
{
name: "1f913",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f913.png",
},
{
name: "1f60e",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60e.png",
},
{
name: "1f929",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f929.png",
},
{
name: "1f921",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f921.png",
},
{
name: "1f920",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f920.png",
},
{
name: "1f917",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f917.png",
},
{
name: "1f60f",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f60f.png",
},
{
name: "1f636",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f636.png",
},
{
name: "1f610",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f610.png",
},
{
name: "1f611",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f611.png",
},
{
name: "1f612",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f612.png",
},
{
name: "1f644",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f644.png",
},
{
name: "1f914",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f914.png",
},
{
name: "1f925",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f925.png",
},
{
name: "1f92d",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f92d.png",
},
{
name: "1f92b",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f92b.png",
},
{
name: "1f92c",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f92c.png",
},
{
name: "1f92f",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f92f.png",
},
{
name: "1f633",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f633.png",
},
{
name: "1f61e",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61e.png",
},
{
name: "1f61f",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f61f.png",
},
{
name: "1f620",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f620.png",
},
{
name: "1f621",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f621.png",
},
],
},
{
label: "收藏",
children: [
{
name: "1f62c",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f62c.png",
},
{
name: "1f621",
title: "微笑",
src: "https://twemoji.maxcdn.com/2/72x72/1f621.png",
},
],
},
];
+156
View File
@@ -0,0 +1,156 @@
import ContactsData from "./contacts";
import UserData from "./user";
const generateRandId = () => {
return Math.random()
.toString(36)
.substr(-8);
};
const getContact = id => {
const data = ContactsData.find(contact => contact.id == id);
return { id: data.id, avatar: data.avatar, displayName: data.displayName };
};
export default {
1: [
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "问你件事",
toContactId: 1,
fromUser: UserData,
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "啥子。",
toContactId: 1,
fromUser: getContact(1),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "为什么",
toContactId: 1,
fromUser: UserData,
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "你穿了高跟鞋还这么矮",
toContactId: 1,
fromUser: UserData,
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "因为我矮啊。[!1f600][!1f600][!1f600]",
toContactId: 1,
fromUser: getContact(1),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "你开心吗",
toContactId: 1,
fromUser: getContact(1),
},
],
2: [],
3: [],
4: [],
5: [],
6: [],
7: [],
8: [],
9: [],
10: [],
11: [],
12: [],
13: [
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "我是测试时候看到的",
toContactId: 1,
fromUser: getContact(4),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "上新版本了,玩玩",
toContactId: 1,
fromUser: getContact(4),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "项目内没有搞这个",
toContactId: 1,
fromUser: getContact(4),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "@awesome 最新的,不然哪有这功能",
toContactId: 1,
fromUser: getContact(5),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "其实是跟你的遮罩层有冲突",
toContactId: 1,
fromUser: getContact(4),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "自己修改index哈",
toContactId: 1,
fromUser: UserData,
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "你们升级到最近版了吗?",
toContactId: 1,
fromUser: getContact(6),
},
{
id: generateRandId(),
status: "succeed",
type: "text",
sendTime: 1566047865417,
content: "wo 现在用的142",
toContactId: 1,
fromUser: getContact(7),
},
],
14: [],
15: [],
};
+5
View File
@@ -0,0 +1,5 @@
export default {
id: 1000,
avatar: "https://p.qqan.com/up/2018-4/15244505348390471.jpg",
displayName: "野火。",
};