Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display previous and next text at the same time #56

Open
sswoodruff89 opened this issue Aug 15, 2020 · 2 comments
Open

Display previous and next text at the same time #56

sswoodruff89 opened this issue Aug 15, 2020 · 2 comments

Comments

@sswoodruff89
Copy link

Hey guys, is there a way to display more than one text item, like displaying the previous items and the next items in the loop at the same time?
For example, I have a list of text items and I want to show five at any given time. The middle one would be the current one, the top two would be the previous two and fading out at different stages, and the bottom two would the be the next in the list and fading in at different stages.

@braposo
Copy link
Owner

braposo commented Aug 25, 2020

Hi @sswoodruff89! Not sure what you're trying to achieve from your description, do you have a more visual example you can give? General you can group components together so they are displayed at the same time by just wrapping them in another components. react-text-loop will only consider the top-level child components when looping so anything inside them will be part of the same transition.

We don't support customising the number of elements that are displayed, but maybe using that grouping would be enough?

@iksent
Copy link

iksent commented Feb 25, 2022

@braposo, I think this is https://codepen.io/poopsplat/pen/VLdNZq the example, of what @sswoodruff89 trying to achieve. I am also trying to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants