Skip to content

docs: Update custom-scripts documentation regarding nav-logo CSS specificity overrides #6242

Description

@KrishnaGupta0405

Linked line:

- `nav-logo` — Logo in the navigation bar.

Description

The current documentation for Custom Scripts states that the nav-logo element selector can be targeted directly in CSS to style the navigation bar logo (e.g., nav-logo { height: 3.75rem; }).

However, trying to manipulate the height using just nav-logo fails because Mintlify's internal Tailwind utility classes (such as .h-7 on the image/svg element) have higher specificity and completely override the raw element selector.

To get the logo to successfully scale up, developers have to explicitly target the underlying image element and apply !important to break past the Tailwind utility classes.

Current Behavior vs Expected Behavior

  • Expected: Adding nav-logo { height: 3.75rem; } increases the logo size.
  • Actual: The style is completely ignored due to Tailwind class specificity.

Suggested Documentation Fix / Solution

It would be incredibly helpful to update this line in the documentation to let developers know they need to target the inner image element directly to bypass the utility classes.

For example, updating the note or adding a code snippet like this:

img.nav-logo,
img.nav-logo.h-7 {
  height: 3.75rem !important;
  width: auto !important;
}

Edit-> (I forgot to paste the permalink)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions