metafizzy / metafizzy/flickity
Strange behaviour cellAlign. Sometime works correctly, other times no.
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 7.6k
- Forks
- 593
- PR merge metrics
- No merged PRs in 30d
Description



Hi, I am new to this library and I think this is awesome.
I don't know if I miss something but I found a strange behaviour using cellAlign: left (default).
Sometimes the cell is not completely aligned on left like in img1 and img2.
If I open the Inspector, then it works correctly, even if I close it.
But if I refresh the page, it returns to render incorrectly.
I tried on different PC, browsers, even on my friend's PC.
Is this normal?
Code:
```
Document
* {
box-sizing: border-box;
}
.main-carousel {
border: 1px solid red;
}
.carousel-cell {
border: 1px solid green;
height: 250px;
width: 250px;
}
```
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the supplied HTML reproduction using Flickity 2, especially the data-flickity options for cellAlign and contain. Compare the initial layout after refresh with the layout after opening and closing the browser Inspector. Done means identifying and fixing the condition that causes the cells to render inconsistently so left alignment is stable on initial load.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 38/100