Skip to content

Conversation

@fw-bot
Copy link
Collaborator

@fw-bot fw-bot commented Nov 28, 2025

Description:

Pressing Tab in the font size editor moves focus to the hidden “add more rows” footer (the next focusable element in the DOM). This caused the browser to auto-scroll to the footer while the grid viewport state remained unchanged, making the footer appear to float over the grid.

Now, when the font size editor loses focus (via blur/Tab), it closes its dropdown and redirects focus back to the grid instead of the footer.

Task: 5263792

review checklist

  • feature is organized in plugin, or UI components
  • support of duplicate sheet (deep copy)
  • in model/core: ranges are Range object, and can be adapted (adaptRanges)
  • in model/UI: ranges are strings (to show the user)
  • undo-able commands (uses this.history.update)
  • multiuser-able commands (has inverse commands and transformations where needed)
  • new/updated/removed commands are documented
  • exportable in excel
  • translations (_t("qmsdf %s", abc))
  • unit tested
  • clean commented code
  • track breaking changes
  • doc is rebuild (npm run doc)
  • status is correct in Odoo

Forward-Port-Of: #7495

@robodoo
Copy link
Collaborator

robodoo commented Nov 28, 2025

Pull request status dashboard

@fw-bot
Copy link
Collaborator Author

fw-bot commented Nov 28, 2025

@dhrp-odoo @LucasLefevre cherrypicking of pull request #7495 failed.

stdout:

Auto-merging src/components/font_size_editor/font_size_editor.ts
CONFLICT (content): Merge conflict in src/components/font_size_editor/font_size_editor.ts
Auto-merging src/components/font_size_editor/font_size_editor.xml
CONFLICT (content): Merge conflict in src/components/font_size_editor/font_size_editor.xml
Auto-merging tests/grid/__snapshots__/grid_component.test.ts.snap
Auto-merging tests/spreadsheet/__snapshots__/spreadsheet_component.test.ts.snap
Auto-merging tests/top_bar_component.test.ts

Either perform the forward-port manually (and push to this branch, proceeding as usual) or close this PR (maybe?).

In the former case, you may want to edit this PR message as well.

⚠️ after resolving this conflict, you will need to merge it via @robodoo.

More info at https://github.com/odoo/odoo/wiki/Mergebot#forward-port

Pressing Tab in the font size editor could move focus to the hidden
“add more rows” footer. The browser then auto-scrolled to that footer
while the grid viewport state stayed unchanged, making the footer look
like it was floating above the grid.

We now handle Tab on the font size input: we prevent the default
navigation, close the dropdown, and redirect focus back to the grid
composer instead of the footer. This keeps the layout stable when
tabbing from the toolbar.

Alternative approaches considered but discarded:

- Closing on blur and refocusing the grid: clicking the arrow caused
  the input to blur first, so the blur handler closed the dropdown and
  the arrow click immediately reopened it, making it impossible to
  close the dropdown.
- Using mousedown to distinguish internal clicks: this fired before
  selecting an item in the dropdown, so the dropdown closed too early
  and the item click was never applied.

Task: 5263792
X-original-commit: 99a94ac
@dhrp-odoo dhrp-odoo force-pushed the master-17.0-tab-navigation-breaks-layout-dhrp-478643-fw branch from 86b983f to b7f77af Compare November 28, 2025 09:55
@dhrp-odoo
Copy link
Contributor

robodoo r+

robodoo pushed a commit that referenced this pull request Dec 1, 2025
Pressing Tab in the font size editor could move focus to the hidden
“add more rows” footer. The browser then auto-scrolled to that footer
while the grid viewport state stayed unchanged, making the footer look
like it was floating above the grid.

We now handle Tab on the font size input: we prevent the default
navigation, close the dropdown, and redirect focus back to the grid
composer instead of the footer. This keeps the layout stable when
tabbing from the toolbar.

Alternative approaches considered but discarded:

- Closing on blur and refocusing the grid: clicking the arrow caused
  the input to blur first, so the blur handler closed the dropdown and
  the arrow click immediately reopened it, making it impossible to
  close the dropdown.
- Using mousedown to distinguish internal clicks: this fired before
  selecting an item in the dropdown, so the dropdown closed too early
  and the item click was never applied.

closes #7558

Task: 5263792
X-original-commit: 99a94ac
Signed-off-by: Lucas Lefèvre (lul) <[email protected]>
Signed-off-by: Dhrutik Patel (dhrp) <[email protected]>
@robodoo robodoo added the 19.1 label Dec 1, 2025
@robodoo robodoo closed this Dec 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants