Skip to content

fix : add background styling for dark logos in branding documentation - #247

Merged
moshams272 merged 9 commits into
webpack:mainfrom
Ekagrashharma:fix/icon-bg
Aug 21, 2026
Merged

fix : add background styling for dark logos in branding documentation#247
moshams272 merged 9 commits into
webpack:mainfrom
Ekagrashharma:fix/icon-bg

Conversation

@Ekagrashharma

@Ekagrashharma Ekagrashharma commented Aug 15, 2026

Copy link
Copy Markdown
Contributor

Summary

This pull request updates the pages/about/branding.md file to improve the presentation of the webpack logos on dark backgrounds. The main change is the addition of a dark background behind the logo images to ensure better visibility and consistency.

Added a dark background (#0d121c) behind the horizontal and stacked logo images for dark backgrounds using a styled, making the logos more visible and visually consistent.

fixes : #243

Dark theme
Screenshot 2026-08-15 204053

Light theme
Screenshot 2026-08-15 204105

Summary by CodeRabbit

  • Style
    • Improved dark-background logo previews in the branding documentation with consistent backgrounds and padding.
    • Standardized logo and icon tables with a more compact, balanced layout.
    • Centered the hex sticker image for improved presentation.
    • Preserved existing links to downloadable logo assets.
    • Updated branding styles for clearer, more consistent visual presentation.

Copilot AI lite review requested due to automatic review settings August 15, 2026 17:15
@vercel

vercel Bot commented Aug 15, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
webpack-doc-kit Ready Ready Preview Aug 21, 2026 2:00am

Request Review

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@github-actions github-actions Bot added the documentation Improvements or additions to documentation label Aug 15, 2026
@coderabbitai

coderabbitai Bot commented Aug 15, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: c38f6f7e-03eb-441f-b686-b05bc9b6b444

📥 Commits

Reviewing files that changed from the base of the PR and between 233287a and 002dc7c.

📒 Files selected for processing (2)
  • pages/about/branding.md
  • styles/index.css
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • webpack/webpack (auto-detected)
💤 Files with no reviewable changes (1)
  • styles/index.css
🚧 Files skipped from review as they are similar to previous changes (1)
  • pages/about/branding.md

Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.


Walkthrough

The branding page wraps dark-background logo images in darkBg spans. The stylesheet adds dark backgrounds, padding, fixed table layout, and equal-width columns. The hex sticker is wrapped in a centered container. Its image is displayed as a centered block.

Merge Risk: ⚪ Minimal · up to 002dc

This localized documentation styling change adds dark backgrounds behind branding logos and introduces no actionable merge-blocking risk; it is merge-ready after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes the main change: adding background styling for dark logos in the branding documentation.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (2 skipped: 2 unsupported.)
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@Ekagrashharma Ekagrashharma changed the title fix(branding): add background styling for dark logos in branding documents fix : add background styling for dark logos in branding documentation Aug 15, 2026
Comment thread pages/about/branding.md Outdated
| [svg](https://github.com/openjs-foundation/artwork/blob/main/projects/webpack/webpack-logo-horizontal-color.svg) \| [png](https://github.com/openjs-foundation/artwork/blob/main/projects/webpack/webpack-logo-horizontal-color.png) | [svg](https://github.com/openjs-foundation/artwork/blob/main/projects/webpack/webpack-logo-horizontal-color-dark_background.svg) \| [png](https://github.com/openjs-foundation/artwork/blob/main/projects/webpack/webpack-logo-horizontal-color-dark_background.png) |
| Light backgrounds | Dark backgrounds |
| :----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------: |
| ![webpack horizontal logo for light backgrounds](https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color.png) | <span style="background-color: #0d121c; padding: 20px; display: inline-block;">![webpack horizontal logo for dark backgrounds](https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color-dark_background.png)</span> |

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Can we use a -- variable, we have several theme variables defined

@Ekagrashharma Ekagrashharma Aug 15, 2026

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Okay, I understand. Should I use one of the existing theme variables for this, or would you prefer me to define a new variable for the color?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hi @Ekagrashharma! I encourage you to read webpack's AI policy.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Sure, I’ll go through the AI policy and make sure I’m aligned with that .
Just wanted to be transparent with you—I’m not too much confident with my English, so I sometimes use AI to help me phrase my messages better. :)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hey, @avivkeller, can you help me with what to do next

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hey, @TusharThakur04

I tried to add the variable instead of the hex code, but Tailwind is not loading in the MDX file. I read the CSS and style loader file, but I am unclear on how to tackle this.

Can you give me some references where I can look into this ?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@avivkeller does mdx parser at doc-kit take care of variable names?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The variable name is plain CSS, so it's not parsed/tailwind-ed, and is handled by the browser's CSS loading directly

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@Ekagrashharma If you push your changes that aren't working, I'm sure I can help identify a root cause :-)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@Ekagrashharma If you push your changes that aren't working, I'm sure I can help identify a root cause :-)

