fkhadra / fkhadra/react-toastify
feature/bug: Enable variable/dynamic width stacked notifications
- Dominant language
- TypeScript
- Stars
- 13.4k
- Forks
- 741
- PR merge metrics
- No merged PRs in 30d
Description
Setting the following css enables variable/dynamic width notifications when stacked={false}
```
'.Toastify__toast': {
padding: 0,
width: 'fit-content',
},
'.Toastify__toast-body': {
padding: 0,
margin: 0,
width: '100%',
},
```
When I set stacked={true} this no longer works and the notifications are all set to a fixed small width causing all the notifications to run off the screen. Maybe it makes sensed for stacked notifications to all be the same width (visually), but would be interested in seeing if there are ideas for how it could be accomplished with variable/dynamic width.
Contributor guide
Research direction
Reproduce the reported CSS behavior with stacked={false} and stacked={true}, then inspect the stacked notification styling and width constraints. Done means stacked notifications can use variable or dynamic widths without being forced to a small fixed width or running off the screen.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100