Skip to content

Commit

Permalink
#1341 "pin" edit tag row outside of tag list (#410)
Browse files Browse the repository at this point in the history
Co-authored-by: matej <[email protected]>
  • Loading branch information
boriskovar-m2ms and matej-vavrek authored Feb 27, 2024
1 parent 3dd536b commit 6cb3607
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions js/components/preview/tags/details/tagDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ const useStyles = makeStyles(theme => ({
display: 'flex',
flexDirection: 'column',
overflow: 'auto',
height: '100%',
width: '100%',
marginTop: -theme.spacing(),
justifyContent: 'space-between',
Expand Down Expand Up @@ -199,8 +198,8 @@ const TagDetails = memo(() => {
const moleculesToEditIds = useSelector(state => state.selectionReducers.moleculesToEdit);
const moleculesToEdit =
moleculesToEditIds &&
moleculesToEditIds.length > 0 &&
!(moleculesToEditIds.length === 1 && moleculesToEditIds[0] === null)
moleculesToEditIds.length > 0 &&
!(moleculesToEditIds.length === 1 && moleculesToEditIds[0] === null)
? moleculesToEditIds.map(id => dispatch(getMoleculeForId(id)))
: [];

Expand Down Expand Up @@ -442,7 +441,7 @@ const TagDetails = memo(() => {
</Grid>
</Grid>
</div>
<div ref={elementRef} className={classes.containerExpanded}>
<div ref={elementRef} className={classes.containerExpanded} style={{ height: tagDetailView ? "80%" : "87%" }}>
{tagDetailView ? (
<>
<div className={classes.container} id="tagName">
Expand Down Expand Up @@ -604,9 +603,9 @@ const TagDetails = memo(() => {
)}
</div>
)}
<div style={{ paddingBottom: resizableLayout === true ? '17px' : '0px' }}>
<NewTagDetailRow moleculesToEditIds={moleculesToEditIds} moleculesToEdit={moleculesToEdit} />
</div>
</div>
<div style={{ paddingBottom: resizableLayout === true ? '17px' : '0px' }}>
<NewTagDetailRow moleculesToEditIds={moleculesToEditIds} moleculesToEdit={moleculesToEdit} />
</div>
</Panel>
);
Expand Down

0 comments on commit 6cb3607

Please sign in to comment.