OK, I'll do that, and I also added 2 test divs so you can see that Tailwind is not loading, but the inline CSS is working.

  • the theme.css is declaring the @theme variables

@github-actions github-actions Bot added the dependencies Pull requests that update a dependency file label Aug 17, 2026
Comment thread package.json Outdated
Comment thread package.json Outdated
Comment thread pages/about/branding.md Outdated
@ryzrr

ryzrr commented Aug 18, 2026

Copy link
Copy Markdown
Member

@avivkeller Just wondering ,should we make these logos consistent or does that conflict with the branding guidelines? Just checking .
image

@ovflowd

ovflowd commented Aug 18, 2026

Copy link
Copy Markdown
Member

@avivkeller Just wondering ,should we make these logos consistent or does that conflict with the branding guidelines? Just checking . image

Define making them consistent?

@TusharThakur04

Copy link
Copy Markdown
Member

size i guess

@ovflowd

ovflowd commented Aug 18, 2026

Copy link
Copy Markdown
Member

size i guess

I agree on that, the logo sizes are wildly different.

@Ekagrashharma

Ekagrashharma commented Aug 18, 2026

Copy link
Copy Markdown
Contributor Author

size i guess

I agree on that, the logo sizes are wildly different.

Yeah, I agree with that. Should I add a commit to fix this or make a new issue ?

@Ekagrashharma

Copy link
Copy Markdown
Contributor Author
image

WDYT? it this better ? @TusharThakur04

@ryzrr

ryzrr commented Aug 18, 2026

Copy link
Copy Markdown
Member

size i guess

I agree on that, the logo sizes are wildly different.

yes i meant the sizing of the logos

@Ekagrashharma

Copy link
Copy Markdown
Contributor Author

size i guess

I agree on that, the logo sizes are wildly different.

yes i meant the sizing of the logos

Just to confirm, are you saying that the logos have different dimensions?

@ovflowd

ovflowd commented Aug 18, 2026

Copy link
Copy Markdown
Member

size i guess

I agree on that, the logo sizes are wildly different.

yes i meant the sizing of the logos

Just to confirm, are you saying that the logos have different dimensions?

the ask is that the different logos use similar proportional sizes. Some logos are huge.

@Ekagrashharma

Copy link
Copy Markdown
Contributor Author

Yes, exactly. they have different dimensions, and some appear much larger than others.

@github-actions github-actions Bot removed the dependencies Pull requests that update a dependency file label Aug 19, 2026

@moshams272 moshams272 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nice work. 🤍

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: b93abd28-07f8-4fc0-830f-c5920bffabe2

📥 Commits

Reviewing files that changed from the base of the PR and between 5b56d7b and 6d0357d.

📒 Files selected for processing (2)
  • pages/about/branding.md
  • styles/index.css
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • webpack/webpack (auto-detected)
🚧 Files skipped from review as they are similar to previous changes (1)
  • pages/about/branding.md

Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.

Comment thread styles/index.css
Comment on lines +25 to +29
.darkBg {
background-color: var(--color-neutral-950);
display: inline-block;
padding: 20px;
}

@coderabbitai coderabbitai Bot Aug 19, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

# Expect image rules that keep the logos within their 50% table cells.
rg -n -C 4 '\.darkBg|\.halfWidthTable|img|max-width|max-height|overflow' \
  styles pages/about/branding.md

Repository: webpack/webpack-doc-kit

Length of output: 855


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- branding references and image syntax ---'
rg -n -C 8 'darkBg|halfWidthTable|!\[|<img|image|logo' pages/about/branding.md pages styles || true

printf '%s\n' '--- stylesheet structure and image rules ---'
fd -t f -e css -e scss -e md . styles pages | sort
rg -n -C 3 '(^|[,{[:space:]])img([[:space:]:,{]|$)|max-width|max-height|width:|height:|overflow' styles pages || true

printf '%s\n' '--- relevant file sizes ---'
wc -l styles/index.css pages/about/branding.md

Repository: webpack/webpack-doc-kit

Length of output: 50382


🏁 Script executed:

#!/bin/bash
set -euo pipefail

python3 - <<'PY'
from pathlib import Path
import re

css = Path("styles/index.css").read_text()
md = Path("pages/about/branding.md").read_text()

print("--- CSS declarations ---")
for selector, body in re.findall(r"([^{}]+)\{([^{}]*)\}", css):
    if any(term in selector for term in ("darkBg", "halfWidthTable", "img")):
        print(selector.strip(), "=>", " ".join(body.split()))

print("--- branding image lines and wrappers ---")
for number, line in enumerate(md.splitlines(), 1):
    if any(term in line for term in ("darkBg", "halfWidthTable", "![", "<img")):
        print(f"{number}: {line}")

print("--- intrinsic image dimensions in repository ---")
for path in Path(".").rglob("*"):
    if path.is_file() and path.suffix.lower() in {".png", ".jpg", ".jpeg", ".svg", ".webp"}:
        print(path)
PY

Repository: webpack/webpack-doc-kit

Length of output: 3313


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- all stylesheet files ---'
fd -t f \( -e css -o -e scss \) . | sort

printf '%s\n' '--- image and table rules in stylesheets ---'
while IFS= read -r file; do
  printf '\n[%s]\n' "$file"
  rg -n -C 3 '(^|[,{[:space:]])img([[:space:]:,{]|$)|max-width|max-height|width:|height:|overflow|table-layout|halfWidthTable|darkBg' "$file" || true
done < <(fd -t f \( -e css -o -e scss \) . | sort)

printf '%s\n' '--- layout/config references ---'
rg -n -C 3 'styles/index\.css|index\.css|markdown|remark|rehype|table' package.json *.js *.cjs *.mjs *.ts config* scripts plugins 2>/dev/null || true

Repository: webpack/webpack-doc-kit

Length of output: 303


🏁 Script executed (no clone):

#!/bin/bash
set -euo pipefail

python3 - <<'PY'
from urllib.request import urlopen
from struct import unpack

urls = {
    "horizontal-light": "https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color.png",
    "horizontal-dark": "https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color-dark_background.png",
    "stacked-light": "https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color.png",
    "stacked-dark": "https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color-dark_background.png",
}

for name, url in urls.items():
    with urlopen(url, timeout=15) as response:
        data = response.read()
    if data[:8] != b"\x89PNG\r\n\x1a\n":
        raise RuntimeError(f"{name}: response is not PNG")
    width, height = unpack(">II", data[16:24])
    print(f"{name}: {width}x{height}, bytes={len(data)}")
PY

Length of output: 2412


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- all stylesheet files ---'
fd --type f --extension css --extension scss . | sort

