LearnNewsExamplesServices
Frontmatter
id8480
titleConstrain Markdown image wrapper width in Portal app
stateClosed
labels
bugai
assigneestobiu
createdAtJan 9, 2026, 7:26 PM
updatedAtJan 9, 2026, 8:27 PM
githubUrlhttps://github.com/neomjs/neo/issues/8480
authortobiu
commentsCount1
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtJan 9, 2026, 8:27 PM

Constrain Markdown image wrapper width in Portal app

tobiu
tobiu commented on Jan 9, 2026, 7:26 PM

The .neo-markdown-image-wrapper with width: 100% overrides the padding-right defined in resources/scss/src/apps/portal/shared/content/Component.scss, causing the image container to still overlap the sections navigation in some contexts.

We need to adjust the styles in resources/scss/src/apps/portal/shared/content/Component.scss to constrain the max-width of the image wrapper effectively, ensuring it respects the padding intended for the navigation layout.

Goal: Ensure the image wrapper does not exceed the available content width (minus the right padding/margin reserved for the nav).

tobiu
tobiu Jan 9, 2026, 8:27 PM

Input from Gemini 3 Pro:

✦ Resolved the layout overflow issue by implementing a comprehensive flexbox constraint chain.

Key Changes:

  1. Flex Shrink: Enforced flex-shrink: 1 !important and min-width: 0 on MainContainer, PageContainer, and TabContainer levels to prevent flex items from forcing parent expansion.
  2. Image Wrapper: Set max-width: 100% on .neo-markdown-image-wrapper to respect the parent's constrained width.
  3. Article Constraints: Applied max-width: min(1200px, calc(100% - 250px)) to the Markdown component on large screens to strictly reserve space for the Sections Navigation.
  4. Cleanup: Removed redundant padding from the Portal component SCSS.

This ensures the layout correctly adapts to the viewport width, preventing content from overlapping the side navigation.