diff --git a/src/components/GalleryView.js b/src/components/GalleryView.js index b83e30652443c4b7c358aded49c69bff10fea150..5288795cdd435481e44fefd5ff0d4a30228f9057 100644 --- a/src/components/GalleryView.js +++ b/src/components/GalleryView.js @@ -32,7 +32,7 @@ export class GalleryView extends Component { className={ classNames( classes.galleryViewItem, - canvas.index === window.canvasIndex ? classes.currentCanvas : '', + canvas.index === window.canvasIndex ? classes.galleryViewItemCurrent : '', ) } onClick={() => setCanvas(window.id, canvas.index)} @@ -44,7 +44,6 @@ export class GalleryView extends Component { imageUrl={manifestoCanvas.thumbnail(null, 100)} isValid={manifestoCanvas.hasValidDimensions} maxHeight={120} - maxWidth={100} aspectRatio={manifestoCanvas.aspectRatio} style={{ margin: '0 auto' }} /> diff --git a/src/containers/GalleryView.js b/src/containers/GalleryView.js index 691909246b4eb6ec6f736edb25c4e84ccfc80bde..8e0aacd1176c3a9f85e558a3143ed9fc6ea70a89 100644 --- a/src/containers/GalleryView.js +++ b/src/containers/GalleryView.js @@ -21,15 +21,14 @@ const mapStateToProps = (state, { window }) => ( * Styles to be passed to the withStyles HOC */ const styles = theme => ({ - currentCanvas: { - border: `2px solid ${theme.palette.secondary.main}`, - padding: theme.spacing.unit / 2, - }, galleryContainer: { - flex: '1', + alignItems: 'flex-start', + flexDirection: 'row', + flexWrap: 'wrap', overflowX: 'hidden', overflowY: 'scroll', padding: '50px 0 50px 20px', + width: '100%', }, galleryViewItem: { '&:focus': { @@ -37,20 +36,19 @@ const styles = theme => ({ }, '&:hover': { border: `2px solid ${theme.palette.secondary.main}`, - padding: theme.spacing.unit / 2, - transform: 'scale(1.05)', - transition: '.1s transform ease-out', }, - boxSizing: 'border-box', + border: '2px solid transparent', cursor: 'pointer', display: 'inline-block', - height: '160px', + height: '165px', margin: `${theme.spacing.unit}px ${theme.spacing.unit / 2}px`, - maxWidth: '100px', + minWidth: '60px', overflow: 'hidden', padding: theme.spacing.unit / 2, - textOverflow: 'elipsis', - transition: '.1s transform ease-out', + width: 'min-content', + }, + galleryViewItemCurrent: { + border: `2px solid ${theme.palette.secondary.main}`, }, });