this.carousel

This commit is contained in:
Martin Quarda 2024-05-08 13:39:59 +02:00
parent d5620ae8b2
commit 90d5108544

View File

@ -49,7 +49,7 @@ class Main extends Component {
new_index += this.state.photos.length new_index += this.state.photos.length
} }
this.setState({currentImage: new_index}) this.setState({currentImage: new_index})
this.carousel && this.carousel.setState({currentIndex: 1}) this.carousel && this. carousel.setState({currentIndex: 1})
} }
onSubmit(event){ onSubmit(event){
event.preventDefault(); event.preventDefault();
@ -102,7 +102,7 @@ class Main extends Component {
<ModalGateway> <ModalGateway>
{this.state.photoIsOpen && {this.state.photoIsOpen &&
<Modal onClose={this.togglePhoto}> <Modal onClose={this.togglePhoto}>
{carousel} {this.carousel}
</Modal> </Modal>
} }
</ModalGateway> </ModalGateway>