Skip to content

Commit

Permalink
[feat] better carousel handling, and also fixed the fullscreen packag…
Browse files Browse the repository at this point in the history
…e (currently manual patch, waiting for metafizzy/flickity-fullscreen#33)
  • Loading branch information
nkalupahana committed Jan 4, 2022
1 parent f2ec9bb commit 9b3ef82
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/ImageCarousel.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const ImageCarousel = ({ files }) => {

return (
<>
{ accessURLs && <Flickity className="carousel-mods" reloadOnUpdate={true} options={{"wrapAround": true, "adaptiveHeight": true, "fullscreen": true}}>
{ accessURLs && <Flickity className="carousel-mods" reloadOnUpdate={false} options={{"wrapAround": true, "adaptiveHeight": true, "fullscreen": true}}>
{ accessURLs.map(url => <div key={url} style={{"display": "flex", "alignItems": "center", "justifyContent": "center"}}><img alt="User-attached for mood log" src={url} /></div>)}
</Flickity> }
</>
Expand Down
1 change: 1 addition & 0 deletions src/components/MoodLogCard.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
grid-column-start: 1;
grid-column-end: 3;
margin-bottom: 30px;
min-height: 100px;
}

.carousel-mods.is-fullscreen > div > div > div {
Expand Down

0 comments on commit 9b3ef82

Please sign in to comment.