matrix-react-sdk
Version:
SDK for matrix.org using React
26 lines (25 loc) • 827 B
TypeScript
import React, { ReactNode } from "react";
import { Room } from "matrix-js-sdk/src/matrix";
import { TranslationKey } from "../../../../languageHandler";
import { XOR } from "../../../../@types/common";
import { Tool } from "../DevtoolsDialog";
export interface IDevtoolsProps {
onBack(): void;
setTool(label: TranslationKey, tool: Tool): void;
}
interface IMinProps extends Pick<IDevtoolsProps, "onBack"> {
className?: string;
children?: ReactNode;
extraButton?: ReactNode;
}
interface IProps extends IMinProps {
actionLabel: TranslationKey;
onAction(): Promise<string | void>;
}
declare const BaseTool: React.FC<XOR<IMinProps, IProps>>;
export default BaseTool;
interface IContext {
room: Room;
threadRootId?: string | null;
}
export declare const DevtoolsContext: React.Context<IContext>;