1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-05 08:53:14 +00:00
This commit is contained in:
LeoSirius
2019-04-19 22:32:19 +08:00
parent 5a5c98dbbf
commit 993885fc39
3 changed files with 97 additions and 74 deletions

View File

@@ -20,6 +20,7 @@ const { isStarred, isLocked, lockedByMe,
repoID, filePath, enableWatermark, userNickName
} = window.app.pageOptions;
class FileView extends React.Component {
constructor(props) {
@@ -28,7 +29,7 @@ class FileView extends React.Component {
isStarred: isStarred,
isLocked: isLocked,
lockedByMe: lockedByMe,
isCommentPanelOpen: false
isCommentPanelOpen: false,
};
}
@@ -75,7 +76,7 @@ class FileView extends React.Component {
render() {
return (
<div className="h-100 d-flex flex-column">
<div className="file-view-header d-flex justify-content-between align-items-center">
<div className="file-view-header d-flex justify-content-between">
<FileInfo
isStarred={this.state.isStarred}
isLocked={this.state.isLocked}
@@ -84,6 +85,9 @@ class FileView extends React.Component {
<FileToolbar
isLocked={this.state.isLocked}
lockedByMe={this.state.lockedByMe}
onSaveChangedContent={this.props.onSaveChangedContent}
isSaving={this.props.isSaving}
isContentChangedButNotSaved={this.props.isContentChangedButNotSaved}
toggleLockFile={this.toggleLockFile}
toggleCommentPanel={this.toggleCommentPanel}
/>