21 lines
403 B
TypeScript
21 lines
403 B
TypeScript
2 years ago
|
import { t } from "../i18n";
|
||
2 years ago
|
import { HelpIcon } from "./icons";
|
||
5 years ago
|
|
||
2 years ago
|
type HelpButtonProps = {
|
||
5 years ago
|
name?: string;
|
||
|
id?: string;
|
||
|
onClick?(): void;
|
||
|
};
|
||
|
|
||
2 years ago
|
export const HelpButton = (props: HelpButtonProps) => (
|
||
4 years ago
|
<button
|
||
|
className="help-icon"
|
||
|
onClick={props.onClick}
|
||
|
type="button"
|
||
2 years ago
|
title={`${t("helpDialog.title")} — ?`}
|
||
|
aria-label={t("helpDialog.title")}
|
||
4 years ago
|
>
|
||
2 years ago
|
{HelpIcon}
|
||
4 years ago
|
</button>
|
||
5 years ago
|
);
|