Skip to content
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

feat(ItemNavigation): introduce navigationMode property #910

Merged
merged 5 commits into from
Nov 27, 2019

Conversation

MapTo0
Copy link
Member

@MapTo0 MapTo0 commented Nov 6, 2019

(1) The ItemNavigation now has three navigation modes:

  • "Vertical" - "Up|Down" navigation
  • "Horizontal"- "Left|Right" navigation
  • "Auto" - both "Vertical" and "Horizontal" navigation

(2) From now you can navigate throw the List items and Table rows only vertically
via the "Up" and "Down" arrow keys.

FIXES: #862

- prevents focusing next/prev item when pressing right/left arrow

FIXES: #862
@MapTo0 MapTo0 requested a review from pskelin November 6, 2019 08:18
@MapTo0
Copy link
Member Author

MapTo0 commented Nov 6, 2019

Why a property - we need both cases in order to cover all requirements.
The list itself does not need it.

ActionSheet - horizontal navigation works fine - https://openui5nightly.hana.ondemand.com/#/entity/sap.m.ActionSheet/sample/sap.m.sample.ActionSheet

ilhan007
ilhan007 previously approved these changes Nov 11, 2019
Copy link
Contributor

@pskelin pskelin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's discuss the name first.

  • if it is about vertical navigation, there will be a second property
  • two properties about controlling the same behaviour seems strage
  • there are four possible values, why not an enum?
  • one of the four values doesn't make sense - both horizontal and vertical prevented

an enum might be more meaningful (both the name and the values):
navigationMode = { Horizontal, Vertical, Auto|Both|2D }

@ilhan007 ilhan007 changed the title feat(ItemNavigation): introduce preventHorizontalNavigation property feat(ItemNavigation): introduce navigationMode property Nov 27, 2019
@ilhan007 ilhan007 merged commit 9c43533 into master Nov 27, 2019
@ilhan007 ilhan007 deleted the list-remove-horizontal-kbh branch November 27, 2019 14:15
ilhan007 pushed a commit that referenced this pull request Dec 3, 2019
(1) The ItemNavigation now has three navigation modes: 
- "Vertical" - "Up|Down" navigation
- "Horizontal"- "Left|Right" navigation
- "Auto" - both "Vertical" and "Horizontal" navigation

(2) From now you can navigate throw the List items and Table rows only vertically
via the "Up" and "Down" arrow keys.

FIXES: #862
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ui5-list keyboard navigation should be vertical only
4 participants