-
Notifications
You must be signed in to change notification settings - Fork 55
[WIP] EnvFrom Styling #216
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
Conversation
Styling updates for EnvFrom component
@@ -18,7 +18,8 @@ | |||
> span { | |||
background-color: @dropdown-link-active-bg !important; | |||
border-color: @dropdown-link-active-border-color !important; | |||
color: @dropdown-link-active-color; | |||
color: @dropdown-link-active-color !important; | |||
cursor: default !important; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't be want this to be pointer
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this is the funky part. This scenario plays out as that item being disabled... we could do a few things...
- leave it as the disabled cursor,
- change it to the pointer to make it similar to the select lists in general,
- or leave it as something neutral with default...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This screenshot shows the conundrum and the reason why, to me, it made more sense to assign it the default
cursor.
By default ui-select makes the first selection .active. So if the first option has already been selected in another select, then having the cursor be pointer
would imply it’s still clickable when it’s not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But it should be clickable. The bug to me is that the current value is marked invalid. It is a valid selection.
Note that in other selects we use a pointer cursor for the active item.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In other words, I don't think this is a style bug. The bug is we're making an item disabled when it's not.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We agree it's not entirely a style bug when an item can be disabled and active at the same time... but at the same time UI Select maybe should have already taken that into account with its styling... or lack of.
Of the opinion that having both classes applied really shouldn't be able to happen without some form of CSS support if UI Select is just going to default to selecting the first item automatically.
Working on a couple of alternates:
- we just ignore disabling all together (maybe remove duplicates on save)
- @sg00dwin mentioned an alternative that has its own issues (possibly around drag and sort on the Environment From component) where we could simply remove/hide the items already selected... it avoids the issue entirely.
- we try to autoselect the first non-disabled item
Closing this PR since it's related to a bypass as opposed to a real fix. May re-open as updates for Environment From become necessary. Related to the disabled styling... |
Styling updates for EnvFrom component.