@kotori-bot/core
Version:
Kotori Core
58 lines (57 loc) • 1.81 kB
TypeScript
declare global {
namespace JSX {
type Node = string | number | boolean | null | Element | Node[];
type Element = import('../components/messages').MessageList<keyof import('../types/message').MessageMapping> | import('../components/messages').MessageSingle<keyof import('../types/message').MessageMapping>;
interface ElementAttributesProperty {
props: any;
}
interface ElementChildrenAttribute {
children: unknown;
}
interface IntrinsicElements {
text: {
children: string;
};
br: never;
image: {
src: string;
};
reply: {
messageId: string;
};
mention: {
userId: string;
};
mentionAll: never;
video: {
src: string;
};
audio: {
src: string;
};
voice: {
src: string;
};
file: {
src: string;
};
location: {
latitude: number;
longitude: number;
title: string;
content: string;
};
seg: {
children: Node;
};
format: {
template: string;
children: Element[] | Element;
};
}
}
}
declare const Fragment: unique symbol;
export declare function hTs(type: string | typeof Fragment | ((props: Record<string, unknown>) => JSX.Element), props: Record<string, unknown>, ...children: any[]): JSX.Element;
export declare function hRes(type: string, props: Record<string, unknown>): JSX.Element;
export {};