Facing flexbox column alignment issue. Don't know how to fix it by myself. so gone through below SO threads, but unfortunately nothing works for me.
Currently using Angular 11x version for development. I've created REUSEABLE table component using Angular material, which is working fine. Here the problem is, am showing action icons based on conditions. some time there is a scenario to show only ONE or TWO icons at a time, where am seeing some unwanted HUGE gaps between two icons like below.
Want to resolve this gap issue for below scenarios
- if single icon - it should be aligned with Action header in Center
- if two icons - it should be aligned with Action header with decent gap.
Could someone tell me what am doing wrong here? or it would be much appreciated if someone help me to find out proper and better solution .
my css
.align-user-action {
display: flex;
flex-wrap: nowrap;
flex-direction: row;
justify-content: space-between;
cursor: pointer;
}
expectation
item 1 item 2
item 1 item 2 item 3 item 4
item 1 item 2
Thanks to everyone