printf '%s\n' '--- image and table rules in stylesheets ---'
while IFS= read -r file; do
  printf '\n[%s]\n' "$file"
  rg -n -C 3 '(^|[,{[:space:]])img([[:space:]:,{]|$)|max-width|max-height|width:|height:|overflow|table-layout|halfWidthTable|darkBg' "$file" || true
done < <(fd --type f --extension css --extension scss . | sort)

printf '%s\n' '--- layout/config references ---'
rg -n -C 3 'styles/index\.css|index\.css|markdown|remark|rehype|table' package.json '*.js' '*.cjs' '*.mjs' '*.ts' config* scripts plugins 2>/dev/null || true

Repository: webpack/webpack-doc-kit

Length of output: 1158


🏁 Script executed (no clone):

#!/bin/bash
set -euo pipefail

for url in \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color-dark_background.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color-dark_background.png'
do
  printf '%s: ' "$url"
  curl -ksSL --fail "$url" | python3 -c '
import sys, struct
data = sys.stdin.buffer.read()
if data[:8] != b"\x89PNG\r\n\x1a\n":
    raise SystemExit("not a PNG")
print(f"{struct.unpack(\">II\", data[16:24])[0]}x{struct.unpack(\">II\", data[16:24])[1]}")
'
done

Length of output: 625


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- global stylesheets ---'
for file in styles/index.css styles/theme.css; do
  printf '\n[%s]\n' "$file"
  cat -n "$file"
done

printf '%s\n' '--- image rules across stylesheets ---'
rg -n -C 4 '(^|[,{[:space:]])img([[:space:]:,{]|$)|max-width|max-height|overflow' \
  styles components layouts || true

printf '%s\n' '--- branding table scope ---'
sed -n '18,38p' pages/about/branding.md

Repository: webpack/webpack-doc-kit

Length of output: 11940


🏁 Script executed (no clone):

#!/bin/bash
set -euo pipefail

for url in \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-horizontal-color-dark_background.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color.png' \
  'https://raw.githubusercontent.com/openjs-foundation/artwork/main/projects/webpack/webpack-logo-stacked-color-dark_background.png'
do
  printf '%s: ' "$url"
  curl -ksSL --fail "$url" -o /tmp/logo.png
  python3 - <<'PY'
import struct
data = open("/tmp/logo.png", "rb").read()
if data[:8] != b"\x89PNG\r\n\x1a\n":
    raise SystemExit("not a PNG")
width, height = struct.unpack(">II", data[16:24])
print(f"{width}x{height}")
PY
done

Length of output: 658


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- Tailwind version and preflight source ---'
rg -n '"tailwindcss"|tailwindcss@|preflight' package.json package-lock.json pnpm-lock.yaml yarn.lock node_modules/tailwindcss 2>/dev/null | head -80 || true
find node_modules/tailwindcss -maxdepth 3 -type f \( -iname '*preflight*' -o -iname '*.css' \) -print 2>/dev/null | head -40

printf '%s\n' '--- markdown renderer and article classes ---'
rg -n -C 5 'ReactMarkdown|remark|rehype|dangerouslySetInnerHTML|prose|article|mdx|markdown' \
  components layouts plugins scripts package.json 2>/dev/null | head -240 || true

printf '%s\n' '--- exact branding wrapper scope ---'
python3 - <<'PY'
from pathlib import Path
text = Path("pages/about/branding.md").read_text()
print("halfWidthTable openings:", text.count('<div class="halfWidthTable">'))
print("halfWidthTable closings:", text.count("</div>"))
print("stacked table is inside wrapper:", text.index("### Stacked logo") < text.index("</div>"))
PY

Repository: webpack/webpack-doc-kit

Length of output: 315


🏁 Script executed:

#!/bin/bash
set -u

printf '%s\n' '--- Tailwind package files ---'
find node_modules/tailwindcss -maxdepth 3 -type f \( -iname '*preflight*' -o -iname '*.css' \) -print 2>/dev/null | head -40 || true

