ant-design/site/theme/template/Content/EditButton.jsx
2016-08-17 18:33:19 +08:00

15 lines
372 B
JavaScript

import React from 'react';
import { Tooltip, Icon } from 'antd';
const branchUrl = 'https://github.com/ant-design/ant-design/blob/1.x-stable/';
export default function EditButton({ title, filename }) {
return (
<Tooltip title={title}>
<a className="edit-button" href={`${branchUrl}${filename}`}>
<Icon type="edit" />
</a>
</Tooltip>
);
}