Skip to content

Commit

Permalink
Web: Files: Fixed styles for version history panel.
Browse files Browse the repository at this point in the history
  • Loading branch information
TatianaLopaeva committed Nov 3, 2021
1 parent 76b4251 commit e2c435d
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ const StyledVersionRow = styled(Row)`
.row_content {
position: relative;
padding-top: 14px;
${(props) => !props.isTabletView && "padding-right:16px"}
}
.version_badge {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ const VersionRow = (props) => {
updateCommentVersion,
onSetRestoreProcess,
isRestoreProcess,
isTabletView,
} = props;
const [showEditPanel, setShowEditPanel] = useState(false);
const [commentValue, setCommentValue] = useState(info.comment);
Expand Down Expand Up @@ -67,7 +68,6 @@ const VersionRow = (props) => {
const onOpenFile = () => window.open(info.webUrl);

const onRestoreClick = () => {

onSetRestoreProcess(true);
restoreVersion(info.id, info.version)
.catch((err) => toastr.error(err))
Expand Down Expand Up @@ -104,6 +104,7 @@ const VersionRow = (props) => {
canEdit={canEdit}
isRestoreProcess={isRestoreProcess}
isVersion={isVersion}
isTabletView={isTabletView}
>
<>
<Box displayProp="flex">
Expand Down Expand Up @@ -249,7 +250,7 @@ const VersionRow = (props) => {

export default inject(({ auth, versionHistoryStore }) => {
const { user } = auth.userStore;
const { culture } = auth.settingsStore;
const { culture, isTabletView } = auth.settingsStore;
const language = (user && user.cultureName) || culture || "en-US";

const {
Expand All @@ -260,7 +261,7 @@ export default inject(({ auth, versionHistoryStore }) => {

return {
culture: language,

isTabletView,
markAsVersion,
restoreVersion,
updateCommentVersion,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,9 @@ class SectionBodyContent extends React.Component {
</RowContainer>
</div>
) : (
<Loaders.HistoryRows title="version-history-body-loader" />
<div className="loader-history-rows" style={{ paddingRight: "16px" }}>
<Loaders.HistoryRows title="version-history-body-loader" />
</div>
);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ class PureVersionHistory extends React.Component {
secondaryProgressBarIcon="file"
showSecondaryButtonAlert={false}
withBodyScroll={false}
isLoadingContent={isLoading}
>
<PageLayout.ArticleHeader>
<ArticleHeaderContent />
Expand Down

0 comments on commit e2c435d

Please sign in to comment.