Skip to content

Commit

Permalink
Pull GalleryView styles up
Browse files Browse the repository at this point in the history
  • Loading branch information
cbeer committed Dec 8, 2023
1 parent 6575cab commit 0b543a3
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions src/components/GalleryView.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
import { Component } from 'react';
import PropTypes from 'prop-types';
import { styled } from '@mui/material/styles';
import Paper from '@mui/material/Paper';
import GalleryViewThumbnail from '../containers/GalleryViewThumbnail';

const Root = styled(Paper, { name: 'GalleryView', slot: 'root' })(({ theme }) => ({
alignItems: 'flex-start',
display: 'flex',
flexDirection: 'row',
flexWrap: 'wrap',
overflowX: 'hidden',
overflowY: 'scroll',
padding: '50px 0 50px 20px',
width: '100%',
}));

/**
* Renders a GalleryView overview of the manifest.
*/
Expand All @@ -16,22 +28,12 @@ export class GalleryView extends Component {
} = this.props;
const htmlDir = viewingDirection === 'right-to-left' ? 'rtl' : 'ltr';
return (
<Paper
<Root
component="section"
aria-label="gallery section"
dir={htmlDir}
square
elevation={0}
sx={{
alignItems: 'flex-start',
display: 'flex',
flexDirection: 'row',
flexWrap: 'wrap',
overflowX: 'hidden',
overflowY: 'scroll',
padding: '50px 0 50px 20px',
width: '100%',
}}
id={`${windowId}-gallery`}
>
{
Expand All @@ -43,7 +45,7 @@ export class GalleryView extends Component {
/>
))
}
</Paper>
</Root>
);
}
}
Expand Down

0 comments on commit 0b543a3

Please sign in to comment.