fix: typo

This commit is contained in:
手瓜一十雪
2024-11-22 22:04:57 +08:00
parent 53d440fddc
commit 2009492b2f
4 changed files with 20 additions and 7 deletions

View File

@@ -15,6 +15,7 @@ import {
} from "@/core/packet/transformer/proto";
import {
BaseEmojiType,
FaceType,
NTMsgAtType,
PicType,
SendArkElement,
@@ -163,7 +164,7 @@ export class PacketMsgFaceElement extends IPacketMsgElement<SendFaceElement> {
constructor(element: SendFaceElement) {
super(element);
this.faceId = element.faceElement.faceIndex;
this.isLargeFace = element.faceElement.faceType === BaseEmojiType.CHAIN_SUPER_EMOJI;
this.isLargeFace = element.faceElement.faceType === FaceType.AniSticke;
}
buildElement(): NapProtoEncodeStructType<typeof Elem>[] {

View File

@@ -1,5 +1,4 @@
import { BaseEmojiType } from "./emoji";
import { ElementType, MessageElement, NTGrayTipElementSubTypeV2, PicSubType, PicType, TipAioOpGrayTipElement, TipGroupElement, NTVideoType } from "./msg";
import { ElementType, MessageElement, NTGrayTipElementSubTypeV2, PicSubType, PicType, TipAioOpGrayTipElement, TipGroupElement, NTVideoType, FaceType } from "./msg";
type ElementFullBase = Omit<MessageElement, 'elementType' | 'elementId' | 'extBufForUI'>;
@@ -31,7 +30,7 @@ export interface TextElement {
export interface FaceElement {
faceIndex: number;
faceType: BaseEmojiType;
faceType: FaceType;
faceText?: string;
packId?: string;
stickerId?: string;
@@ -254,7 +253,7 @@ export interface FaceBubbleElement {
faceFlag: number;
content: string;
oldVersionStr: string;
faceType: BaseEmojiType;
faceType: FaceType;
others: string;
yellowFaceInfo: {
index: number;

View File

@@ -526,4 +526,16 @@ export interface MsgReqType {
includeSelf: boolean,
includeDeleteMsg: boolean,
extraCnt: number
}
/**
* 表情类型枚举
*/
export enum FaceType {
Unknown = 0,
OldFace = 1, // 老表情
Normal = 2, // 常规表情
AniSticke = 3, // 动画贴纸
Lottie = 4,// 新格式表情
Poke = 5 // 可变Poke
}