excalidraw/src/components/HelpIcon.tsx
Arun 40656c70d1
fix: Make help toggle tabbable (#3310)
* fix: Make help toggle tabbable

* Update src/components/HelpIcon.tsx

Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>

Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>
2021-03-23 16:48:10 +05:30

22 lines
417 B
TypeScript

import React from "react";
import { questionCircle } from "../components/icons";
type HelpIconProps = {
title?: string;
name?: string;
id?: string;
onClick?(): void;
};
export const HelpIcon = (props: HelpIconProps) => (
<button
className="help-icon"
onClick={props.onClick}
type="button"
title={`${props.title} — ?`}
aria-label={props.title}
>
{questionCircle}
</button>
);