gravity-ui / rfc

Gravity RFC is a process for proposing and implementing changes in our ecosystem
MIT License
3 stars 0 forks source link

Change behaviour of home/end in List #9

Closed burashka closed 1 month ago

burashka commented 3 months ago

Objective

What is the problem and why is it important?

Keys home/end select first and last item in list. However, users expect change position of cursor in input.

May be, it's difference between MacOS and another system, because ctrl-arrow change position.

Solution Proposal

What should be done and how?

Сhange behaviour of home/end in List for non-macos users:

May be, for all users?

Definition of done

What criteria should be met to consider the task complete?

List provides expected behaviour for home/end keys.

resure commented 3 months ago

@korvin89 @amje you might be interested

korvin89 commented 3 months ago

@resure We have already released new list component and don't have any plans for new features in old list.

resure commented 3 months ago

@resure We have already released new list component and don't have any plans for new features in old list.

Well, what matters is not only the fact that a new component was released, but also the speed of adoption of that new component. If new List will be integrated into services as slowly as new calendar (1 to 3 years) then probably old List should be upgraded too so users won't suffer in the meanwhile.

ogonkov commented 3 months ago

If focus inside list items Home/End should focus first/last item in list

burashka commented 3 months ago

@resure We have already released new list component and don't have any plans for new features in old list.

I see unstable branch in storybook. Can I use it now? When will new list component become stable and publish?

korvin89 commented 3 months ago

@burashka

home/end will change position of cursor in input

Yep, it is completely true according to w3c Combobox Pattern

ctrl-home/ctrl-end will select first and last item in list

There is no such keys behaviour pattern in w3c or or wherever, so our users will not be able to find out about such functionality in any way. I think we should not use patterns that are not standard.

Here my suggestion about your issue https://github.com/gravity-ui/uikit/pull/1491.

korvin89 commented 3 months ago

@burashka

I see unstable branch in storybook. Can I use it now? When will new list component become stable and publish?

Yep, you can already use it, but component could have breaking changes in minors cause of in unstable status.

amje commented 2 months ago

@burashka @korvin89 I can see that feature is shipped to the current List, can we close this issue?