printf '%s\n' '--- Tailwind preflight references ---'
rg -n -C 4 'max-width: 100%|height: auto|img, video|preflight' \
  node_modules/tailwindcss package-lock.json 2>/dev/null | head -120 || true

printf '%s\n' '--- markdown renderer and article classes ---'
rg -n -C 5 'ReactMarkdown|remark|rehype|dangerouslySetInnerHTML|prose|article|mdx|markdown' \
  components layouts plugins scripts package.json 2>/dev/null | head -240 || true

printf '%s\n' '--- exact branding wrapper scope ---'
python3 - <<'PY'
from pathlib import Path
text = Path("pages/about/branding.md").read_text()
open_at = text.index('<div class="halfWidthTable">')
close_at = text.index("</div>", open_at)
stacked_at = text.index("### Stacked logo")
print("wrapper opening:", open_at)
print("wrapper closing:", close_at)
print("stacked heading:", stacked_at)
print("stacked table inside wrapper:", open_at < stacked_at < close_at)
PY

Repository: webpack/webpack-doc-kit

Length of output: 12385


🌐 Web query:

Tailwind CSS v4.3.3 preflight img video max-width 100% height auto

💡 Result:

In Tailwind CSS v4.3.3, Preflight includes a base style rule that constrains images and videos to prevent them from overflowing their containers [1][2]: img, video { max-width: 100%; height: auto; } This rule ensures that images and videos are responsive by default, maintaining their intrinsic aspect ratio [1][2]. If you need to override this behavior, you can use the max-w-none utility class [1][2]. For cases where you must remove the height: auto rule entirely, common approaches include [3][4]: 1. Disabling Preflight: You can disable Preflight globally if you prefer to manage your own base resets [3][4]. 2. Using Utility Overrides: While it is difficult to revert height: auto to the default browser behavior using simple CSS values, you may need to apply specific heights or use other layout strategies if the default behavior conflicts with your design [3][4]. 3. Custom PostCSS Plugins: Some developers use plugins to strip specific rules from the generated CSS after Tailwind runs [4]. Please note that Tailwind v4.3.3 introduced a fix regarding Preflight and iframes to prevent it from overriding Firefox's native focus-visible outline styles, but the core image and video constraint rules remain unchanged [5][6][7].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- focused change ---'
git diff --unified=12 -- styles/index.css pages/about/branding.md

printf '%s\n' '--- available browser/layout tools ---'
for command in chromium chromium-browser google-chrome firefox playwright; do
  if command -v "$command" >/dev/null 2>&1; then
    printf '%s: %s\n' "$command" "$(command -v "$command")"
  fi
done

printf '%s\n' '--- relevant package metadata ---'
sed -n '1,80p' package.json

Repository: webpack/webpack-doc-kit

Length of output: 2226


🌐 Web query:

CSS inline-block wrapper padding child img max-width 100% intrinsic width overflow table cell

💡 Result:

The layout issues you are encountering when nesting an image with max-width: 100% inside an inline-block wrapper—especially within a table cell—stem from cyclic dependencies in how browsers calculate intrinsic widths [1][2][3]. When a container (like an inline-block or a table cell) has an auto width, its size is determined by its content [2][4]. If a child image within that container is set to max-width: 100%, the browser faces a circular dependency: it cannot determine the width of the container without the image, but it cannot determine the width of the image without knowing the width of the container [1][2][3]. Key causes and solutions for these behaviors are detailed below: Circular Dependency in Intrinsic Sizing When the wrapper is inline-block and the child image is set to max-width: 100%, the browser may default to the image's intrinsic (natural) pixel size rather than scaling it to the available space [1][5]. This often causes the wrapper (and consequently the table cell) to expand to the full natural width of the image [1][6][7]. Baseline Gaps Images are inline elements by default [8][6]. Even if you set display: block on an image, it often leaves a small gap at the bottom of a container because it aligns to the baseline of the text, reserving space for typographic descenders [9][10]. To eliminate this, ensure the image is set to display: block or vertical-align: top/bottom [11][9][6]. Fixing Table Cell Overflow If images cause a table cell or its wrapper to exceed expected bounds, consider these strategies: - Use the min function: If you need responsiveness while preventing expansion beyond natural size, use width: min(100%, px) [1]. This breaks the circular dependency by bounding the image's contribution to the table's auto-layout calculation [1]. - Enforce layout: Setting table-layout: fixed on the table can prevent cells from expanding based on image content, forcing them to respect defined column widths [8][12]. - Force Block Behavior: Always set display: block on images inside wrappers to remove inline-related spacing issues [11][6]. - Use min-width: 100% on the wrapper: If using an inline-block wrapper inside an overflow container, adding min-width: 100% ensures the wrapper correctly fills the available scrollable space rather than shrinking to fit the image [13]. If you are using percentage-based padding on the wrapper or child, the browser may ignore the padding during the initial intrinsic width calculation to avoid an infinite loop [3]. Using fixed units (e.g., px, em) for padding often resolves these layout calculation failures [3].

Citations:


Constrain .darkBg and wrap the stacked logo table.

Tailwind Preflight constrains the direct <img>, but .darkBg can retain the nested image’s intrinsic width. Its 20px padding can then make the dark cell overflow its fixed 50% column on narrow screens. Add scoped max-width: 100% and box-sizing: border-box rules to .darkBg.

The stacked logo table is outside .halfWidthTable, so it does not receive the fixed-layout or 50% column rules. Move the closing </div> after that table if both tables require equal columns.

✅ Addressed in commit 002dc7c

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@Ekagrashharma what about the third table 👀

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

which one?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@Ekagrashharma what about the third table 👀

working on it

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

which one?

The one under them that is the sticker ;)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Hey @Ekagra! I was checking the recent commit. It looks like you added some custom CSS to fix the width of the third table. Actually, the reviewer just wanted us to move the closing </div> of .halfWidthTable down in the Markdown file so it wraps the third table as well. 👀

@Ekagrashharma

Copy link
Copy Markdown
Contributor Author

Nice work. 🤍

Thank you; it means a lot :)

@Ekagrashharma

Copy link
Copy Markdown
Contributor Author
Screenshot 2026-08-20 184940

final changes.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

♻️ Duplicate comments (1)
styles/index.css (1)

24-29: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Prevent .darkBg from overflowing narrow table cells.

At Line 24, .darkBg uses display: inline-block and padding: 20px without a width constraint. The nested logo can retain its intrinsic width, causing the wrapper to exceed the fixed 50% column on narrow screens. Add box-sizing: border-box and max-width: 100% to .darkBg, and constrain its nested image.

Proposed fix
 .darkBg {
   background: `#0d121c`;
+  box-sizing: border-box;
   display: inline-block;
+  max-width: 100%;
   padding: 20px;
 }
+
+.darkBg img {
+  max-width: 100%;
+}

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: a9b0e8c4-42d3-42ff-9b5c-e63af8f559ae

📥 Commits

Reviewing files that changed from the base of the PR and between 6d0357d and 233287a.

📒 Files selected for processing (2)
  • pages/about/branding.md
  • styles/index.css
🔗 Linked repositories identified

CodeRabbit considers these linked repositories for cross-repo context during reviews:

  • webpack/webpack (auto-detected)
🚧 Files skipped from review as they are similar to previous changes (1)
  • pages/about/branding.md

Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review.

@moshams272
moshams272 merged commit f2af951 into webpack:main Aug 21, 2026
14 checks passed
@Ekagrashharma

Copy link
Copy Markdown
Contributor Author

Thanks to all the maintainers for your support and guidance in getting this issue merged.

I really appreciate it! :)

Could you also guide me on how I can start tackling more challenging issues?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation theme

Projects

None yet

Development

Successfully merging this pull request may close these issues.

page(branding): should force light/dark. bg on icon

7 participants