Repository navigation
Conversation
…onent (draft) poc
This POC uses ui5-table rendering instead of a native one JIRA: BGSOFUIRILA-4203 related to #13666
|
🚀 Deployed on https://pr-13678--ui5-webcomponents-preview.netlify.app |
major refactoring and improvements, added tests
minor fixes, value state functionality implementation
add playground samples
fix table scrolling
fix showSuggestions property behavior
|
Announcing the selected row differs from OpenUI5 table suggestions. In the other application when going through the items, first the number of the row is announced with some other information. After the value column is announced, the rest of the columns and their values for the selected row are also announced. |
apply code review feedback
add the missing events and kbd handling
|
overall API looks good |
MapTo0
left a comment
There was a problem hiding this comment.
Thanks for the work on this — the component shape and the split into row/cell subcomponents read well. I ran a review pass and have 10 findings below, ordered roughly most-severe first. The three I'd like resolved before merge are:
_onfocusoutdoes not callsuper._onfocusout— base-class blur bookkeeping is silently skipped.:host([_isPhone])CSS selector never matches —_isPhoneis a getter, not a reflected@property, so the mobilemax-heightoverride is dead.- Enter with no matching row falls through to
super._onkeydownwithoutpreventDefault, so the form may submit via_request-submitwhile the popover was open.
The rest are correctness/style nits worth folding in while the component is still @experimental. Happy to discuss any of them.
apply code review feedback
apply code review feedback
remove redundant css rule
apply code review feedback
niyap
left a comment
There was a problem hiding this comment.
Please check the aria-describedby attribute in ui5-input as well as the specification. Also check availableSuggestionsCount() in ui5-input - when the dropdown is open there is an announcement that it is expanded as well as the count of the suggestions available where that is not the case with tabular suggestions.
| * @param {HTMLElement | null} row The highlighted or selected suggestion row. | ||
| * @public | ||
| */ | ||
| @event("selection-change", { bubbles: true }) |
There was a problem hiding this comment.
another case that is not working. If you type something and press enter to confirm the autocompleted value, popover is closed, change is fired, then if you delete a character, popover is open again without selection presented, but selection-change is not fired. Even if you press then Enter, it is not fired
There was a problem hiding this comment.
This is a controversial one, I will leave it as it is for now. In that case the selection is finalized and confirmed, change is fired, then when the popover is open there is no selection and it never was. I know that you mean the clearing of the previously selected item's value maybe should fire the event but I am not sure for that case, when popover is closed and value confirmed. No visible selection is changed in the suggestions on the second open and also the app in will still be able to have full control because of the 'change' event.
apply code review feedback
| class InputTableSuggestCell extends TableCell { | ||
| /** | ||
| * Defines the content of the cell. | ||
| * | ||
| * @public | ||
| */ | ||
| @slot({ type: Node, "default": true }) | ||
| declare content: DefaultSlot<Node>; | ||
|
|
||
| /** | ||
| * Determines the horizontal alignment of the cell content. | ||
| * | ||
| * @default undefined | ||
| * @public | ||
| */ | ||
| @property() | ||
| declare horizontalAlign?: `${TableCellHorizontalAlign}`; | ||
|
|
||
| /** @private */ | ||
| @property({ type: Boolean }) | ||
| declare merged: boolean; | ||
|
|
||
| onEnterDOM() { | ||
| super.onEnterDOM(); | ||
| this.toggleAttribute("ui5-table-cell", true); | ||
| } |
There was a problem hiding this comment.
those properties already available in the TableCell and you expose the base with @extends so why all that necessary? at least the implementation like onEnterDom could be left to the base class.
The same question applies for all other Table subclasses in this change
There was a problem hiding this comment.
Hello @aborjinik, thanks for the feedback.
I dropped the content and horizontalAlign re-declarations, removed now-unused slot, DefaultSlot, TableCellHorizontalAlign imports.
I kept the onEnterDOM overrides because UI5Element auto-adds only a tag-named attribute, so differently-tagged subclass must manually re-add (ui5-table-cell etc.)
apply code review feedback
apply code review feedback
niyap
left a comment
There was a problem hiding this comment.
- If you type "PR" in the first sample of InputTableSuggest, then delete the autocompleted value (selection over first item is cleared), on Tab the first matching item is autocompleted. That does not happen both with ui5-input and sap.m.Input with tabular suggestions
- When we have value state and suggestion and enough space to show the value state popover below the input but not enough to show the suggestions popover, when open the suggestion together with the value state header are shown above the input but the value state message popover remains open below the input just empty
| * | ||
| * @constructor | ||
| * @extends TableHeaderRow | ||
| * @since 2.28.0 |
There was a problem hiding this comment.
Please be aware before merging to check the currently developed version and change the @ since tag everywhere.
apply code review feedback
apply code review feedback



JIRA: BGSOFUIRILA-4203
Related to #13666
Overview
This branch introduces a significant refactoring of the
ui5-inputcomponent architecture by extracting a base class (InputField) and creating a newInputTableSuggestcomponent for tabular suggestions.Architecture Changes
Before:
ui5-input (All functionality mixed)
After:
InputField (Core input functionality) ← New private base class
├── ui5-input (List-based suggestions)
└── ui5-input-table-suggest (Table suggestions)
New Files
InputField.ts- Private base class with core input functionalityInputFieldTemplate.tsx- Base template with hook system for extensibilityInputField.css- Base styles extracted from Input.cssInputTableSuggest.ts- New component for tabular suggestionsInputTableSuggestTemplate.tsx- Template for tabular suggestions popoverInputTableSuggestPopoverTemplate.tsx- Popover template with Table componentInputField (Base Class)
Contains all non-suggestion-related functionality:
value,placeholder,disabled,readonly,required,type,valueState,maxlength,showClearIcon, accessibility propertiesicon,valueStateMessagechange,input,selectui5-input (Extends InputField)
Adds list-based suggestions:
showSuggestions,highlight,noTypeahead,filtersuggestionItems(SuggestionItem/SuggestionItemGroup)selection-change,type-ahead,suggestion-scroll,open,closeInputSuggestionsfeature for suggestion handlingui5-input-table-suggest (Extends InputField) - NEW
Adds tabular suggestions (like SAPUI5's sap.m.Input with tabular suggestions):
showSuggestions,noTypeahead,opensuggestionColumns(TableHeaderCell),suggestionRows(TableRow)selection-change,type-ahead,open,closeKey Design Decisions
ui5-inputuses List,InputTableSuggestuses TableInputField.stylesarrayMigration Impact
ui5-inputconsumersui5-input-table-suggestcomponent available for tabular suggestion use casesAdditional notes:
The internal ui5-table now renders the app's real slotted elements via native chained projection
instead of cloning them:
→ forwards the app's ui5-table-header-row into Table's headerRow slot.
→ forwards rows into Table's default rows slot.
Because elements stay in the app's light DOM, live cell mutations now reflect without a re-render — the
main bug the old remap couldn't handle.
API shift
Columns are now declared as one ui5-table-header-row (single-element slot) wrapping
ui5-table-header-cells, instead of loose header cells. JSDoc updated on both slots.
Removed
All built-in highlighting logic; apps now do app-side highlighting (demonstrated in the new RichCells
sample).
Table-side fixes for projection
TableCell._headerCell now resolves the owning table via row._table instead of parentElement (which is
InputTableSuggest under projection) — fixes popin labels / alignment.
TableRowBase._table result is cached (_tableRef), cleared on connect/disconnect.
New Table._rows / Table._headerRow getters
Table.ts gained _rows and _headerRow getters that call getSlottedNodes() to flatten chained
projection, returning the real ui5-table-row / ui5-table-header-row even when the table is nested inside
another component.
The entire Table subsystem was migrated from this.rows / this.headerRow to these internal getters:
TableNavigation, TableSelection, TableSelectionBase, TableSelectionMulti, TableSelectionSingle,
TableGrowing, TableVirtualizer, TableDragAndDrop, TableGroupRow, TableRow, TableCustomAnnouncement,
TableTemplate, and TableRowBase._hasPopin. Without this, every table feature would see the raw
placeholder instead of the projected rows — this is what actually makes projection work end to end.