Skip to content

Conversation

@rmbh-odoo
Copy link
Contributor

@rmbh-odoo rmbh-odoo commented Nov 5, 2025

Description:

Current behavior before PR:

  • The canvas size was computed from the grid, which caused visible white margins
    after a snappy resize (commit 3c8df4b9).
  • Some unused props were being passed, creating unnecessary code clutter.

Desired behavior after PR is merged:

  • The dashboard canvas size is now computed from the gridRef, ensuring only the
    visible parts are displayed and avoiding redundant canvas computations.

Task: 5223156

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

@robodoo
Copy link
Collaborator

robodoo commented Nov 5, 2025

Pull request status dashboard

@rrahir
Copy link
Collaborator

rrahir commented Nov 10, 2025

if I understand the issue correctly, we miss the actual computation of the spreadsheet width when in dashboard mode. have you looked into a way to correct that as well? because right now we have a discrepency between the canvas size and the actual part displayed to the client and I'm not sure that just hiding it is the best solution (maybe it's too complicated to fix and it's the right call, but i'm curious to know if looked into it)

@rmbh-odoo rmbh-odoo force-pushed the saas-18.4-fix-dashboard-gray-background-rmbh branch from 327e1bc to 4650b73 Compare November 11, 2025 13:38
@rmbh-odoo rmbh-odoo changed the title [FIX] dashboard: hide overflow area after snappy resize [FIX] dashboard: properly handle grid resize in dashboard mode Nov 11, 2025
@rmbh-odoo rmbh-odoo force-pushed the saas-18.4-fix-dashboard-gray-background-rmbh branch 2 times, most recently from 361261b to d525807 Compare November 15, 2025 05:03

onGridResized({ height, width }: DOMDimension) {
onGridResized() {
const { height, width } = this.props.getGridSize();
Copy link
Collaborator

Choose a reason for hiding this comment

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

I guess we could go a bit further and make a helper because those lines are a repetition of the computation in get gridContainer() ;-)

Before this commit:
- The canvas size was computed from the grid, which caused visible white margins
  after a snappy resize (commit 3c8df4b).
- Some unused props were being passed, creating unnecessary code clutter.

After this commit:
- The dashboard canvas size is now computed as the min of the grid bounds and
  the end of getColDimension.
- Shows only visible parts and avoids extra canvas processing.

Task: 5223156
@rmbh-odoo rmbh-odoo force-pushed the saas-18.4-fix-dashboard-gray-background-rmbh branch from d525807 to 6982b97 Compare November 17, 2025 12:51
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.

3 participants