mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-13 05:39:59 +00:00
Markdown previewer location (#3833)
* Change the position in the markdown preview page * modify func name * optimization code
This commit is contained in:
@@ -85,6 +85,11 @@ class ViewFileToolbar extends React.Component {
|
||||
});
|
||||
}
|
||||
|
||||
onHistoryClick = () => {
|
||||
let historyUrl = siteRoot + 'repo/file_revisions/' + this.props.repoID + '/?p=' + Utils.encodePath(this.props.path);
|
||||
location.href = historyUrl;
|
||||
}
|
||||
|
||||
render() {
|
||||
let { filePermission } = this.props;
|
||||
let name = Utils.getFileName(this.props.path);
|
||||
@@ -114,6 +119,7 @@ class ViewFileToolbar extends React.Component {
|
||||
}
|
||||
<DropdownItem onClick={this.onEditFileTagToggle}>{gettext('Tags')}</DropdownItem>
|
||||
<DropdownItem onClick={this.onListRelatedFileToggle}>{gettext('Related Files')}</DropdownItem>
|
||||
<DropdownItem onClick={this.onHistoryClick}>{gettext('History')}</DropdownItem>
|
||||
</DropdownMenu>
|
||||
</Dropdown>
|
||||
)}
|
||||
|
Reference in New Issue
Block a user