Unexpected Page Breaks in Widget Table Rendering #10188

Closed
opened 2025-12-29 21:28:00 +01:00 by adam · 5 comments
Owner

Originally created by @opericgithub on GitHub (Sep 4, 2024).

Originally assigned to: @jeremystretch on GitHub.

Deployment Type

Self-hosted

NetBox Version

v4.1.0

Python Version

3.10

Steps to Reproduce

I've encountered an issue with how widget tables are rendered in NetBox v4.1 compared to v3.7. Specifically, I'm experiencing unexpected page breaks that cause the table content to disintegrate, which disrupts the proper display of journal entries.
I've attached screenshots of both versions to illustrate the issue.

NetBox Version 3.7:

I have two journal entries displayed in a widget.
In the first entry, there is some text followed by a table with headers and values.
In the second entry, there is only text without a table.
Everything renders correctly, with the first entry displaying the text and the table beneath it, and the second entry showing the text as expected.

image

NetBox Version 4.1:

With the same two journal entries, the content now breaks unexpectedly.
The text of the first entry is displayed correctly until the table header, but then it suddenly breaks.
The second entry displays the text correctly, but the table content from the first entry appears below it, partially rendering the table with headers and values.

image

Steps to Reproduce:

  1. Create two journal entries in a widget.
  2. Ensure the first entry has text followed by a table with headers and values.
  3. Observe the rendering differences between NetBox v3.7 and v4.1.

Expected Behavior

The journal entries should render consistently, with tables staying intact under the corresponding text without unexpected breaks, as it was in NetBox v3.7.

Observed Behavior

In NetBox v4.1, the page breaks disrupt the table rendering, causing it to disintegrate and misalign with the journal entry.

Please let me know if you need any further details or additional information.

Thank you!

Originally created by @opericgithub on GitHub (Sep 4, 2024). Originally assigned to: @jeremystretch on GitHub. ### Deployment Type Self-hosted ### NetBox Version v4.1.0 ### Python Version 3.10 ### Steps to Reproduce I've encountered an issue with how widget tables are rendered in NetBox v4.1 compared to v3.7. Specifically, I'm experiencing unexpected page breaks that cause the table content to disintegrate, which disrupts the proper display of journal entries. I've attached screenshots of both versions to illustrate the issue. NetBox Version **3.7**: I have two journal entries displayed in a widget. In the first entry, there is some text followed by a table with headers and values. In the second entry, there is only text without a table. Everything renders correctly, with the first entry displaying the text and the table beneath it, and the second entry showing the text as expected. ![image](https://github.com/user-attachments/assets/decbbd29-52b1-40cc-90f1-a03be4794e4e) NetBox Version **4.1**: With the same two journal entries, the content now breaks unexpectedly. The text of the first entry is displayed correctly until the table header, but then it suddenly breaks. The second entry displays the text correctly, but the table content from the first entry appears below it, partially rendering the table with headers and values. ![image](https://github.com/user-attachments/assets/f111873e-021a-4f7b-8a6b-70dc3bd91727) Steps to Reproduce: 1. Create two journal entries in a widget. 2. Ensure the first entry has text followed by a table with headers and values. 3. Observe the rendering differences between NetBox v3.7 and v4.1. ### Expected Behavior The journal entries should render consistently, with tables staying intact under the corresponding text without unexpected breaks, as it was in NetBox v3.7. ### Observed Behavior In NetBox v4.1, the page breaks disrupt the table rendering, causing it to disintegrate and misalign with the journal entry. Please let me know if you need any further details or additional information. Thank you!
adam added the type: bugstatus: acceptedseverity: low labels 2025-12-29 21:28:00 +01:00
adam closed this issue 2025-12-29 21:28:00 +01:00
Author
Owner

@jeremystretch commented on GitHub (Sep 4, 2024):

@opericgithub could you please share the markup you're using in the comments field of the offending object?

@jeremystretch commented on GitHub (Sep 4, 2024): @opericgithub could you please share the markup you're using in the `comments` field of the offending object?
Author
Owner

@opericgithub commented on GitHub (Sep 4, 2024):

yes Jeremy, here it is:

image

@opericgithub commented on GitHub (Sep 4, 2024): yes Jeremy, here it is: ![image](https://github.com/user-attachments/assets/abde066f-a8a1-45f9-a3db-95d1ad8108dc)
Author
Owner

@jeremystretch commented on GitHub (Sep 4, 2024):

This is caused by the hx-select="table" attribute on the widget's container element. Coincidentally, this should be fixed by PR #17370 which was submitted for bug #17332.

Marking this as blocked until that PR has been merged, at which point we should check that this bug has also been addressed.

@jeremystretch commented on GitHub (Sep 4, 2024): This is caused by the `hx-select="table"` attribute on the widget's container element. Coincidentally, this should be fixed by PR #17370 which was submitted for bug #17332. Marking this as blocked until that PR has been merged, at which point we should check that this bug has also been addressed.
Author
Owner

@jeremystretch commented on GitHub (Sep 4, 2024):

This has been fixed by PR #17370.

screenshot

@jeremystretch commented on GitHub (Sep 4, 2024): This has been fixed by PR #17370. ![screenshot](https://github.com/user-attachments/assets/0d465992-4086-4623-893d-ab2ba43ea175)
Author
Owner

@opericgithub commented on GitHub (Sep 4, 2024):

Thanks, I can confirm it works now on develop branch

@opericgithub commented on GitHub (Sep 4, 2024): Thanks, I can confirm it works now on develop branch
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#10188